You are using hyper parameter tuning to train an optimal model.
Your training script calculates the area under the curve (AUC) metric for the trained model like this:
--
y_scores = model.predict_proba(X_test)
auc = roc_auc_score(y_test,y_scores[:,1])
--
You define the hyperdrive configuration like this:
--
hyperdrive = HyperDriveConfig(estimator=sklearn_estimator,
hyperparameter_sampling=grid_sampling,
policy=None,
primary_metric_name='AUC',
primary_metric_goal=PrimaryMetricGoal.MAXIMIZE,
max_total_runs=6,
max_concurrent_runs=4)
--
Which code should you add to the training script?
Wähle eine der folgenden: