DP-100 · Question #237
You create a script that trains a convolutional neural network model over multiple epochs and logs the validation loss after each epoch. The script includes arguments for batch size and learning…
The correct answer is E. Run the script in an experiment based on a HyperDriveConfig object. HyperDriveConfig is the correct tool for hyperparameter tuning in Azure ML. It wraps a ScriptRunConfig with a parameter search space (e.g., discrete choices for batch size and learning rate), a primary metric to optimize (in this case, minimize validation loss), a sampling…
Question
Options
- ARun the script in an experiment based on an AutoMLConfig object
- BCreate a PythonScriptStep object for the script and run it in a pipeline
- CUse the Automated Machine Learning interface in Azure Machine Learning studio
- DRun the script in an experiment based on a ScriptRunConfig object
- ERun the script in an experiment based on a HyperDriveConfig object
How the community answered
(37 responses)- A14% (5)
- B3% (1)
- C3% (1)
- D8% (3)
- E73% (27)
Explanation
HyperDriveConfig is the correct tool for hyperparameter tuning in Azure ML. It wraps a ScriptRunConfig with a parameter search space (e.g., discrete choices for batch size and learning rate), a primary metric to optimize (in this case, minimize validation loss), a sampling strategy (random, grid, or Bayesian), and early termination policies. Azure ML then orchestrates multiple child runs across the compute cluster, each testing a different hyperparameter combination, and identifies the run with the lowest validation loss. AutoMLConfig (A) and the AutoML Studio interface (C) automate algorithm and feature selection - not hyperparameter tuning of a custom script. PythonScriptStep (B) is a pipeline step with no tuning capability. ScriptRunConfig (D) runs the script once with fixed parameters, with no search.
Topics
Community Discussion
No community discussion yet for this question.