SlideShare a Scribd company logo
2022/9/6
1
DNN Lab 1 and 3
• Lab 1 (DNN supervised learning): Titanic Survival Predication
• Lab 3 (DNN supervised learning): curve learning
• Lab 7 (reinforcement learning): Q Learning maze
• Lab 8 (reinforcement learning): Open AI : Mountain Car
• Lab 9 (reinforcement learning): Open AI :CartPole
• Lab 2 (CNN supervised learning): image classification- ImageNet
• Lab 5 (CNN supervised learning): handwriting number classification- Mnist
• Lab 6 (CNN supervised learning): object detection- SSD (Single Shot MultiBox Detector)
• Lab 4 (RNN supervised learning)
2
2022/9/6
Three levels for lab1-12 reports
• (Minimum) Run the program and get reasonable result, e.g, accuracy around 90%
• Tune the hyperparameters to get better result
• Change the dataset and get acceptable results
3
(tensorflow) C:> Lab01_titanic_survival_prediction
(tensorflow) C:> python titanic_survival_predictation.py
(tensorflow) C:> 可自行修改輸入資料,看結果合不合理?
(tensorflow) C:> cd..
(tensorflow) C:> cd Lab03_plot_result
(tensorflow) C:> python plot_result.py
(tensorflow) C:> 可自行修改輸入曲線,看是否可以訓練成功?
(tensorflow) C:> cd..
Run Lab01 and Lab03
4
2022/9/6
Lab01 Titanic Survival
Prediction
↓
PM2.5 Exceeded Prediction (Change
dataset!)
職電子碩㇐ 110368505 劉蘋慧
110368526 蕭銘宏
110368529 林佑軒
110368540 李品濬
Abstract
● Titanic survival prediction
In this case, we learned how to use TFLearn and TensorFlow to model the survival chance of
titanic passengers using their personal information (such as gender, age, and so on). To
tackle this classic machine learning task, we are going to build a DNN classifier.
2022/9/6
Abstract
● PM2.5 exceeded prediction
Based on the case of titanic survival predictor, we used and preprocessed the dataset from
fengyuan automatic meteorological observation station to predict the chance if the
concentration of PM2.5 will exceed the standard.
Table of contents
a. Dataset parameters
b. Source code introduction
c. Source code modification
d. Conclusion
PM2.5 Exceeded Prediction
01 02
Titanic Survival Prediction
a. Introduction
b. Dataset preprocessing
c. Source code modification
d. Conclusion
2022/9/6
Titanic Survival
Prediction
01
Dataset parameters
Dataset with titanic passengers’ personal
information.
survived (0 = No; 1 = Yes)
pclass Passenger Class (1 = st; 2 = nd; 3 = rd)
name Name
sex Sex
age Age
sibsp Number of Siblings/Spouses Aboard
parch Number of Parents/Children Aboard
ticket Ticket Number
fare Passenger Fare
2022/9/6
Titanic Survival
Prediction
01
Source code introduction
Load dataset csv
file.
Define a function to preprocess
data.
Ignore index 1 and 6
columns.
2022/9/6
Default use 2 layers of neural
network.
Softmax activation maps inputs to real numbers between 0-1,
and guarantees the sum of chances of all categories is 1.
Batch size Number of samples used for one iteration of gradient descent
Epoch Number of times that the learning algorithm work through all training samples
Changing the values of these two parameters will influence the accuracy of the prediction and the
surviving rate of DiCaprio and Winslet.
2022/9/6
Prepare the test data and predict the surviving
rates.
Titanic Survival
Prediction
01
Source code modification
2022/9/6
Add this line at the beginning of the code to remove nodes from graph
or reset entire default graph, and prevent the error below.
Add a new layer of the neural network, and modify
the nodes of these layers to 128, 64 and 32
respectively.
Keep the values of epoch and batch
size.
2022/9/6
Titanic Survival
Prediction
01
Conclusion
After modifying the structure of
the neural network, the accuracy
is improved from 0.77 to
0.81.
2022/9/6
PM2.5 Exceeded
Prediction
02
Introduction
PM2.5 standard Classify these four levels to two
categories.
1:Dangerous
0:Great
2022/9/6
We prepared the real data of fengyuan automatic weather station (AWS)
from Central Weather Bureau(CWB) to be the dataset for predicting the
chance if the concentration of PM2.5 will exceed.
PM2.5 Exceeded
Prediction
02
Dataset preprocessing
2022/9/6
We need to preprocess the dataset and let it fit the
input model format of the neural network in TFLearn.
2022/9/6
List all data to an one-dimensional
array with the sorted 18 parameters.
Reshape data to 320x18 array. (18 a
group)
Insert id numbers to the first
column.
Add parameters row and export the dataset csv
file.
2022/9/6
Classify and mask the values of PM2.5 to 0 and
1.
PM2.5 Exceeded
Prediction
02
Source code modification
2022/9/6
Designate PM2.5 as target predict
parameter.
Based on the case of titanic survival predictor, we modified
the input data shape to 17 and kept the number of the
layers and the nodes of these layers.
17 = 18 parameters – 1 (PM2.5 as predict target
parameter)
2022/9/6
Modify the value of epoch and observe the accuracy and the
loss rate. We found that the value of epoch is 15, the best
accuracy it will be. If exceeding 15, the overfitting would happen.
Meanwhile, we modified the value of batch size to 20.
Prepare the test data and predict the exceeded
rates.
2022/9/6
PM2.5 Exceeded
Prediction
02
Conclusion
The accuracy of the prediction can achieve to
0.92.
2022/9/6
AI Lab3 Report– 視覺化神經網路
利用TensorFlow進行非線性回歸計算
授課教授:曾恕銘
系所:自動化職碩㇐
學生姓名:109618515 趙國桓
109618512 彭凱群
AI Lab3 – 視覺化神經網路
• Tensorflow 特點:
1. 強大的機器學習框架
2. 開源且免費
3. 最新版至少支援六種程式語言
4. 使用者可在瀏覽器內訓練並執行模型
5. 針對小型可攜設備,TensorFlow有輕量化版本
jc1
jc2
投影片 38
jc1 jonathan chao, 2021/6/24
jc2 jonathan chao, 2021/6/24
2022/9/6
39
Ai lab3 – 視覺化神經網路
首先設定神經網路層數,
同時也把權重定義在這
裡
40
• 下方的程式碼是用來定義公式, AI Lab3的兩個題目只有公式不同
2022/9/6
41
這㇐段程式碼主要重點為 -
o 定義㇐個簡單的神經網
路
o 設定代價函數
o 採用梯度訓練法讓預測
值接近
o 畫出資料點位
42
• 下方的程式碼是用來
做1000次迭代並且
用紅色作為最接近的
資料點連接, 最後執
行時會看到㇐條中心
線會因為資料變化接
近中點
2022/9/6
43
AI Lab3 執行結果
• 上方為完整主程式展示結果
• 下方為例題展示結果
挑戰點
1. 因為㇐直出現呼叫問題, 所以刪除所有環境, 重新安裝
anaconda和tensorflow module
2. 逐行執行程式進行修改
3. 找出兩個function call定義問題
4. ㇐個個module screen 看看還有沒有定義的問題
2022/9/6
原始開發者yt 影片
• https://www.youtube.com/watch?v=ZGPfyB7ZFK8&t=269s
• https://www.youtube.com/watch?v=nslbfsN8wiU

