Etapele modelului

Introducere în MLflow

Weston Bassler

Senior MLOps Engineer

Medii software

Diagrama mediilor de dezvoltare, staging și producție

Introducere în MLflow

Etapele modelului MLflow

  • Atribuite versiunilor de model
  • Etape predefinite:

    • None
    • Staging
    • Production
    • Archived
  • O singură etapă la un moment dat

Introducere în MLflow

Etape predefinite

Etape predefinite

Introducere în MLflow

None

Etapa None

Introducere în MLflow

Staging

Etapa Staging

Introducere în MLflow

Production

Etapa de producție

Introducere în MLflow

Archived

Etapa de arhivare

Introducere în MLflow

Tranziția modelelor

transition-ui

# Import MLFlow Client
from mlflow import MlflowClient
client = MlflowClient()

# Transition to Staging client.transition_model_version_stage( name="Unicorn", version=3, stage="Staging" )
Introducere în MLflow

Tranziție la etapa Staging

# Transition to Staging
client.transition_model_version_stage(name="Unicorn", version=3, stage="Staging")
<ModelVersion: creation_timestamp=1679693470034, current_stage='Staging', 
description=None, last_updated_timestamp=1679699050734, name='Unicorn', 
run_id='a1454f2865e449f8835f38f71e53e547', run_link=None, 
source='./mlruns/1/a1454f2865e449f8835f38f71e53e547/artifacts/model', 
status='READY', status_message=None, tags={}, user_id=None, version=3>
Introducere în MLflow

Interfața Registry

staging-ui

Introducere în MLflow

Tranziție la producție

# Transition to Production
client.transition_model_version_stage(name="Unicorn", version=3, 
                                      stage="Production")
<ModelVersion: creation_timestamp=1679693470034, current_stage='Production', 
description=None, last_updated_timestamp=1679699633297, name='Unicorn', 
run_id='a1454f2865e449f8835f38f71e53e547', run_link=None, 
source='./mlruns/1/a1454f2865e449f8835f38f71e53e547/artifacts/model', 
status='READY', status_message=None, tags={}, user_id=None, version=3>
Introducere în MLflow

Să exersăm!

Introducere în MLflow

Preparing Video For Download...