iT邦幫忙

第 11 屆 iT 邦幫忙鐵人賽

DAY 3
0

對於ML有些基礎認知後,是時候嘗試自己針對問題做設計和推敲吧!

同樣在coursera聽著後續的課程,內容提及了監督式神經網路的訓練,在運用了眾多被標註過的資料後便可以對影像做分類,這的確是基礎中的基礎範本呢~ 有趣的是當中提到一件事,ML應該是兩個階段,分別是訓練(training)與推論(inferences)。

訓練就是我們稍有實際接觸ML模型在餵資料後所做的線性代數運算,然而光有訓練模型是不夠的,我們嘗試著去教機器達成我們想要的任務,但機器真的學會之後能自己做推論嗎?前面提到的監督式範例,就是給他諸多影像如車子、貓、狗... 的東西,教這個ML模型自己根據我們的標註的名稱去學習,訓練完後給機器一隻新的貓圖片問「照片上的是什麼?」,如果它在學習的階段掌握了不同名稱的東西具有怎麼樣的影像特徵,那它就能做到推論回說「我想是貓貓」

推論這個動作我以往也只是當做驗證模型可不可用,但影片也提醒多數書籍、blog貼文、大學課程都會忽視推論這個階段,因此期望用end-to-end的方式另外教學怎麼實際運用ML模型,仔細想想我也時常不重視這件事,影片中的一席話到讓我頗受衝擊呢

"What is the use of training Machine Learing model if you cannot use it?"

恩,有了不同視野後仍要一步一步來,先來定義ML的問題接著做~
這裡用影片中定義問題的示範答案,建議可以嘗試自己想看看,我自己其實也是在對問題的理解上仍是一知半解就回答了(coursera以開放性討論方式作答),原始問題會以英文呈現,有中文翻譯的為示範答案。

選擇一個議題來嘗試定義問題

Use Case : Demand forecasting in manufacturing(製造上的需求預測)
If the use case was an ML problem....

1)What is being predicted?
How many units of widgets X should be manufactured this month
(這個月要製造多少個部件X)

2)What data is needed?
We need historical data on the number of units sold
(我們需要過去販售多少件的歷史紀錄)


Now imagine the ML problem is a question of software:

3)What is the API for the problem during prediction?
the method in the API could be predicted demand, and what does it take?
(這API中的方法可以是預測需求,那麼它會需要什麼?)
The inputs might be the widget ID and the month that we want to do this prediction for,
with the default value for the month being the current month.
(可能是部件ID和想預測需求的月份當作輸入,並將當前月份做為預設值)
We're not asking the end user to give us how many ... units were sold last month.
That is something that we would have to collect ourselves.
(我們並不會要求終端使用者提供上個月是販售多少單位個...。
那是些我們必須由自己蒐集而來的資料)

predictDemand(widgetID,month=currentTime.month)

4)Who will use this service? How are they doing it today?
we might think that the users might be product managers, might be logistics managers, et cetera.
(我們可以認為使用者有機會是產品經理或物流經裡等等)
They examine trends of ... sales, overall economy, trade publications, and they somehow make a decision.
(它們研究...的銷售趨勢、全國經濟、貿易刊物,並以某種方式做出決定)


Lastly, cast it in the framework of a data problem. What are some key actions to collect, analyze, predict, and react to the data/predictions (different input features might require different actions)

5)What data are we collect?
We need to collect the economic data, the competitor data, the industry data,
data from our company itself.
(我們必須蒐集經濟上的數據、競爭者的數據、產業數據、我們公司自己的數據)

6)What data are we analyzing?
craft features that our experts are looking at today from this data, and we need to take those features and use them as inputs to our model
(創造一些如今專家們希望從這些數據中發掘的特徵,而且我們需要獲取這些特徵後將它當作我們模型的輸入)

7)What data are we reactiong to?
if we predicted that demand is going to increase, we automatically go ahead and put out orders to our suppliers for more of the things that they provide to us. So the reaction might be automatic.
(如果我們預測需求將會增加,我們將自動的持續運行且發出訂單到我們的供應商增加供應量,所以我們的反應可能是自動的)


上一篇
Day2 第一堂課就遲到啦
下一篇
Day4 策略
系列文
想使自身成長就先從連續30天的機器學習開始吧!31

尚未有邦友留言

立即登入留言