In this post, I’m sharing a quick review of the Build and Operate Machine Learning Solutions with Azure course, along with helpful insights for anyone getting ready to take the DP-100 certification exam.
Just wrapped up this third course in the Microsoft Azure Data Scientist Associate Professional Certificate? You’re getting closer to the DP-100 exam, and this course takes things further by diving into real-world ML operations using the Azure Machine Learning Python SDK. It’s all about building scalable solutions—from experiment tracking and training to deployment and monitoring. If you’re working toward mastering the cloud-side of machine learning, this course will level up your skills and help you feel more confident for test day — and I’ve got the review to help guide your prep.
Build and Operate Machine Learning Solutions with Azure
Table of Contents
Test prep Quiz Answer | Week 1
Question 1)
You installed the Azure Machine Learning Python SDK and you want to use it to create a workspace named “aml-workspace” on your subscription.
How do you code this in Python?
from azureml.core import Workspace
ws = Workspace.create(name=’aml-workspace’,
subscription_id=’123456-abc-123…’,
resource_group=’aml-resources’,
create_resource_group=True,
location=’eastus’
)
Question 2)
You installed the Azure Machine Learning CLI extension and you want to use it to create an ML workspace in an existing resource group. Which Azure CLI command does this?
- az ml ws create -w ‘aml-workspace’ -g ‘aml-resources’
- new az ml workspace create -w ‘aml-workspace’ -g ‘aml-resources’
- az ml workspace create -w ‘aml-workspace’ -g ‘aml-resources’
- az ml new workspace create -w ‘aml-workspace’ -g ‘aml-resources’
Question 3)
Which of the following package managers and CLI commands can you use to install the Azure Machine Learning SDK for Python?
- pip install azureml-sdk
- yarn install azureml-sdk
- nuget azureml-sdk
- npm install azureml-sdk
Question 4)
If you want to connect to your Azure ML workspace using a configuration file, which Python command can you use?
- from azureml.core import Workspace
ws = Workspace.from_config()
Question 5)
After an experiment run has been completed, what run object method can you use to list the generated files?
- list_file_names
- get_file_names
- download_file
- download_files
Question 6)
After you run an experiment to train a model, you want to store the model in the Azure ML workspace, so it can be available to other experiments and services. How can you do this?
- Save the experiment script as a notebook
- Save the model as a file in a compute instance
- Save the model as a file in a Key Vault instance
- Register the model in the workspace
Question 7)
If you want to view the models you registered in Azure ML studio using the Model object, which Python command can you use?
- from azureml.core import Model
for model in Model.list(ws):
print(model.name, ‘version:’, model.version)
Test prep Quiz Answers | Week 2
Question 1)
Which Python commands should you use to create and register a tabular dataset using the from_delimited_files method of the Dataset.Tabular class?
- from azureml.core import Dataset
blob_ds = ws.get_default_datastore()
csv_paths = [(blob_ds, ‘data/files/current_data.csv’),
(blob_ds, ‘data/files/archive/*.csv’)]
tab_ds = Dataset.Tabular.from_delimited_files(path=csv_paths)
tab_ds = tab_ds.register(workspace=ws, name=’csv_table’)
Question 2)
You’re creating a file dataset using the from_files method of the Dataset.File class.
You also want to register it in the workspace with the name img_files. Which SDK commands can you use?
- from azureml.core import Dataset
blob_ds = ws.get_default_datastore()
file_ds = Dataset.File.from_files(path=(blob_ds, ‘data/files/images/*.jpg’))
file_ds = file_ds.register(workspace=ws, name=’img_files’)
Question 3
What methods can you use from the Dataset class to retrieve a dataset after registering it? Select all that apply.
- find_by_id
- get_by_id
- find_by_name
- get_by_name
Question 4)
To retrieve a specific version of a data set, which SDK commands should you use?
- img_ds = Dataset.get_by_name(workspace=ws, name=’img_files’, version=’2’)
- img_ds = Dataset.get_by_name(workspace=ws, name=’img_files’, version_2)
- img_ds = Dataset.get_by_name(workspace=ws, name=’img_files’, version=2)
- img_ds = Dataset.get_by_name(workspace=ws, name=’img_files’, version(2))
Question 5)
Which SDK commands can you use to view the registered environments in your workspace?
- from azureml.core import Environment
env_names = Environment.list(workspace=ws)
for env_name in env_names:
print(‘Name:’,env_name)
Question 6)
You are defining a compute configuration for a managed compute target using the SDK.
Which of the below commands is correct?
- compute_config = AmlCompute.provisioning_configuration(vm_size=’STANDARD_DS11_V2′,
min_nodes=0, max_nodes=4,
vm_priority=’dedicated’)
Question 7)
You created a compute target and now you want to use it for an experiment. You want to specify the compute target using a ComputeTarget object. Which of the SDK commands below can you use?
- compute_name = “aml-cluster”
training_cluster = ComputeTarget(workspace=ws,
name=compute_name)
training_env = Environment.get(workspace=ws, name=’training_environment’)
script_config = ScriptRunConfig(source_directory=’my_dir’,
script=’script.py’,
environment=training_env,
compute_target=training_cluster)
Test prep Quiz Answers | Week 3
Question 1)
You defined three steps named step1, step2, and step3 for a pipeline you want to create.
You now want to assign those steps to the pipeline and run it as an experiment.
Which of the SDK commands below can you use?
- train_pipeline = Pipeline(workspace = ws, steps = [step1,step2,step3])
experiment = Experiment(workspace = ws, name = ‘training-pipeline’)
pipeline_run = experiment.submit(train_pipeline)
Question 2)
To publish a pipeline you created, which SDK commands should you use?
published_pipeline = pipeline.publish(name=’training_pipeline’,
description=’Model training pipeline’,
version=’1.0′)
Question 3)
The parameters for a pipeline have to be defined before publishing it.
- True
- False
Question 4)
After publishing a parametrized pipeline, you can pass parameter values in the JSON payload for the REST interface. Which SDK commands can you use for this?
- response = requests.post(rest_endpoint,
headers=auth_header,
json={“ExperimentName”: “run_training_pipeline”,
“ParameterAssignments”: {“reg_rate”: 0.1}})
Question 5)
You want to create a schedule for your pipeline. What object can you define for this task?
- ScheduleTimer
- ScheduleRecurrence
- ScheduleConfig
- ScheduleSync
Question 6)
You want to configure an AKS cluster as a compute target for your service to be deployed on.
Which SDK commands do the job?
- from azureml.core.compute import ComputeTarget, AksCompute
cluster_name = ‘aks-cluster’
compute_config = AksCompute.provisioning_configuration(location=’eastus’)
production_cluster = ComputeTarget.create(ws, cluster_name, compute_config)
production_cluster.wait_for_completion(show_output=True)
Question 7)
What are the default authentication methods for ACI services and AKS services? Select all that apply.
- Token-based for AKS services.
- Disabled for ACI services
- Disabled for AKS services
- Token-based for ACI services
- Key-based for AKS services
Test prep Quiz Answers | Week 4
Question 1)
To register a model using a reference to the Run used to train the model, which SDK commands can you use?
- from azureml.core import Model
run.register_model( model_name=’classification_model’,
model_path=’outputs/model.pkl’,
description=’A classification model’)
Question 2)
Which of the following SDK commands can you use to create a parallel run step?
- parallelrun_step = ParallelRunStep(
name=’batch-score’,
parallel_run_config=parallel_run_config,
inputs=[batch_data_set.as_named_input(‘batch_data’)],
output=output_dir,
arguments=[],
allow_reuse=True
Question 3)
After the run of the pipeline has completed, which code can you use to retrieve the parallel_run_step.txt file from the output of the step?
- for root, dirs, files in os.walk(‘results’):
for file in files:
if file.endswith(‘parallel_run_step.txt’):
result_file = os.path.join(root,file)
Question 4)
You want to define a search space for hyperparameter tuning. The batch_size hyperparameter can have the value 128, 256, or 512 and the learning_rate hyperparameter can have values from a normal distribution with a mean of 10 and a standard deviation of 3. How can you code this in Python?
- from azureml.train.hyperdrive import choice, normal
param_space = {
‘–batch_size’: choice(128, 256, 512),
‘–learning_rate’: normal(10, 3)
}
Question 5)
How does random sampling select values for hyperparameters?
- It tries every possible combination of parameters in the search space
- It tries to select parameter combinations that will result in improved performance from the previous selection
- From a mix of discrete and continuous values
Question 6)
Bayesian sampling can be used only with choice, uniform and quniform parameter expressions, and it can be combined with an early-termination policy.
- True
- False
Question 7)
You want to implement a median stopping policy. How can you code this in Python?
- from azureml.train.hyperdrive import MedianStoppingPolicy
early_termination_policy = MedianStoppingPolicy(evaluation_interval=1,
delay_evaluation=5)
Test prep Quiz Answers | Week 5
Question 1)
You need to retrieve the primary metric for a regression task. How can you code this in Python?
- from azureml.train.automl.utilities import get_primary_metrics
get_primary_metrics(‘regression’)
Question 2)
You need to retrieve the best run and its model. How can you code that with the SDK?
- best_run, fitted_model = automl_run.get_output()
best_run_metrics = best_run.get_metrics()
for metric_name in best_run_metrics:
metric = best_run_metrics[metric_name]
print(metric_name, metric)
Question 3)
How can you code an instance of a MimicExplainer for a model named loan_model?
- from interpret.ext.blackbox import MimicExplainer
from interpret.ext.glassbox import DecisionTreeExplainableModel
mim_explainer = MimicExplainer(model=loan_model,
initialization_examples=X_test,
explainable_model = DecisionTreeExplainableModel,
features=[‘loan_amount’,’income’,’age’,’marital_status’],
classes=[‘reject’, ‘approve’])
Question 4)
How can you code an instance of a TabularExplainer for a model named loan_model?
- from interpret.ext.blackbox import TabularExplainer
tab_explainer = TabularExplainer(model=loan_model,
initialization_examples=X_test,
features=[‘loan_amount’,’income’,’age’,’marital_status’],
classes=[‘reject’, ‘approve’])
Question 5)
How can you code a PFIExplainer for a model named loan_model?
- from interpret.ext.blackbox import PFIExplainer
pfi_explainer = PFIExplainer(model = loan_model,
features=[‘loan_amount’,’income’,’age’,’marital_status’],
classes=[‘reject’, ‘approve’])
Question 6)
You need to retrieve local feature importance from a TabularExplainer. How can you code this in the SDK?
- local_tab_explanation = tab_explainer.explain_local(X_test[0:5])
local_tab_features = local_tab_explanation.get_ranked_local_names()
local_tab_importance = local_tab_explanation.get_ranked_local_values()
Question 7)
Which packages do you need to install in the run environment to be able to create an explanation in the experiment script? Select all that apply.
- azureml-contrib-interpret
- azureml-blackbox
- azureml-interpret
- azureml-explainer
Test prep Quiz Answers | Week 6
Question 1)
Which parity constraint can be used with any of the mitigation algorithms to minimize disparity in the selection rate across sensitive feature groups?
- Error rate parity
- Bounded group loss
- Demographic parity
- Equalized odds
Question 2)
Which parity constraint can be used with any of the mitigation algorithms to minimize disparity in combined true positive rate and false_positive_rate across sensitive feature groups?
- Error rate parity
- False-positive rate parity
- True positive rate parity
- Equalized odds
Question 3)
You are training a binary classification model to determine who should be targeted in a marketing campaign. How can you assess if the model is fair and will not discriminate based on ethnicity?
- Remove the ethnicity feature from the training dataset.
- Compare disparity between selection rates and performance metrics across ethnicities.
- Evaluate each trained model with a validation dataset, and use the model with the highest accuracy score. An accurate model is inherently fair.
Question 4)
When deploying a new real-time service, Application Insights can be enabled in the deployment configuration for the service. How would you code that using the SDK?
- dep_config = AciWebservice.deploy_configuration(cpu_cores = 1,
memory_gb = 1,
enable_app_insights=True)
Question 5)
For web services that have already been deployed, you can update them and enable the Application Insight using the Azure ML SDK. How would you code that?
- service = ws.webservices[‘my-svc’]
service.update(enable_app_insights=True)
Question 6)
You want to back fill a dataset monitor based on monthly changes in data for the previous 3 months. How would you code that in the SDK?
- import datetime as dt
backfill = monitor.backfill( dt.datetime.now() – dt.timedelta(months=3), dt.datetime.now()) - import datetime as dt
backfill = monitor.backfill( dt.datetime.now(), dt.timedelta(months=3), dt.datetime.now()) - import datetime as dt
backfill = monitor_backfill( dt.datetime.now(), dt.timedelta(months=3), dt.datetime.now()) - import datetime as dt
backfill = monitor_backfill( dt.datetime.now() – dt.timedelta(months=3), dt.datetime.now())
Question 7)
You want to schedule a data drift monitor to run every day and send an alert if the drift magnitude is greater than 0.2. How would you code that in Python?
- alert_email = AlertConfiguration(‘[email protected]’)
monitor = DataDriftDetector.create_from_datasets(ws, ‘dataset-drift-detector’,
baseline_data_set, target_data_set,
compute_target=cpu_cluster,
frequency=’Day’, latency=2,
drift_threshold=.2,
alert_configuration=alert_email)
You might also like: Microsoft Azure Machine Learning for Data Scientists Quiz Answers + Review
Review
I recently completed the “Build and Operate Machine Learning Solutions with Azure” course on Coursera, and it’s one of the most practical and technical courses in the series so far. With six in-depth modules, it teaches you how to use the Azure ML Python SDK to train, deploy, and manage machine learning models in a scalable, enterprise-ready environment.
It builds directly on your knowledge of Python and popular ML frameworks, helping you operationalize everything in the Azure ecosystem.
What stood out to me was how clearly the course walks through each step of the ML lifecycle in Azure—especially the hands-on SDK usage, which really matters if you’re aiming to go beyond drag-and-drop ML. You’ll also get practice with managing resources, running experiments, and monitoring models responsibly at scale. Whether you’re fine-tuning your skills for the DP-100 exam or building cloud-based ML systems professionally, this course is a strong checkpoint to test your readiness and build real confidence.