You create an Azure Machine Learning workspace. The workspace contains a dataset named sample_dataset, a compute instance, and a compute cluster.
You must create a two-stage pipeline that will prepare data in the dataset and then train and register a model based on the prepared data.
The first stage of the pipeline contains the following code:
You need to identify the location containing the output of the first stage of the script that you can use as input for the second stage.
Which storage location should you use?
A. workspaceblobstore datastore
B. workspacefilestore datastore
C. compute instance
D. compute_cluster
Show Answer
Correct Answer: A
Explanation: In Azure Machine Learning pipelines, outputs from a pipeline step (for example, via OutputFileDatasetConfig) are written to the workspace’s default datastore unless otherwise specified. The default datastore is an Azure Blob Storage container named workspaceblobstore, which is designed to store experiment artifacts, intermediate data, and pipeline outputs. Compute instances or clusters are transient execution environments, and workspacefilestore is intended mainly for user files such as notebooks, not pipeline stage outputs.
Question 223
HOTSPOT -
You create a new Azure Databricks workspace.
You configure a new cluster for long-running tasks with mixed loads on the compute cluster as shown in the image below.
Use the drop-down menus to select the answer choice that completes each statement based on the information presented in the graphic.
NOTE: Each correct selection is worth one point.
Hot Area:
Show Answer
Correct Answer: No
No
Explanation: The cluster mode is Standard, not High Concurrency, so user code does not run in separate processes.
Autoscaling is enabled with a minimum of 2 and maximum of 8 workers, so the number of workers is not fixed for the job duration.
Question 224
HOTSPOT -
You create an Azure Machine Learning workspace named workspace1. You assign a custom role to a user of workspace1.
The custom role has the following JSON definition:
Instructions: For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:
Show Answer
Correct Answer: No
No
Yes
Explanation: Actions is '*' but several critical permissions are explicitly removed by NotActions.
Deleting compute resources is denied by 'Microsoft.MachineLearningServices/workspaces/computes/*/delete'.
Logging/writing metrics is a data-plane operation on runs and does not require 'workspaces/write', so it remains allowed.
Question 225
You use the Azure Machine Learning designer to create and run a training pipeline.
The pipeline must be run every night to inference predictions from a large volume of files. The folder where the files will be stored is defined as a dataset.
You need to publish the pipeline as a REST service that can be used for the nightly inferencing run.
What should you do?
A. Create a batch inference pipeline
B. Set the compute target for the pipeline to an inference cluster
C. Create a real-time inference pipeline
D. Clone the pipeline
Show Answer
Correct Answer: A
Explanation: Nightly inferencing over a large volume of files stored as a dataset is an offline, scheduled scoring scenario. In Azure Machine Learning designer, this is done by publishing a batch inference pipeline as a REST service, which is designed for processing large datasets asynchronously on a schedule. Real-time inference and inference clusters are for low-latency online scoring, and cloning does not address deployment or scheduling.
Question 226
You create a batch inference pipeline by using the Azure ML SDK. You run the pipeline by using the following code: from azureml.pipeline.core import Pipeline from azureml.core.experiment import Experiment pipeline = Pipeline(workspace=ws, steps=[parallelrun_step]) pipeline_run = Experiment(ws, 'batch_pipeline').submit(pipeline)
You need to monitor the progress of the pipeline execution.
What are two possible ways to achieve this goal? Each correct answer presents a complete solution.
NOTE: Each correct selection is worth one point.
A. Run the following code in a notebook:
B. Use the Inference Clusters tab in Machine Learning Studio.
C. Use the Activity log in the Azure portal for the Machine Learning workspace.
D. Run the following code in a notebook:
E. Run the following code and monitor the console output from the PipelineRun object:
Show Answer
Correct Answer: D, E
Explanation: You can monitor a batch inference pipeline run directly from code. One option is to use the Azure ML notebook widget (RunDetails) to visualize the pipeline run status and step progress interactively. Another option is to call wait_for_completion(show_output=True) on the PipelineRun object, which streams execution status, logs, and provides a link to the run details in Azure ML Studio. Both methods fully satisfy the requirement to monitor pipeline execution progress.
Question 227
HOTSPOT -
You create a Python script named train.py and save it in a folder named scripts. The script uses the scikit-learn framework to train a machine learning model.
You must run the script as an Azure Machine Learning experiment on your local workstation.
You need to write Python code to initiate an experiment that runs the train.py script.
How should you complete the code segment? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Hot Area:
Explanation: ScriptRunConfig requires the folder containing the code (source_directory), the entry-point file relative to that folder (script), and the execution environment defining dependencies (environment).
Question 228
You create a binary classification model. The model is registered in an Azure Machine Learning workspace. You use the Azure Machine Learning Fairness SDK to assess the model fairness.
You develop a training script for the model on a local machine.
You need to load the model fairness metrics into Azure Machine Learning studio.
What should you do?
A. Implement the download_dashboard_by_upload_id function
B. Implement the create_group_metric_set function
C. Implement the upload_dashboard_dictionary function
D. Upload the training script
Show Answer
Correct Answer: C
Explanation: To load locally computed fairness metrics into Azure Machine Learning studio, you must upload the fairness dashboard data to the workspace. The Fairness SDK provides upload_dashboard_dictionary for this purpose, which uploads the fairness metrics and insights so they can be viewed in Azure ML Studio. The other options either create metrics locally or download existing dashboards, not upload them.
Question 229
HOTSPOT -
You create an Azure Machine Learning workspace and load a Python training script named train.py in the src subfolder. The dataset used to train your model is available locally.
You run the following script to train the model:
Instructions: For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:
Show Answer
Correct Answer: 1. No
2. No
3. No
Explanation: 1) The ScriptRunConfig specifies an Azure ML compute target (cpu-cluster); it does not fall back to local compute on failure.
2) Local datasets are not automatically uploaded to a new datastore; this must be done explicitly.
3) The environment is created from a Conda YAML specification file, not from an existing local Conda environment.
Question 230
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You plan to use a Python script to run an Azure Machine Learning experiment. The script creates a reference to the experiment run context, loads data from a file, identifies the set of unique values for the label column, and completes the experiment run:
The experiment must record the unique labels in the data as metrics for the run that can be reviewed later.
You must add code to the script to record the unique label values as run metrics at the point indicated by the comment.
Solution: Replace the comment with the following code:
run.log_list('Label Values', label_vals)
Does the solution meet the goal?
A. Yes
B. No
Show Answer
Correct Answer: A
Explanation: The goal is to record the unique label values as run metrics. Using run.log_list with the collection of unique labels accomplishes this, allowing the values to be reviewed later in the run’s metrics. Therefore, the solution meets the stated goal.
Question 231
DRAG DROP -
You are using a Git repository to track work in an Azure Machine Learning workspace.
You need to authenticate a Git account by using SSH.
Which three actions should you perform in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.
Select and Place:
Show Answer
Correct Answer: Generate a public/private key pair
Add the public key to the Git account
Clone the Git repository by using an SSH repository URL
Explanation: SSH authentication requires first creating an SSH key pair. The public key is then registered with the Git account to enable authentication. Once configured, the repository can be securely cloned using the SSH URL, which uses the private key locally.
$19
Get all 477 questions with detailed answers and explanations
Instant download HTML + PDF delivered the moment payment clears.
Secure Stripe checkout we never see or store your card details.
7-day refund if files are defective see our refund policy.