More Related Content

Similar to AIML2 DNN lab 1 3 1hr (111-1).pdf

Lossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
Lossless Data Compression Using Rice Algorithm Based On Curve Fitting TechniqueLossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
Lossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
IRJET Journal
 
Transfer defect learning
Transfer defect learningTransfer defect learning
Transfer defect learning
Sung Kim
 
Large Scale Kernel Learning using Block Coordinate Descent
Large Scale Kernel Learning using Block Coordinate DescentLarge Scale Kernel Learning using Block Coordinate Descent
Large Scale Kernel Learning using Block Coordinate Descent
Shaleen Kumar Gupta
 
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
Jean-Claude Meteodyn
 
Latency Performance of Encoding with Random Linear Network Coding
Latency Performance of Encoding with Random Linear Network CodingLatency Performance of Encoding with Random Linear Network Coding
Latency Performance of Encoding with Random Linear Network Coding
Lars Nielsen
 
Scaling Deep Learning Algorithms on Extreme Scale Architectures
Scaling Deep Learning Algorithms on Extreme Scale ArchitecturesScaling Deep Learning Algorithms on Extreme Scale Architectures
Scaling Deep Learning Algorithms on Extreme Scale Architectures
inside-BigData.com
 
ITB Term Paper - 10BM60066
ITB Term Paper - 10BM60066ITB Term Paper - 10BM60066
ITB Term Paper - 10BM60066
rahulsm27
 
