Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam Certified Machine Learning Associate All Questions

View all questions & answers for the Certified Machine Learning Associate exam

Exam Certified Machine Learning Associate topic 1 question 14 discussion

Actual exam question from Databricks's Certified Machine Learning Associate
Question #: 14
Topic #: 1
[All Certified Machine Learning Associate Questions]

A data scientist is attempting to tune a logistic regression model logistic using scikit-learn. They want to specify a search space for two hyperparameters and let the tuning process randomly select values for each evaluation.
They attempt to run the following code block, but it does not accomplish the desired task:

Which of the following changes can the data scientist make to accomplish the task?

  • A. Replace the GridSearchCV operation with RandomizedSearchCV
  • B. Replace the GridSearchCV operation with cross_validate
  • C. Replace the GridSearchCV operation with ParameterGrid
  • D. Replace the random_state=0 argument with random_state=1
  • E. Replace the penalty= ['12', '11'] argument with penalty=uniform ('12', '11')
Show Suggested Answer Hide Answer
Suggested Answer: A 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
Deuterium44
2 weeks, 3 days ago
Selected Answer: A
A: The data scientist wants to perform random hyperparameter sampling for tuning the logistic regression model. However, GridSearchCV performs an exhaustive search over all possible combinations of the provided parameter values, not a random selection. To accomplish random sampling of hyperparameters, they should use RandomizedSearchCV, which samples a specified number of random combinations from the defined search space. With RandomizedSearchCV, they can specify a distribution (e.g., uniform) for continuous hyperparameters (like C) and use a list of discrete options for categorical hyperparameters (like penalty), enabling the desired random sampling approach.
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...