SlideShare ist ein Scribd-Unternehmen logo
1 von 64
Downloaden Sie, um offline zu lesen
Copyright Notice
These slides are distributed under the Creative Commons License.
DeepLearning.AI makes these slides available for educational purposes. You may not
use or distribute these slides for commercial purposes. You may make copies of these
slides and use or distribute them for educational purposes as long as you
cite DeepLearning.AI as the source of the slides.
For the rest of the details of the license, see
https://creativecommons.org/licenses/by-sa/2.0/legalcode
Neural Architecture Search
Welcome
Neural Architecture Search
Hyperparameter tuning
Neural Architecture Search
● Neural architecture search (NAS) is is a technique for automating the
design of artificial neural networks
● It helps finding the optimal architecture
● This is a search over a huge space
● AutoML is an algorithm to automate this search
Types of parameters in ML Models
● Trainable parameters:
○ Learned by the algorithm during training
○ e.g. weights of a neural network
● Hyperparameters:
○ set before launching the learning process
○ not updated in each training step
○ e.g: learning rate or the number of units in a dense layer
Manual hyperparameter tuning is not scalable
● Hyperparameters can be numerous even for small models
● e.g shallow DNN:
○ Architecture choices
○ activation functions
○ Weight initialization strategy
○ Optimization hyperparameters such as learning rate, stop condition
● Tuning them manually can be a real brain teaser
● Tuning helps with model performance
Automating hyperparameter tuning with Keras Tuner
● Automation is key: open source resources to the rescue
● Keras Tuner:
○ Hyperparameter tuning with Tensorflow 2.0.
○ Many methods available
Neural Architecture Search
Keras Autotuner Demo
Setting up libraries and dataset
import tensorflow as tf
from tensorflow import keras
mnist = tf.keras.datasets.mnist
(x_train, y_train),(x_test, y_test) = mnist.load_data()
x_train, x_test = x_train / 255.0, x_test / 255.0
Deep learning “Hello world!”
model = tf.keras.models.Sequential([
tf.keras.layers.Flatten(input_shape=(28, 28)),
tf.keras.layers.Dense(512, activation='relu'),
tf.keras.layers.Dropout(0.2),
tf.keras.layers.Dense(10, activation='softmax')
])
model.compile(optimizer='adam',
loss='sparse_categorical_crossentropy',
metrics=['accuracy'])
model.fit(x_train, y_train, epochs=5)
model.evaluate(x_test, y_test)
Model performance
Epoch 1/5
1875/1875 - 10s 5ms/step - loss: 0.3603 - accuracy: 0.8939
Epoch 2/5
1875/1875 - 10s 5ms/step - loss: 0.1001 - accuracy: 0.9695
Epoch 3/5
1875/1875 - 10s 5ms/step - loss: 0.0717 - accuracy: 0.9781
Epoch 4/5
1875/1875 - 10s 5ms/step - loss: 0.0515 - accuracy: 0.9841
Epoch 5/5
1875/1875 - 10s 5ms/step - loss: 0.0432 - accuracy: 0.9866
Parameters rational: if any
model = tf.keras.models.Sequential([
tf.keras.layers.Flatten(input_shape=(28, 28)),
tf.keras.layers.Dense(512, activation='relu'),
tf.keras.layers.Dropout(0.2),
tf.keras.layers.Dense(10, activation='softmax')
])
model.compile(optimizer='adam',
loss='sparse_categorical_crossentropy',
metrics=['accuracy'])
model.fit(x_train, y_train, epochs=5)
model.evaluate(x_test, y_test)
Is this architecture optimal?
● Do the model need more or less hidden units to perform well?
● How does model size affect the convergence speed?
● Is there any trade off between convergence speed, model size and
accuracy?
● Search automation is the natural path to take
● Keras tuner built in search functionality.
Automated search with Keras tuner
# First, install Keras Tuner
!pip install -q -U keras-tuner
# Import Keras Tuner after it has been installed
import kerastuner as kt
Building model with iterative search
def model_builder(hp):
model = keras.Sequential()
model.add(keras.layers.Flatten(input_shape=(28, 28)))
hp_units = hp.Int('units', min_value=16, max_value=512, step=16)
model.add(keras.layers.Dense(units=hp_units, activation='relu'))
model.add(tf.keras.layers.Dropout(0.2))
model.add(keras.layers.Dense(10))
model.compile(optimizer='adam',loss='sparse_categorical_crossentropy',
metrics=['accuracy'])
return model
Search strategy
tuner = kt.Hyperband(model_builder,
objective='val_accuracy',
max_epochs=10,
factor=3,
directory='my_dir',
project_name='intro_to_kt')
Other flavors: RandomSearch // BayesianOptimization // Sklearn
Callback configuration
stop_early =
tf.keras.callbacks.EarlyStopping(monitor='val_loss',
patience=5)
tuner.search(x_train,
y_train,
epochs=50,
validation_split=0.2,
callbacks=[stop_early])
Search output
Trial 24 Complete [00h 00m 22s]
val_accuracy: 0.3265833258628845
Best val_accuracy So Far: 0.5167499780654907
Total elapsed time: 00h 05m 05s
Search: Running Trial #25
Hyperparameter |Value |Best Value So Far
units |192 |48
tuner/epochs |10 |2
tuner/initial_e...|4 |0
tuner/bracket |1 |2
tuner/round |1 |0
tuner/trial_id |a2edc917bda476c...|None
Back to your model
model = tf.keras.models.Sequential([
tf.keras.layers.Flatten(input_shape=(28, 28)),
tf.keras.layers.Dense(48, activation='relu'),
tf.keras.layers.Dropout(0.2),
tf.keras.layers.Dense(10, activation='softmax')
])
Training output
Epoch 1/5
1875/1875 - 3s 1ms/step - loss: 0.6427 - accuracy: 0.8090
Epoch 2/5
1875/1875 - 3s 1ms/step - loss: 0.2330 - accuracy: 0.9324
Epoch 3/5
1875/1875 - 3s 1ms/step - loss: 0.1835 - accuracy: 0.9448
Epoch 4/5
1875/1875 - 3s 1ms/step - loss: 0.1565 - accuracy: 0.9515
Epoch 5/5
1875/1875 - 3s 1ms/step - loss: 0.1393 - accuracy: 0.9564
AutoML
Intro to AutoML
Outline
● Introduction to AutoML
● Neural Architecture Search
● Search Space and Search Strategies
● Performance Estimation
● AutoML on the Cloud
Automated Machine Learning (AutoML)
Auto ML
Data
Pipeline
Model
Training
Model
Deployment
Model
Monitoring
Discovery
Data
Validation
Feature
Engineering
Train Model
Data
Ingestion
Validate
Model
AutoML automates the entire ML workflow
Neural Architecture Search
Search Space
A
Neural Architecture a ∈ A
Architecture is picked from
this space by search
strategy
Accuracy
Latency
Performance Estimation Strategy
Performance
Search Strategy
Neural Architecture Search
● AutoML automates the development of ML
models
● AutoML is not specific to a particular type of
model.
● NAS is a technique for automating the design of
artificial neural networks (ANN).
NAS
AutoML
● Neural Architecture Search (NAS) is a subfield
of AutoML
Real-World example: Meredith Digital
Media & Entertainment
AutoML
Content
Classification
Faster
Classification
Builds Loyalty
Trend Discovery
Human Level
Performance
AutoML
Understanding Search
Spaces
Types of Search Spaces
input
Macro
L0
L1
LN-1
LN
output
Li
Node
Connection
Micro
input
output
Macro Architecture Search Space
Contains individual layers and connection types
input
Chain structured
space
L0
L1
LN-1
LN
output
input
Complex search
space
output
Micro Architecture Search Space
Normal Cell
Reduction Cell
Repertoire
input
output
input
output
input
output
input
AutoML
Search Strategies
1. Grid Search
2. Random Search
3. Bayesian Optimization
4. Evolutionary Algorithms
5. Reinforcement Learning
A Few Search Strategies
Grid Search and Random Search
● Grid Search
○ Exhaustive search approach on fixed grid
values
● Random Search
● Both suited for smaller search spaces.
● Both quickly fail with growing size of search
space.
Bayesian Optimization
● Assumes that a specific probability
distribution, is underlying the performance.
● Tested architectures constrain the
probability distribution and guide the
selection of the next option.
● In this way, promising architectures can be
stochastically determined and tested.
Parents Selected
Parents
Parents
+
Offspring
X
X X
Select
+
remove
Replace
with
offspring
Repeat
Evolutionary Methods
Reinforcement Learning
State
● The performance estimation
strategy determines the reward
Reward
● Agents goal is to maximize a
reward
Agent
● The available options are
selected from the search space Action
Search
space
Controller (RNN)
Train child network with
architecture A to get accuracy R
Agent Controller,
Reward
Accuracy,
Action
Child
Network
Sample architecture
A with probability p
Compute gradient of p and scale it
by R to update the controller
Reinforcement Learning for NAS
AutoML
Measuring AutoML Efficacy
Validation Accuracy
Performance Estimation Strategy
Computationally
heavy
Time consuming +
High GPU demand
Expensive
1. Lower fidelity estimates
2. Learning Curve Extrapolation
3. Weight Inheritance/ Network Morphisms
Strategies to Reduce the Cost
Lower Fidelity Estimates
Reduce
training time
Data subset
Low resolution
images
Fewer filters
and cells
● Reduce cost but
underestimates performance
● Works if relative ranking of
architectures does not
change due to lower fidelity
estimates
● Recent research shows this
is not the case
Learning Curve Extrapolation
● Requires predicting the learning curve reliably
X
X
● Extrapolates based on initial learning.
● Removes poor performers
Weight Inheritance/Network Morphisms
● Initialize weights of new architectures based on previously trained
architectures
○ Similar to transfer learning
● Uses Network Morphism
● Underlying function unchanged
○ New network inherits knowledge from parent network.
○ Computational speed up: only a few days of GPU usage
○ Network size not inherently bounded
AutoML
AutoML on the Cloud
Popular Cloud Offerings
Cloud-based AutoML
Amazon SageMaker Autopilot
Microsoft Azure Automated Machine Learning
Google Cloud AutoML
Amazon SageMaker Autopilot
Amazon SageMaker Autopilot
Raw tabular data
in S3 bucket
Select prediction
target
Automated
model selection,
training, and
tuning
Notebooks for
visibility and
control
Select best model
Key features
Quick Iteration
High quality models
Performance ranked
Selected features
Notebooks for reproducibility
Typical use cases
Price Prediction:
● Stocks
● Utilities
● Real estate
Risk Assessment:
● Individuals
● Assets
● Companies
Churn Prediction:
● Prevent customer loss
● Pattern analysis
Microsoft Azure
Automated Machine Learning
Microsoft Azure AutoML
Automated Feature
Selection
Automated Model
Selection
Optimized model
Hyperparameter
Tuning
Key features
Quick customization:
● Model
● Control settings
Data Visualization
Automated Feature Engineering
Intelligent stopping
Key features
● Experiment summaries
● Metric visualizations
Model Interpretability
Pattern Discovery
Google Cloud AutoML
Google Cloud AutoML
● Accessible to beginners
● Train high-quality models
● GUI Based
● Pipeline life-cycle
● Neural Architecture Search
● Transfer Learning
● Data labeling
● Data cleaning
Structured Data AutoML Tables
Automatically build and deploy state-of-the-art machine learning models on
structured data.
Cloud AutoML Products
Sight Auto ML Vision
Derive insights from images in the
cloud or at the edge.
Auto ML Video Intelligence
Enable powerful content discovery
and engaging video experiences.
Language AutoML Natural Language
Reveal the structure and meaning
of text through machine learning.
Auto ML Translation
Dynamically detect and translate
between languages.
AutoML Vision Products
AutoML Vision Object Detection AutoML Vision Edge Object Detection
Auto ML Vision Classification AutoML Vision Edge Image Classification
AutoML Video Intelligence Classification
Enables you to train machine learning models, to classify shots and segments on
your videos according to your own defined labels.
AutoML Video Intelligence Products
AutoML Video Object detection
Enables you to train machine learning models to detect and track multiple
objects, in shots and segments.
So what’s in the secret sauce?
How do these Cloud offerings perform AutoML?
● We don’t know (or can’t say) and they’re not about to
tell us
● The underlying algorithms will be similar to what
we’ve learned
● The algorithms will evolve with the state of the art
AutoML
Assignment Setup
Setup
AutoML
1
Steps to Classify Images using AutoML Vision
2
Create
Dataset
Upload images to
Cloud Storage and
create dataset in
Vision.
3
Train Evaluate
4
Deploy
model for
serving
5
Deploy
6
Test
Generate
predictions using
deployed model
● Qwiklabs provides real cloud environments that help developers and IT
professionals learn cloud platforms and software.
● Check tutorial on Qwiklabs basics
Setup
AutoML
1 2
Create
Dataset
3
Train Evaluate
4 5
Deploy
6
Test
It’s your turn!

Weitere ähnliche Inhalte

Was ist angesagt?

Introduction to machine learning
Introduction to machine learningIntroduction to machine learning
Introduction to machine learningSanghamitra Deb
 
Developing Recommendation System to provide a Personalized Learning experienc...
Developing Recommendation System to provide a PersonalizedLearning experienc...Developing Recommendation System to provide a PersonalizedLearning experienc...
Developing Recommendation System to provide a Personalized Learning experienc...Sanghamitra Deb
 
Deep Dive into Hyperparameter Tuning
Deep Dive into Hyperparameter TuningDeep Dive into Hyperparameter Tuning
Deep Dive into Hyperparameter TuningShubhmay Potdar
 
Using Deep Learning to Find Similar Dresses
Using Deep Learning to Find Similar DressesUsing Deep Learning to Find Similar Dresses
Using Deep Learning to Find Similar DressesHJ van Veen
 
Automated Machine Learning (Auto ML)
Automated Machine Learning (Auto ML)Automated Machine Learning (Auto ML)
Automated Machine Learning (Auto ML)Hayim Makabee
 
Workshop - Introduction to Machine Learning with R
Workshop - Introduction to Machine Learning with RWorkshop - Introduction to Machine Learning with R
Workshop - Introduction to Machine Learning with RShirin Elsinghorst
 
Data Wrangling For Kaggle Data Science Competitions
Data Wrangling For Kaggle Data Science CompetitionsData Wrangling For Kaggle Data Science Competitions
Data Wrangling For Kaggle Data Science CompetitionsKrishna Sankar
 
Hyperparameter Tuning
Hyperparameter TuningHyperparameter Tuning
Hyperparameter TuningJon Lederman
 
Learning keras by building dogs-vs-cats image classifier
Learning keras by building dogs-vs-cats image classifierLearning keras by building dogs-vs-cats image classifier
Learning keras by building dogs-vs-cats image classifierJian Wu
 
Feature Engineering - Getting most out of data for predictive models
Feature Engineering - Getting most out of data for predictive modelsFeature Engineering - Getting most out of data for predictive models
Feature Engineering - Getting most out of data for predictive modelsGabriel Moreira
 
Machine Learning Fundamentals
Machine Learning FundamentalsMachine Learning Fundamentals
Machine Learning FundamentalsSigOpt
 
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...Evaluate deep q learning for sequential targeted marketing with 10-fold cross...
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...Jian Wu
 
NLP and Deep Learning for non_experts
NLP and Deep Learning for non_expertsNLP and Deep Learning for non_experts
NLP and Deep Learning for non_expertsSanghamitra Deb
 
