C2 W3 Quiz question

Hello,

Here is a question from the quiz:

“If you think
β
β (hyperparameter for momentum) is between 0.9 and 0.99, which of the following is the recommended way to sample a value for beta?”

Based on the lecture, I believe, the answer is supposed to be beta = 1-10**r where r=[-2,-1]. However, I don’t see this in the answer options. What range of values are being assumed for r in the provided answer options? Can someone please explain me what I am missing here? By the way, I know the right answer but I cannot understand/accept it.
Thank you!

I took that quiz and I did see one of the answers that is basically equivalent to what you describe. Remember that the output of

r = np.random.rand()

will be a number between 0 and 1.

But these quizzes are dynamic and there can be different versions of the various questions, so perhaps I just got lucky.

1 Like

Understood now. Thank you!

1 Like