Mooune_DBU
Databricks Employee
Databricks Employee

There are many ways you can retrieve experiments results using the mlflow API (see example if you want to retrieve and display for only a specific model (assuming you have the `model_name`:

best_models = mlflow.search_runs(filter_string=f'tags.model="{model_name}" and attributes.status = "FINISHED" and metrics.F1 > 0', order_by=['metrics.F1 DESC'], max_results=1)

In Databricks my other favorite way to query runs for ad-hoc analytics is via the "mlflow-experiment" format:

df_client = spark.read.format("mlflow-experiment").load()
df_client.createOrReplaceTempView("vw_client")

Following which one can run queries slice/dice results using SparkSQL:

df_model_selector = spark.sql("""SELECT experiment_id, run_id, metrics.auc as AUC, metrics.F1 as F1, artifact_uri 
 
    FROM vw_client 
    
    WHERE status='FINISHED'
    ORDER BY metrics.f1 desc
 
  """)
display(df_model_selector)