QuestionQ128

VerifiedModel Development

A data scientist needs to tune a set of hyperparameters for a machine learning model. They have wrapped a Spark ML model in the objective function objective_function and have defined the search space search_space.

As a result, they have the following code block:

Question Image

Which change must they make to the preceding code block to accomplish the task?

Explanation

For an objective function that trains a distributed Spark MLlib model, Hyperopt should use Trials rather than SparkTrials. SparkTrials is intended for objective functions that run single-machine algorithms, whereas Trials supports distributed training algorithms such as MLlib.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!