Skip to content

Instantly share code, notes, and snippets.

@afranzi
Created October 23, 2018 21:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save afranzi/7a9ab4f1d6b8427171ce4176a071e717 to your computer and use it in GitHub Desktop.
Save afranzi/7a9ab4f1d6b8427171ce4176a071e717 to your computer and use it in GitHub Desktop.
Log model by using the MLflow Tracking Server
with mlflow.start_run():
... model ...
mlflow.log_param("source", wine_path)
mlflow.log_param("alpha", alpha)
mlflow.log_param("l1_ratio", l1_ratio)
mlflow.log_metric("rmse", rmse)
mlflow.log_metric("r2", r2)
mlflow.log_metric("mae", mae)
mlflow.set_tag('domain', 'wine')
mlflow.set_tag('predict', 'quality')
mlflow.sklearn.log_model(lr, "model")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment