
Answer-first summary for fast verification
Answer: hp.normal(label, mu, sigma)
The correct function is `hp.normal(label, mu, sigma)`, which is specifically designed to generate values from a normal distribution with the given mean and standard deviation. The other options are not suitable for this purpose: - `hp.qnormal(label, mu, sigma, q)`: Generates values from a q-normal distribution, not a standard normal distribution. - `hp.quniform(label, low, high, q)`: Generates values from a q-uniform distribution, not a normal distribution. - `hp.loguniform(label, low, high)`: Generates values from a log-uniform distribution, not a normal distribution. Using `hp.normal(label, mu, sigma)` is ideal for hyperparameter optimization when you need values centered around a mean with a specific spread.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
Which Hyperopt function should you use to generate a real value that follows a normal distribution with a specified mean (mu) and standard deviation (sigma)?
A
hp.quniform(label, low, high, q)
B
hp.loguniform(label, low, high)
C
hp.normal(label, mu, sigma)
D
hp.qnormal(label, mu, sigma, q)