Feature Engineering
Feature EngineeringFeature Engineering
Feature EngineeringHJ van Veen
 
Using Optimal Learning to Tune Deep Learning Pipelines
Using Optimal Learning to Tune Deep Learning PipelinesUsing Optimal Learning to Tune Deep Learning Pipelines
Using Optimal Learning to Tune Deep Learning PipelinesScott Clark
 
SigOpt for Machine Learning and AI
SigOpt for Machine Learning and AISigOpt for Machine Learning and AI
SigOpt for Machine Learning and AISigOpt
 
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...SigOpt
 
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learnt
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learntKaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learnt
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learntEugene Yan Ziyou
 

Was ist angesagt? (20)

Introduction to machine learning
Introduction to machine learningIntroduction to machine learning
Introduction to machine learning
 
Intro to ml_2021
Intro to ml_2021Intro to ml_2021
Intro to ml_2021
 
Developing Recommendation System to provide a Personalized Learning experienc...
Developing Recommendation System to provide a PersonalizedLearning experienc...Developing Recommendation System to provide a PersonalizedLearning experienc...
Developing Recommendation System to provide a Personalized Learning experienc...
 
Deep Dive into Hyperparameter Tuning
Deep Dive into Hyperparameter TuningDeep Dive into Hyperparameter Tuning
Deep Dive into Hyperparameter Tuning
 
Using Deep Learning to Find Similar Dresses
Using Deep Learning to Find Similar DressesUsing Deep Learning to Find Similar Dresses
Using Deep Learning to Find Similar Dresses
 
Automated Machine Learning (Auto ML)
Automated Machine Learning (Auto ML)Automated Machine Learning (Auto ML)
Automated Machine Learning (Auto ML)
 
Workshop - Introduction to Machine Learning with R
Workshop - Introduction to Machine Learning with RWorkshop - Introduction to Machine Learning with R
Workshop - Introduction to Machine Learning with R
 
Data Wrangling For Kaggle Data Science Competitions
Data Wrangling For Kaggle Data Science CompetitionsData Wrangling For Kaggle Data Science Competitions
Data Wrangling For Kaggle Data Science Competitions
 
Hyperparameter Tuning
Hyperparameter TuningHyperparameter Tuning
Hyperparameter Tuning
 
Learning keras by building dogs-vs-cats image classifier
Learning keras by building dogs-vs-cats image classifierLearning keras by building dogs-vs-cats image classifier
Learning keras by building dogs-vs-cats image classifier
 
Feature Engineering - Getting most out of data for predictive models
Feature Engineering - Getting most out of data for predictive modelsFeature Engineering - Getting most out of data for predictive models
Feature Engineering - Getting most out of data for predictive models
 
Machine Learning Fundamentals
Machine Learning FundamentalsMachine Learning Fundamentals
Machine Learning Fundamentals
 
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...Evaluate deep q learning for sequential targeted marketing with 10-fold cross...
Evaluate deep q learning for sequential targeted marketing with 10-fold cross...
 
Bayesian Global Optimization
Bayesian Global OptimizationBayesian Global Optimization
Bayesian Global Optimization
 
NLP and Deep Learning for non_experts
NLP and Deep Learning for non_expertsNLP and Deep Learning for non_experts
NLP and Deep Learning for non_experts
 
Feature Engineering
Feature EngineeringFeature Engineering
Feature Engineering
 
Using Optimal Learning to Tune Deep Learning Pipelines
Using Optimal Learning to Tune Deep Learning PipelinesUsing Optimal Learning to Tune Deep Learning Pipelines
Using Optimal Learning to Tune Deep Learning Pipelines
 
