0
0
MLOpsdevops~10 mins

Container registries for ML in MLOps - Interactive Code Practice

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

Complete the code to tag a Docker image before pushing it to a container registry.

MLOps
docker tag my-ml-model:latest myregistry.azurecr.io/[1]
Drag options to blanks, or click blank then click option'
Amlmodel:v1
Blatest
Cmodel123
Dimage
Attempts:
3 left
💡 Hint
Common Mistakes
Using just 'latest' without the registry prefix
Using an invalid tag format
2fill in blank
medium

Complete the command to push the tagged image to the container registry.

MLOps
docker push [1]
Drag options to blanks, or click blank then click option'
Amyregistry/mlmodel
Bmy-ml-model:latest
Cmlmodel:v1
Dmyregistry.azurecr.io/mlmodel:v1
Attempts:
3 left
💡 Hint
Common Mistakes
Pushing without the registry URL
Using an incomplete image name
3fill in blank
hard

Fix the error in the command to login to an Azure container registry.

MLOps
az acr [1] --name myregistry
Drag options to blanks, or click blank then click option'
Acreate
Bpush
Clogin
Dbuild
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'push' instead of 'login'
Using 'create' which is for creating registries
4fill in blank
hard

Fill both blanks to create a dictionary comprehension that filters images with tag 'v1'.

MLOps
images = {name: tag for name, tag in image_list if tag [1] [2]
Drag options to blanks, or click blank then click option'
A==
B'v1'
C'latest'
D!=
Attempts:
3 left
💡 Hint
Common Mistakes
Using '!=' instead of '=='
Comparing to 'latest' instead of 'v1'
5fill in blank
hard

Fill all three blanks to create a dictionary of image names in uppercase with their tags filtered by tag 'stable'.

MLOps
filtered_images = { [1]: [2] for name, [3] in images.items() if [2] == 'stable' }
Drag options to blanks, or click blank then click option'
Aname.upper()
Btag
Dname
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'name' instead of 'name.upper()' for keys
Mixing variable names in comprehension