Training course lect2
Training course lect2Training course lect2
Training course lect2
Noor Dhiya
 
Cluster Analysis : Assignment & Update
Cluster Analysis : Assignment & UpdateCluster Analysis : Assignment & Update
Cluster Analysis : Assignment & Update
Billy Yang
 
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
Universitat Politècnica de Catalunya
 
1_chlamydia task completely best.docx
1_chlamydia task completely best.docx1_chlamydia task completely best.docx
1_chlamydia task completely best.docx
RachaelMutheu
 
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
Ryo 亮 Kawahara 河原
 
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
Daniel H. Stolfi
 
Story of static code analyzer development
Story of static code analyzer developmentStory of static code analyzer development
Story of static code analyzer development
Andrey Karpov
 
HW2-1_05.doc
HW2-1_05.docHW2-1_05.doc
HW2-1_05.docbutest
 
Medical Image Segmentation Using Hidden Markov Random Field A Distributed Ap...
Medical Image Segmentation Using Hidden Markov Random Field  A Distributed Ap...Medical Image Segmentation Using Hidden Markov Random Field  A Distributed Ap...
Medical Image Segmentation Using Hidden Markov Random Field A Distributed Ap...
EL-Hachemi Guerrout
 
AIML4 CNN lab256 1hr (111-1).pdf
AIML4 CNN lab256 1hr (111-1).pdfAIML4 CNN lab256 1hr (111-1).pdf
AIML4 CNN lab256 1hr (111-1).pdf
ssuserb4d806
 
Svd filtered temporal usage clustering
Svd filtered temporal usage clusteringSvd filtered temporal usage clustering
Svd filtered temporal usage clusteringLiang Xie, PhD
 
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
IAEME Publication
 

Similar to AIML2 DNN lab 1 3 1hr (111-1).pdf (20)

Lossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
Lossless Data Compression Using Rice Algorithm Based On Curve Fitting TechniqueLossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
Lossless Data Compression Using Rice Algorithm Based On Curve Fitting Technique
 
Transfer defect learning
Transfer defect learningTransfer defect learning
Transfer defect learning
 
Large Scale Kernel Learning using Block Coordinate Descent
Large Scale Kernel Learning using Block Coordinate DescentLarge Scale Kernel Learning using Block Coordinate Descent
Large Scale Kernel Learning using Block Coordinate Descent
 
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
Wind meteodyn WT cfd micro scale modeling combined statistical learning for s...
 
Latency Performance of Encoding with Random Linear Network Coding
Latency Performance of Encoding with Random Linear Network CodingLatency Performance of Encoding with Random Linear Network Coding
Latency Performance of Encoding with Random Linear Network Coding
 
Scaling Deep Learning Algorithms on Extreme Scale Architectures
Scaling Deep Learning Algorithms on Extreme Scale ArchitecturesScaling Deep Learning Algorithms on Extreme Scale Architectures
Scaling Deep Learning Algorithms on Extreme Scale Architectures
 
ITB Term Paper - 10BM60066
ITB Term Paper - 10BM60066ITB Term Paper - 10BM60066
ITB Term Paper - 10BM60066
 
Training course lect2
Training course lect2Training course lect2
Training course lect2
 
Cluster Analysis : Assignment & Update
Cluster Analysis : Assignment & UpdateCluster Analysis : Assignment & Update
Cluster Analysis : Assignment & Update
 
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
Object Segmentation (D2L7 Insight@DCU Machine Learning Workshop 2017)
 
1_chlamydia task completely best.docx
1_chlamydia task completely best.docx1_chlamydia task completely best.docx
1_chlamydia task completely best.docx
 
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
Apache Sparkを用いたスケーラブルな時系列データの異常検知モデル学習ソフトウェアの開発
 
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
A Cooperative Coevolutionary Approach to Maximise Surveillance Coverage of UA...
 
Story of static code analyzer development
Story of static code analyzer developmentStory of static code analyzer development
Story of static code analyzer development
 
HW2-1_05.doc
HW2-1_05.docHW2-1_05.doc
HW2-1_05.doc
 
Medical Image Segmentation Using Hidden Markov Random Field A Distributed Ap...
Medical Image Segmentation Using Hidden Markov Random Field  A Distributed Ap...Medical Image Segmentation Using Hidden Markov Random Field  A Distributed Ap...
Medical Image Segmentation Using Hidden Markov Random Field A Distributed Ap...
 
AIML4 CNN lab256 1hr (111-1).pdf
AIML4 CNN lab256 1hr (111-1).pdfAIML4 CNN lab256 1hr (111-1).pdf
AIML4 CNN lab256 1hr (111-1).pdf
 
Svd filtered temporal usage clustering
Svd filtered temporal usage clusteringSvd filtered temporal usage clustering
Svd filtered temporal usage clustering
 
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
AN IMPROVED METHOD FOR IDENTIFYING WELL-TEST INTERPRETATION MODEL BASED ON AG...
 
P1121133727
P1121133727P1121133727
P1121133727
 

More from ssuserb4d806

Analog_chap_02.ppt
Analog_chap_02.pptAnalog_chap_02.ppt
Analog_chap_02.ppt
ssuserb4d806
 
Analog_chap_01.ppt
Analog_chap_01.pptAnalog_chap_01.ppt
Analog_chap_01.ppt
ssuserb4d806
 
1-Introduction and Crystal Structure of Solids-已解鎖.pdf
1-Introduction and Crystal Structure of Solids-已解鎖.pdf1-Introduction and Crystal Structure of Solids-已解鎖.pdf
1-Introduction and Crystal Structure of Solids-已解鎖.pdf
ssuserb4d806
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
ssuserb4d806
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
ssuserb4d806
 
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
ssuserb4d806
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
ssuserb4d806
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
ssuserb4d806
 
RFIC_LNA_Simulation.ppt
RFIC_LNA_Simulation.pptRFIC_LNA_Simulation.ppt
RFIC_LNA_Simulation.ppt
ssuserb4d806
 
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdfAIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
ssuserb4d806
 
Lecture 1 System View.pptx - 已修復.pdf
Lecture 1 System View.pptx  -  已修復.pdfLecture 1 System View.pptx  -  已修復.pdf
Lecture 1 System View.pptx - 已修復.pdf
ssuserb4d806
 
Labs_20210809.pdf
Labs_20210809.pdfLabs_20210809.pdf
Labs_20210809.pdf
ssuserb4d806
 
Training L1 Thinking 2022702.pptx.pptx
Training L1 Thinking 2022702.pptx.pptxTraining L1 Thinking 2022702.pptx.pptx
Training L1 Thinking 2022702.pptx.pptx
ssuserb4d806
 
Lecture08-Arithmetic Code-4-Int Imp-P2.pdf
Lecture08-Arithmetic Code-4-Int Imp-P2.pdfLecture08-Arithmetic Code-4-Int Imp-P2.pdf
Lecture08-Arithmetic Code-4-Int Imp-P2.pdf
ssuserb4d806
 
Lecture09-SQ-P2.pdf
Lecture09-SQ-P2.pdfLecture09-SQ-P2.pdf
Lecture09-SQ-P2.pdf
ssuserb4d806
 
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdfLecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
ssuserb4d806
 
Lecture01-Modeling and Coding-P2.pdf
Lecture01-Modeling and Coding-P2.pdfLecture01-Modeling and Coding-P2.pdf
Lecture01-Modeling and Coding-P2.pdf
ssuserb4d806
 

More from ssuserb4d806 (20)

5.pdf
5.pdf5.pdf
5.pdf
 
4.pdf
4.pdf4.pdf
4.pdf
 
Analog_chap_02.ppt
Analog_chap_02.pptAnalog_chap_02.ppt
Analog_chap_02.ppt
 
Analog_chap_01.ppt
Analog_chap_01.pptAnalog_chap_01.ppt
Analog_chap_01.ppt
 
1-Introduction and Crystal Structure of Solids-已解鎖.pdf
1-Introduction and Crystal Structure of Solids-已解鎖.pdf1-Introduction and Crystal Structure of Solids-已解鎖.pdf
1-Introduction and Crystal Structure of Solids-已解鎖.pdf
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
 
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
Assessment_of_Fetal_and_Maternal_Well-Being_During_Pregnancy_Using_Passive_We...
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_2.pptx
 
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
台北科技大學電子所_可穿戴式系統設計_期末報告 1_賴紀廷_109368501_20230106_1.pptx
 
RFIC_LNA_Simulation.ppt
RFIC_LNA_Simulation.pptRFIC_LNA_Simulation.ppt
RFIC_LNA_Simulation.ppt
 
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdfAIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
AIML4 CNN lab 5-1 BreastCancer ML course student report 2022 spring (111-1).pdf
 
virtuoso
virtuosovirtuoso
virtuoso
 
Lecture 1 System View.pptx - 已修復.pdf
Lecture 1 System View.pptx  -  已修復.pdfLecture 1 System View.pptx  -  已修復.pdf
Lecture 1 System View.pptx - 已修復.pdf
 
Labs_20210809.pdf
Labs_20210809.pdfLabs_20210809.pdf
Labs_20210809.pdf
 
Training L1 Thinking 2022702.pptx.pptx
Training L1 Thinking 2022702.pptx.pptxTraining L1 Thinking 2022702.pptx.pptx
Training L1 Thinking 2022702.pptx.pptx
 
Lecture08-Arithmetic Code-4-Int Imp-P2.pdf
Lecture08-Arithmetic Code-4-Int Imp-P2.pdfLecture08-Arithmetic Code-4-Int Imp-P2.pdf
Lecture08-Arithmetic Code-4-Int Imp-P2.pdf
 
Lecture09-SQ-P2.pdf
Lecture09-SQ-P2.pdfLecture09-SQ-P2.pdf
Lecture09-SQ-P2.pdf
 
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdfLecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
Lecture06-Arithmetic Code-2-Algorithm Implementation-P2.pdf
 
Lecture01-Modeling and Coding-P2.pdf
Lecture01-Modeling and Coding-P2.pdfLecture01-Modeling and Coding-P2.pdf
Lecture01-Modeling and Coding-P2.pdf
 

Recently uploaded

一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单
enxupq
 
Adjusting primitives for graph : SHORT REPORT / NOTES
Adjusting primitives for graph : SHORT REPORT / NOTESAdjusting primitives for graph : SHORT REPORT / NOTES
Adjusting primitives for graph : SHORT REPORT / NOTES
Subhajit Sahu
 
一比一原版(BU毕业证)波士顿大学毕业证成绩单
一比一原版(BU毕业证)波士顿大学毕业证成绩单一比一原版(BU毕业证)波士顿大学毕业证成绩单
一比一原版(BU毕业证)波士顿大学毕业证成绩单
ewymefz
 
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
vcaxypu
 
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
slg6lamcq
 
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdfCh03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
haila53
 
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project PresentationPredicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Boston Institute of Analytics
 
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
u86oixdj
 
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
yhkoc
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单
enxupq
 
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Subhajit Sahu
 
Machine learning and optimization techniques for electrical drives.pptx
Machine learning and optimization techniques for electrical drives.pptxMachine learning and optimization techniques for electrical drives.pptx
Machine learning and optimization techniques for electrical drives.pptx
balafet
 
Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)
TravisMalana
 
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
nscud
 
一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单
ewymefz
 
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
slg6lamcq
 
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
ahzuo
 
Empowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptxEmpowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptx
benishzehra469
 
standardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghhstandardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghh
ArpitMalhotra16
 
Criminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdfCriminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdf
Criminal IP
 

Recently uploaded (20)

一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单
 
Adjusting primitives for graph : SHORT REPORT / NOTES
Adjusting primitives for graph : SHORT REPORT / NOTESAdjusting primitives for graph : SHORT REPORT / NOTES
Adjusting primitives for graph : SHORT REPORT / NOTES
 
一比一原版(BU毕业证)波士顿大学毕业证成绩单
一比一原版(BU毕业证)波士顿大学毕业证成绩单一比一原版(BU毕业证)波士顿大学毕业证成绩单
一比一原版(BU毕业证)波士顿大学毕业证成绩单
 
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
一比一原版(RUG毕业证)格罗宁根大学毕业证成绩单
 
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
一比一原版(Adelaide毕业证书)阿德莱德大学毕业证如何办理
 
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdfCh03-Managing the Object-Oriented Information Systems Project a.pdf
Ch03-Managing the Object-Oriented Information Systems Project a.pdf
 
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project PresentationPredicting Product Ad Campaign Performance: A Data Analysis Project Presentation
Predicting Product Ad Campaign Performance: A Data Analysis Project Presentation
 
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
原版制作(Deakin毕业证书)迪肯大学毕业证学位证一模一样
 
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
一比一原版(CU毕业证)卡尔顿大学毕业证成绩单
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单
 
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
Levelwise PageRank with Loop-Based Dead End Handling Strategy : SHORT REPORT ...
 
Machine learning and optimization techniques for electrical drives.pptx
Machine learning and optimization techniques for electrical drives.pptxMachine learning and optimization techniques for electrical drives.pptx
Machine learning and optimization techniques for electrical drives.pptx
 
Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)Malana- Gimlet Market Analysis (Portfolio 2)
Malana- Gimlet Market Analysis (Portfolio 2)
 
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
 
一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单
 
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
一比一原版(UniSA毕业证书)南澳大学毕业证如何办理
 
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
一比一原版(UIUC毕业证)伊利诺伊大学|厄巴纳-香槟分校毕业证如何办理
 
Empowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptxEmpowering Data Analytics Ecosystem.pptx
Empowering Data Analytics Ecosystem.pptx
 
standardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghhstandardisation of garbhpala offhgfffghh
standardisation of garbhpala offhgfffghh
 
Criminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdfCriminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdf
 

AIML2 DNN lab 1 3 1hr (111-1).pdf

  • 1. 2022/9/6 1 DNN Lab 1 and 3 • Lab 1 (DNN supervised learning): Titanic Survival Predication • Lab 3 (DNN supervised learning): curve learning • Lab 7 (reinforcement learning): Q Learning maze • Lab 8 (reinforcement learning): Open AI : Mountain Car • Lab 9 (reinforcement learning): Open AI :CartPole • Lab 2 (CNN supervised learning): image classification- ImageNet • Lab 5 (CNN supervised learning): handwriting number classification- Mnist • Lab 6 (CNN supervised learning): object detection- SSD (Single Shot MultiBox Detector) • Lab 4 (RNN supervised learning) 2
  • 2. 2022/9/6 Three levels for lab1-12 reports • (Minimum) Run the program and get reasonable result, e.g, accuracy around 90% • Tune the hyperparameters to get better result • Change the dataset and get acceptable results 3 (tensorflow) C:> Lab01_titanic_survival_prediction (tensorflow) C:> python titanic_survival_predictation.py (tensorflow) C:> 可自行修改輸入資料,看結果合不合理? (tensorflow) C:> cd.. (tensorflow) C:> cd Lab03_plot_result (tensorflow) C:> python plot_result.py (tensorflow) C:> 可自行修改輸入曲線,看是否可以訓練成功? (tensorflow) C:> cd.. Run Lab01 and Lab03 4
  • 3. 2022/9/6 Lab01 Titanic Survival Prediction ↓ PM2.5 Exceeded Prediction (Change dataset!) 職電子碩㇐ 110368505 劉蘋慧 110368526 蕭銘宏 110368529 林佑軒 110368540 李品濬 Abstract ● Titanic survival prediction In this case, we learned how to use TFLearn and TensorFlow to model the survival chance of titanic passengers using their personal information (such as gender, age, and so on). To tackle this classic machine learning task, we are going to build a DNN classifier.
  • 4. 2022/9/6 Abstract ● PM2.5 exceeded prediction Based on the case of titanic survival predictor, we used and preprocessed the dataset from fengyuan automatic meteorological observation station to predict the chance if the concentration of PM2.5 will exceed the standard. Table of contents a. Dataset parameters b. Source code introduction c. Source code modification d. Conclusion PM2.5 Exceeded Prediction 01 02 Titanic Survival Prediction a. Introduction b. Dataset preprocessing c. Source code modification d. Conclusion
  • 5. 2022/9/6 Titanic Survival Prediction 01 Dataset parameters Dataset with titanic passengers’ personal information. survived (0 = No; 1 = Yes) pclass Passenger Class (1 = st; 2 = nd; 3 = rd) name Name sex Sex age Age sibsp Number of Siblings/Spouses Aboard parch Number of Parents/Children Aboard ticket Ticket Number fare Passenger Fare
  • 6. 2022/9/6 Titanic Survival Prediction 01 Source code introduction Load dataset csv file. Define a function to preprocess data. Ignore index 1 and 6 columns.
  • 7. 2022/9/6 Default use 2 layers of neural network. Softmax activation maps inputs to real numbers between 0-1, and guarantees the sum of chances of all categories is 1. Batch size Number of samples used for one iteration of gradient descent Epoch Number of times that the learning algorithm work through all training samples Changing the values of these two parameters will influence the accuracy of the prediction and the surviving rate of DiCaprio and Winslet.
  • 8. 2022/9/6 Prepare the test data and predict the surviving rates. Titanic Survival Prediction 01 Source code modification
  • 9. 2022/9/6 Add this line at the beginning of the code to remove nodes from graph or reset entire default graph, and prevent the error below. Add a new layer of the neural network, and modify the nodes of these layers to 128, 64 and 32 respectively. Keep the values of epoch and batch size.
  • 10. 2022/9/6 Titanic Survival Prediction 01 Conclusion After modifying the structure of the neural network, the accuracy is improved from 0.77 to 0.81.
  • 11. 2022/9/6 PM2.5 Exceeded Prediction 02 Introduction PM2.5 standard Classify these four levels to two categories. 1:Dangerous 0:Great
  • 12. 2022/9/6 We prepared the real data of fengyuan automatic weather station (AWS) from Central Weather Bureau(CWB) to be the dataset for predicting the chance if the concentration of PM2.5 will exceed. PM2.5 Exceeded Prediction 02 Dataset preprocessing
  • 13. 2022/9/6 We need to preprocess the dataset and let it fit the input model format of the neural network in TFLearn.
  • 14. 2022/9/6 List all data to an one-dimensional array with the sorted 18 parameters. Reshape data to 320x18 array. (18 a group) Insert id numbers to the first column. Add parameters row and export the dataset csv file.
  • 15. 2022/9/6 Classify and mask the values of PM2.5 to 0 and 1. PM2.5 Exceeded Prediction 02 Source code modification
  • 16. 2022/9/6 Designate PM2.5 as target predict parameter. Based on the case of titanic survival predictor, we modified the input data shape to 17 and kept the number of the layers and the nodes of these layers. 17 = 18 parameters – 1 (PM2.5 as predict target parameter)
  • 17. 2022/9/6 Modify the value of epoch and observe the accuracy and the loss rate. We found that the value of epoch is 15, the best accuracy it will be. If exceeding 15, the overfitting would happen. Meanwhile, we modified the value of batch size to 20. Prepare the test data and predict the exceeded rates.
  • 18. 2022/9/6 PM2.5 Exceeded Prediction 02 Conclusion The accuracy of the prediction can achieve to 0.92.
  • 19. 2022/9/6 AI Lab3 Report– 視覺化神經網路 利用TensorFlow進行非線性回歸計算 授課教授:曾恕銘 系所:自動化職碩㇐ 學生姓名:109618515 趙國桓 109618512 彭凱群 AI Lab3 – 視覺化神經網路 • Tensorflow 特點: 1. 強大的機器學習框架 2. 開源且免費 3. 最新版至少支援六種程式語言 4. 使用者可在瀏覽器內訓練並執行模型 5. 針對小型可攜設備,TensorFlow有輕量化版本 jc1 jc2
  • 20. 投影片 38 jc1 jonathan chao, 2021/6/24 jc2 jonathan chao, 2021/6/24
  • 21. 2022/9/6 39 Ai lab3 – 視覺化神經網路 首先設定神經網路層數, 同時也把權重定義在這 裡 40 • 下方的程式碼是用來定義公式, AI Lab3的兩個題目只有公式不同
  • 22. 2022/9/6 41 這㇐段程式碼主要重點為 - o 定義㇐個簡單的神經網 路 o 設定代價函數 o 採用梯度訓練法讓預測 值接近 o 畫出資料點位 42 • 下方的程式碼是用來 做1000次迭代並且 用紅色作為最接近的 資料點連接, 最後執 行時會看到㇐條中心 線會因為資料變化接 近中點
  • 23. 2022/9/6 43 AI Lab3 執行結果 • 上方為完整主程式展示結果 • 下方為例題展示結果 挑戰點 1. 因為㇐直出現呼叫問題, 所以刪除所有環境, 重新安裝 anaconda和tensorflow module 2. 逐行執行程式進行修改 3. 找出兩個function call定義問題 4. ㇐個個module screen 看看還有沒有定義的問題