SigOpt for Machine Learning and AI
SigOpt for Machine Learning and AISigOpt for Machine Learning and AI
SigOpt for Machine Learning and AI
 
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...
MLconf 2017 Seattle Lunch Talk - Using Optimal Learning to tune Deep Learning...
 
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learnt
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learntKaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learnt
Kaggle Otto Challenge: How we achieved 85th out of 3,514 and what we learnt
 

Ähnlich wie C3 w1

Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsScott Clark
 
Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsSigOpt
 
Using SigOpt to Tune Deep Learning Models with Nervana Cloud
Using SigOpt to Tune Deep Learning Models with Nervana CloudUsing SigOpt to Tune Deep Learning Models with Nervana Cloud
Using SigOpt to Tune Deep Learning Models with Nervana CloudSigOpt
 
Computer Vision for Beginners
Computer Vision for BeginnersComputer Vision for Beginners
Computer Vision for BeginnersSanghamitra Deb
 
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scala
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scalaAutomate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scala
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scalaChetan Khatri
 
The Power of Auto ML and How Does it Work
The Power of Auto ML and How Does it WorkThe Power of Auto ML and How Does it Work
The Power of Auto ML and How Does it WorkIvo Andreev
 
B4UConference_machine learning_deeplearning
B4UConference_machine learning_deeplearningB4UConference_machine learning_deeplearning
B4UConference_machine learning_deeplearningHoa Le
 
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...Universitat Politècnica de Catalunya
 
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...Lviv Data Science Summer School
 
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...Databricks
 
in5490-classification (1).pptx
in5490-classification (1).pptxin5490-classification (1).pptx
in5490-classification (1).pptxMonicaTimber
 
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016MLconf
 
MLConf 2016 SigOpt Talk by Scott Clark
MLConf 2016 SigOpt Talk by Scott ClarkMLConf 2016 SigOpt Talk by Scott Clark
MLConf 2016 SigOpt Talk by Scott ClarkSigOpt
 
AWS re:Invent 2018 - AIM401 - Deep Learning using Tensorflow
AWS re:Invent 2018 - AIM401 - Deep Learning using TensorflowAWS re:Invent 2018 - AIM401 - Deep Learning using Tensorflow
AWS re:Invent 2018 - AIM401 - Deep Learning using TensorflowJulien SIMON
 
Everything you need to know about AutoML
Everything you need to know about AutoMLEverything you need to know about AutoML
Everything you need to know about AutoMLArpitha Gurumurthy
 
Amazon SageMaker 內建機器學習演算法 (Level 400)
Amazon SageMaker 內建機器學習演算法 (Level 400)Amazon SageMaker 內建機器學習演算法 (Level 400)
Amazon SageMaker 內建機器學習演算法 (Level 400)Amazon Web Services
 
PR-232: AutoML-Zero:Evolving Machine Learning Algorithms From Scratch
PR-232:  AutoML-Zero:Evolving Machine Learning Algorithms From ScratchPR-232:  AutoML-Zero:Evolving Machine Learning Algorithms From Scratch
PR-232: AutoML-Zero:Evolving Machine Learning Algorithms From ScratchSunghoon Joo
 
StackNet Meta-Modelling framework
StackNet Meta-Modelling frameworkStackNet Meta-Modelling framework
StackNet Meta-Modelling frameworkSri Ambati
 
AI powered emotion recognition: From Inception to Production - Global AI Conf...
AI powered emotion recognition: From Inception to Production - Global AI Conf...AI powered emotion recognition: From Inception to Production - Global AI Conf...
AI powered emotion recognition: From Inception to Production - Global AI Conf...Vandana Kannan
 

Ähnlich wie C3 w1 (20)

Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning Models
 
Using Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning ModelsUsing Bayesian Optimization to Tune Machine Learning Models
Using Bayesian Optimization to Tune Machine Learning Models
 
Using SigOpt to Tune Deep Learning Models with Nervana Cloud
Using SigOpt to Tune Deep Learning Models with Nervana CloudUsing SigOpt to Tune Deep Learning Models with Nervana Cloud
Using SigOpt to Tune Deep Learning Models with Nervana Cloud
 
Computer Vision for Beginners
Computer Vision for BeginnersComputer Vision for Beginners
Computer Vision for Beginners
 
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scala
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scalaAutomate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scala
Automate ml workflow_transmogrif_ai-_chetan_khatri_berlin-scala
 
The Power of Auto ML and How Does it Work
The Power of Auto ML and How Does it WorkThe Power of Auto ML and How Does it Work
The Power of Auto ML and How Does it Work
 
