0
0
MLOpsdevops~10 mins

Why model versioning enables rollback in MLOps - Test Your Understanding

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to save a model version using MLflow.

MLOps
mlflow.sklearn.log_model(model, '[1]')
Drag options to blanks, or click blank then click option'
Aversion
Bmodel_name
Cartifact_path
Dmodel_version
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'model_version' instead of the artifact path.
Confusing model name with artifact path.
2fill in blank
medium

Complete the code to load a specific model version for rollback.

MLOps
model = mlflow.pyfunc.load_model('models:/[1]/1')
Drag options to blanks, or click blank then click option'
Amodel_name
Bmodel_version
Cversion
Dartifact_path
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'version' instead of model name.
Using artifact path in the registry URI.
3fill in blank
hard

Fix the error in the code to rollback to a previous model version.

MLOps
mlflow.register_model('models:/my_model/[1]', 'my_model')
Drag options to blanks, or click blank then click option'
Alatest
Bcurrent
Cproduction
D1
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'latest' which points to newest, not rollback.
Using stage names instead of version numbers.
4fill in blank
hard

Fill both blanks to update the model stage to enable rollback.

MLOps
client.transition_model_version_stage(name='my_model', version=[1], stage='[2]')
Drag options to blanks, or click blank then click option'
A1
B2
CProduction
DStaging
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong version number.
Using lowercase stage names.
5fill in blank
hard

Fill all three blanks to create a dictionary mapping model versions to stages for rollback.

MLOps
version_stages = [1]: '[2]', [3]: 'Archived'}
Drag options to blanks, or click blank then click option'
A1
BProduction
C2
DStaging
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up version numbers and stage names.
Using wrong stage names.