Complete the code to start a Docker container running an ML model.
docker run -d --name ml_model [1] my_ml_image-v instead of -p to expose ports.The -p 5000:5000 option maps the container's port 5000 to the host, allowing access to the ML model service.
Complete the command to build a Docker image for your ML model.
docker build -t [1] .The -t flag tags the image with a name, here ml_model_image, which is used to run the container later.
Fix the error in the Dockerfile line to set the working directory.
WORKDIR [1]The WORKDIR command requires an absolute path like /app to set the working directory inside the container.
Fill both blanks to create a dictionary comprehension that maps model names to their versions if version is greater than 1.
{model: version [1] model_list if version [2] 1}< instead of > in the condition.The comprehension syntax is {key: value for key, value in iterable if condition}. Here, for and > are needed.
Fill all three blanks to filter and transform a list of model names to uppercase if they start with 'a'.
[[1].upper() for [2] in models if [3].startswith('a')]
The list comprehension iterates over m in models, filters by m.startswith('a'), and transforms with m.upper().