B4UConference_machine learning_deeplearning
B4UConference_machine learning_deeplearningB4UConference_machine learning_deeplearning
B4UConference_machine learning_deeplearning
 
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
Training Deep Networks with Backprop (D1L4 Insight@DCU Machine Learning Works...
 
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...
Master defence 2020 -Volodymyr Lut-Neural Architecture Search: a Probabilisti...
 
presentation.ppt
presentation.pptpresentation.ppt
presentation.ppt
 
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...
Apache Spark Based Hyper-Parameter Selection and Adaptive Model Tuning for De...
 
in5490-classification (1).pptx
in5490-classification (1).pptxin5490-classification (1).pptx
in5490-classification (1).pptx
 
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016
Scott Clark, Co-Founder and CEO, SigOpt at MLconf SF 2016
 
MLConf 2016 SigOpt Talk by Scott Clark
MLConf 2016 SigOpt Talk by Scott ClarkMLConf 2016 SigOpt Talk by Scott Clark
MLConf 2016 SigOpt Talk by Scott Clark
 
AWS re:Invent 2018 - AIM401 - Deep Learning using Tensorflow
AWS re:Invent 2018 - AIM401 - Deep Learning using TensorflowAWS re:Invent 2018 - AIM401 - Deep Learning using Tensorflow
AWS re:Invent 2018 - AIM401 - Deep Learning using Tensorflow
 
Everything you need to know about AutoML
Everything you need to know about AutoMLEverything you need to know about AutoML
Everything you need to know about AutoML
 
Amazon SageMaker 內建機器學習演算法 (Level 400)
Amazon SageMaker 內建機器學習演算法 (Level 400)Amazon SageMaker 內建機器學習演算法 (Level 400)
Amazon SageMaker 內建機器學習演算法 (Level 400)
 
PR-232: AutoML-Zero:Evolving Machine Learning Algorithms From Scratch
PR-232:  AutoML-Zero:Evolving Machine Learning Algorithms From ScratchPR-232:  AutoML-Zero:Evolving Machine Learning Algorithms From Scratch
PR-232: AutoML-Zero:Evolving Machine Learning Algorithms From Scratch
 
StackNet Meta-Modelling framework
StackNet Meta-Modelling frameworkStackNet Meta-Modelling framework
StackNet Meta-Modelling framework
 
AI powered emotion recognition: From Inception to Production - Global AI Conf...
AI powered emotion recognition: From Inception to Production - Global AI Conf...AI powered emotion recognition: From Inception to Production - Global AI Conf...
AI powered emotion recognition: From Inception to Production - Global AI Conf...
 

Kürzlich hochgeladen

CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordAsst.prof M.Gokilavani
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)simmis5
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...roncy bisnoi
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performancesivaprakash250
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Serviceranjana rawat
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlysanyuktamishra911
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxupamatechverse
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escortsranjana rawat
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSRajkumarAkumalla
 

Kürzlich hochgeladen (20)

CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptx
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
 

