nerdexam
Microsoft

DP-100 · Question #423

You are implementing hyperparameter tuning for a model training from a notebook. The notebook is in an Azure Machine Learning workspace. You must configure a grid sampling method over the search space

The correct answer is C. choice. The choice distribution is required when using grid sampling because grid sampling only supports discrete hyperparameter values. The choice distribution explicitly defines a finite set of allowed values (e.g., choice(2, 4, 8)) over which the grid can be systematically enumerated.

Explore data, and run experiments

Question

You are implementing hyperparameter tuning for a model training from a notebook. The notebook is in an Azure Machine Learning workspace. You must configure a grid sampling method over the search space for the num_hidden_layers and batch_size hyperparameters. You need to identify the hyperparameters for the grid sampling. Which hyperparameter sampling approach should you use?

Options

  • Auniform
  • Bqlognormal
  • Cchoice
  • Dnormal

How the community answered

(23 responses)
  • A
    4% (1)
  • C
    91% (21)
  • D
    4% (1)

Explanation

The choice distribution is required when using grid sampling because grid sampling only supports discrete hyperparameter values. The choice distribution explicitly defines a finite set of allowed values (e.g., choice(2, 4, 8)) over which the grid can be systematically enumerated. The uniform distribution defines a continuous range, which grid sampling cannot enumerate. The normal and qlognormal distributions are continuous or continuous-approximation distributions and are also incompatible with grid sampling. Grid sampling requires every hyperparameter to use choice so that it can construct the full Cartesian product of all specified values.

Topics

#Hyperparameter tuning#Grid sampling#Azure Machine Learning#Model training

Community Discussion

No community discussion yet for this question.

Full DP-100 Practice