C3 w1

  • 1. Copyright Notice These slides are distributed under the Creative Commons License. DeepLearning.AI makes these slides available for educational purposes. You may not use or distribute these slides for commercial purposes. You may make copies of these slides and use or distribute them for educational purposes as long as you cite DeepLearning.AI as the source of the slides. For the rest of the details of the license, see https://creativecommons.org/licenses/by-sa/2.0/legalcode
  • 4. Neural Architecture Search ● Neural architecture search (NAS) is is a technique for automating the design of artificial neural networks ● It helps finding the optimal architecture ● This is a search over a huge space ● AutoML is an algorithm to automate this search
  • 5. Types of parameters in ML Models ● Trainable parameters: ○ Learned by the algorithm during training ○ e.g. weights of a neural network ● Hyperparameters: ○ set before launching the learning process ○ not updated in each training step ○ e.g: learning rate or the number of units in a dense layer
  • 6. Manual hyperparameter tuning is not scalable ● Hyperparameters can be numerous even for small models ● e.g shallow DNN: ○ Architecture choices ○ activation functions ○ Weight initialization strategy ○ Optimization hyperparameters such as learning rate, stop condition ● Tuning them manually can be a real brain teaser ● Tuning helps with model performance
  • 7. Automating hyperparameter tuning with Keras Tuner ● Automation is key: open source resources to the rescue ● Keras Tuner: ○ Hyperparameter tuning with Tensorflow 2.0. ○ Many methods available
  • 9. Setting up libraries and dataset import tensorflow as tf from tensorflow import keras mnist = tf.keras.datasets.mnist (x_train, y_train),(x_test, y_test) = mnist.load_data() x_train, x_test = x_train / 255.0, x_test / 255.0
  • 10. Deep learning “Hello world!” model = tf.keras.models.Sequential([ tf.keras.layers.Flatten(input_shape=(28, 28)), tf.keras.layers.Dense(512, activation='relu'), tf.keras.layers.Dropout(0.2), tf.keras.layers.Dense(10, activation='softmax') ]) model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy']) model.fit(x_train, y_train, epochs=5) model.evaluate(x_test, y_test)
  • 11. Model performance Epoch 1/5 1875/1875 - 10s 5ms/step - loss: 0.3603 - accuracy: 0.8939 Epoch 2/5 1875/1875 - 10s 5ms/step - loss: 0.1001 - accuracy: 0.9695 Epoch 3/5 1875/1875 - 10s 5ms/step - loss: 0.0717 - accuracy: 0.9781 Epoch 4/5 1875/1875 - 10s 5ms/step - loss: 0.0515 - accuracy: 0.9841 Epoch 5/5 1875/1875 - 10s 5ms/step - loss: 0.0432 - accuracy: 0.9866
  • 12. Parameters rational: if any model = tf.keras.models.Sequential([ tf.keras.layers.Flatten(input_shape=(28, 28)), tf.keras.layers.Dense(512, activation='relu'), tf.keras.layers.Dropout(0.2), tf.keras.layers.Dense(10, activation='softmax') ]) model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy']) model.fit(x_train, y_train, epochs=5) model.evaluate(x_test, y_test)
  • 13. Is this architecture optimal? ● Do the model need more or less hidden units to perform well? ● How does model size affect the convergence speed? ● Is there any trade off between convergence speed, model size and accuracy? ● Search automation is the natural path to take ● Keras tuner built in search functionality.
  • 14. Automated search with Keras tuner # First, install Keras Tuner !pip install -q -U keras-tuner # Import Keras Tuner after it has been installed import kerastuner as kt
  • 15. Building model with iterative search def model_builder(hp): model = keras.Sequential() model.add(keras.layers.Flatten(input_shape=(28, 28))) hp_units = hp.Int('units', min_value=16, max_value=512, step=16) model.add(keras.layers.Dense(units=hp_units, activation='relu')) model.add(tf.keras.layers.Dropout(0.2)) model.add(keras.layers.Dense(10)) model.compile(optimizer='adam',loss='sparse_categorical_crossentropy', metrics=['accuracy']) return model
  • 16. Search strategy tuner = kt.Hyperband(model_builder, objective='val_accuracy', max_epochs=10, factor=3, directory='my_dir', project_name='intro_to_kt') Other flavors: RandomSearch // BayesianOptimization // Sklearn
  • 18. Search output Trial 24 Complete [00h 00m 22s] val_accuracy: 0.3265833258628845 Best val_accuracy So Far: 0.5167499780654907 Total elapsed time: 00h 05m 05s Search: Running Trial #25 Hyperparameter |Value |Best Value So Far units |192 |48 tuner/epochs |10 |2 tuner/initial_e...|4 |0 tuner/bracket |1 |2 tuner/round |1 |0 tuner/trial_id |a2edc917bda476c...|None
  • 19. Back to your model model = tf.keras.models.Sequential([ tf.keras.layers.Flatten(input_shape=(28, 28)), tf.keras.layers.Dense(48, activation='relu'), tf.keras.layers.Dropout(0.2), tf.keras.layers.Dense(10, activation='softmax') ])
  • 20. Training output Epoch 1/5 1875/1875 - 3s 1ms/step - loss: 0.6427 - accuracy: 0.8090 Epoch 2/5 1875/1875 - 3s 1ms/step - loss: 0.2330 - accuracy: 0.9324 Epoch 3/5 1875/1875 - 3s 1ms/step - loss: 0.1835 - accuracy: 0.9448 Epoch 4/5 1875/1875 - 3s 1ms/step - loss: 0.1565 - accuracy: 0.9515 Epoch 5/5 1875/1875 - 3s 1ms/step - loss: 0.1393 - accuracy: 0.9564
  • 22. Outline ● Introduction to AutoML ● Neural Architecture Search ● Search Space and Search Strategies ● Performance Estimation ● AutoML on the Cloud
  • 23. Automated Machine Learning (AutoML) Auto ML Data Pipeline Model Training Model Deployment Model Monitoring Discovery
  • 25. Neural Architecture Search Search Space A Neural Architecture a ∈ A Architecture is picked from this space by search strategy Accuracy Latency Performance Estimation Strategy Performance Search Strategy
  • 26. Neural Architecture Search ● AutoML automates the development of ML models ● AutoML is not specific to a particular type of model. ● NAS is a technique for automating the design of artificial neural networks (ANN). NAS AutoML ● Neural Architecture Search (NAS) is a subfield of AutoML
  • 27. Real-World example: Meredith Digital Media & Entertainment AutoML Content Classification Faster Classification Builds Loyalty Trend Discovery Human Level Performance
  • 29. Types of Search Spaces input Macro L0 L1 LN-1 LN output Li Node Connection Micro input output
  • 30. Macro Architecture Search Space Contains individual layers and connection types input Chain structured space L0 L1 LN-1 LN output input Complex search space output
  • 31. Micro Architecture Search Space Normal Cell Reduction Cell Repertoire input output input output input output input
  • 33. 1. Grid Search 2. Random Search 3. Bayesian Optimization 4. Evolutionary Algorithms 5. Reinforcement Learning A Few Search Strategies
  • 34. Grid Search and Random Search ● Grid Search ○ Exhaustive search approach on fixed grid values ● Random Search ● Both suited for smaller search spaces. ● Both quickly fail with growing size of search space.
  • 35. Bayesian Optimization ● Assumes that a specific probability distribution, is underlying the performance. ● Tested architectures constrain the probability distribution and guide the selection of the next option. ● In this way, promising architectures can be stochastically determined and tested.
  • 37. Reinforcement Learning State ● The performance estimation strategy determines the reward Reward ● Agents goal is to maximize a reward Agent ● The available options are selected from the search space Action Search space
  • 38. Controller (RNN) Train child network with architecture A to get accuracy R Agent Controller, Reward Accuracy, Action Child Network Sample architecture A with probability p Compute gradient of p and scale it by R to update the controller Reinforcement Learning for NAS
  • 40. Validation Accuracy Performance Estimation Strategy Computationally heavy Time consuming + High GPU demand Expensive
  • 41. 1. Lower fidelity estimates 2. Learning Curve Extrapolation 3. Weight Inheritance/ Network Morphisms Strategies to Reduce the Cost
  • 42. Lower Fidelity Estimates Reduce training time Data subset Low resolution images Fewer filters and cells ● Reduce cost but underestimates performance ● Works if relative ranking of architectures does not change due to lower fidelity estimates ● Recent research shows this is not the case
  • 43. Learning Curve Extrapolation ● Requires predicting the learning curve reliably X X ● Extrapolates based on initial learning. ● Removes poor performers
  • 44. Weight Inheritance/Network Morphisms ● Initialize weights of new architectures based on previously trained architectures ○ Similar to transfer learning ● Uses Network Morphism ● Underlying function unchanged ○ New network inherits knowledge from parent network. ○ Computational speed up: only a few days of GPU usage ○ Network size not inherently bounded
  • 46. Popular Cloud Offerings Cloud-based AutoML Amazon SageMaker Autopilot Microsoft Azure Automated Machine Learning Google Cloud AutoML
  • 48. Amazon SageMaker Autopilot Raw tabular data in S3 bucket Select prediction target Automated model selection, training, and tuning Notebooks for visibility and control Select best model
  • 49. Key features Quick Iteration High quality models Performance ranked Selected features Notebooks for reproducibility
  • 50. Typical use cases Price Prediction: ● Stocks ● Utilities ● Real estate Risk Assessment: ● Individuals ● Assets ● Companies Churn Prediction: ● Prevent customer loss ● Pattern analysis
  • 52. Microsoft Azure AutoML Automated Feature Selection Automated Model Selection Optimized model Hyperparameter Tuning
  • 53. Key features Quick customization: ● Model ● Control settings Data Visualization Automated Feature Engineering Intelligent stopping
  • 54. Key features ● Experiment summaries ● Metric visualizations Model Interpretability Pattern Discovery
  • 56. Google Cloud AutoML ● Accessible to beginners ● Train high-quality models ● GUI Based ● Pipeline life-cycle ● Neural Architecture Search ● Transfer Learning ● Data labeling ● Data cleaning
  • 57. Structured Data AutoML Tables Automatically build and deploy state-of-the-art machine learning models on structured data. Cloud AutoML Products Sight Auto ML Vision Derive insights from images in the cloud or at the edge. Auto ML Video Intelligence Enable powerful content discovery and engaging video experiences. Language AutoML Natural Language Reveal the structure and meaning of text through machine learning. Auto ML Translation Dynamically detect and translate between languages.
  • 58. AutoML Vision Products AutoML Vision Object Detection AutoML Vision Edge Object Detection Auto ML Vision Classification AutoML Vision Edge Image Classification
  • 59. AutoML Video Intelligence Classification Enables you to train machine learning models, to classify shots and segments on your videos according to your own defined labels. AutoML Video Intelligence Products AutoML Video Object detection Enables you to train machine learning models to detect and track multiple objects, in shots and segments.
  • 60. So what’s in the secret sauce? How do these Cloud offerings perform AutoML? ● We don’t know (or can’t say) and they’re not about to tell us ● The underlying algorithms will be similar to what we’ve learned ● The algorithms will evolve with the state of the art
  • 62. Setup AutoML 1 Steps to Classify Images using AutoML Vision 2 Create Dataset Upload images to Cloud Storage and create dataset in Vision. 3 Train Evaluate 4 Deploy model for serving 5 Deploy 6 Test Generate predictions using deployed model
  • 63. ● Qwiklabs provides real cloud environments that help developers and IT professionals learn cloud platforms and software. ● Check tutorial on Qwiklabs basics Setup AutoML 1 2 Create Dataset 3 Train Evaluate 4 5 Deploy 6 Test