Microsoft

DP-100 Free Practice Questions — Page 17

Question 169

DRAG DROP - You are developing a machine learning solution by using the Azure Machine Learning designer. You need to create a web service that applications can use to submit data feature values and retrieve a predicted label. 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.

Illustration for DP-100 question 169
Show Answer
Correct Answer: Create and run a training pipeline. Create and run a real-time inference pipeline. Deploy a service to an inference cluster.
Explanation:
A model must first be trained. To expose predictions to applications via a web service, a real-time inference pipeline is required. Finally, the inference pipeline is deployed to an inference cluster to make it accessible as a web service.

Question 170

You are implementing hyperparameter tuning for a model training from a notebook. The notebook is in an Azure Machine Learning workspace. You must configure a grid sampling method over the search space for the num_hidden_layers and batch_size hyperparameters. You need to identify the hyperparameters for the grid sampling. Which hyperparameter sampling approach should you use?

A. uniform
B. qlognormal
C. choice
D. normal
Show Answer
Correct Answer: C
Explanation:
Grid sampling in Azure Machine Learning requires discrete sets of values for each hyperparameter. The `choice` sampling approach is specifically designed for this purpose, allowing you to define explicit lists of values (for example, different numbers of hidden layers and batch sizes). Grid sampling then evaluates all possible combinations of those choices. Continuous distributions like uniform, normal, or qlognormal are not compatible with grid sampling.

Question 171

HOTSPOT - You load data from a notebook in an Azure Machine Learning workspace into a pandas dataframe. The data contains 10,000 records. Each record consists of 10 columns. You must identify the number of missing values in each of the columns. You need to complete the Python code that will return the number of missing values in each of the columns. Which code segments should you use? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-100 question 171
Show Answer
Correct Answer: shape 0
Explanation:
df.shape[0] returns the total number of rows (10,000). df.count() returns the number of non-missing values per column. Subtracting gives the number of missing values in each column.

Question 172

HOTSPOT - You manage an Azure Machine Learning workspace. You create a training script named sample_training_script.py. The script is used to train a predictive model in the conda environment defined by a file named environment.yml. You need to run the script as an experiment. How should you complete the following code segment? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-100 question 172
Show Answer
Correct Answer: ScriptRunConfig submit
Explanation:
In Azure ML v1, a training script is run by creating a ScriptRunConfig that defines the source directory, script, and environment, and then submitting it to an Experiment using the submit() method.

Question 173

HOTSPOT - You have an Azure Machine Learning workspace. You need to use the Azure Machine Learning SDK for Python to create and register the Azure Data Lake Storage Generation 2 datastore for the workspace. How should you complete the following code segment? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-100 question 173
Show Answer
Correct Answer: register_azure_data_lake_gen2 filesystem='test'
Explanation:
To register an Azure Data Lake Storage Gen2 datastore using the Azure ML SDK (azureml-core), the Datastore.register_azure_data_lake_gen2 method is required, and Gen2 uses a filesystem (not a container or database) as the storage unit.

Question 174

You have an Azure Machine Learning workspace. You are connecting an Azure Data Lake Storage Gen2 account to the workspace as a data store. You need to authorize access from the workspace to the Azure Data Lake Storage Gen2 account. What should you use?

A. Service principal
B. SAS token
C. Managed identity
D. Account key
Show Answer
Correct Answer: C
Explanation:
To authorize access from an Azure Machine Learning workspace to an Azure Data Lake Storage Gen2 account, the recommended and modern approach is to use a managed identity. Azure ML workspaces have a system-assigned or user-assigned managed identity that can be granted RBAC roles (such as Storage Blob Data Reader or Contributor) on the ADLS Gen2 account. This enables secure, identity-based access without managing secrets, keys, or tokens, and aligns with Azure best practices.

Question 175

DRAG DROP - You provision an Azure Machine Learning workspace in a new Azure subscription. You need to attach Azure Databricks as a compute resource from the Azure Machine Learning workspace. Which four 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.

Illustration for DP-100 question 175
Show Answer
Correct Answer: 1. From the Azure portal, create an Azure Databricks service. 2. From the Azure portal, launch an Azure Databricks workspace. 3. From the Azure Databricks workspace, generate a personal access token. 4. From Azure Machine Learning Studio, add an attached compute resource.
Explanation:
Azure Databricks must exist and be accessible first. A workspace is launched to manage resources, then a personal access token is generated for authentication. Finally, the Databricks workspace is attached to Azure Machine Learning as a compute resource.

Question 176

You create an Azure Machine Learning workspace. You must configure an event handler to send an email notification when data drift is detected in the workspace datasets. You must minimize development efforts. You need to configure an Azure service to send the notification. Which Azure service should you use?

A. Azure Logic Apps
B. Azure Automation runbook
C. Azure Function apps
D. Azure DevOps pipeline
Show Answer
Correct Answer: A
Explanation:
Azure Logic Apps provides built-in connectors and event-driven workflows that can easily subscribe to Azure Machine Learning events (such as data drift detection) and send email notifications with minimal or no custom code. This best satisfies the requirement to minimize development effort. Other options would require more custom implementation or are not designed for this purpose.

Question 177

You are creating a compute target to train a machine learning experiment. The compute target must support automated machine learning, machine learning pipelines, and Azure Machine Learning designer training. You need to configure the compute target. Which option should you use?

A. Azure HDInsight
B. Azure Machine Learning compute cluster
C. Azure Batch
D. Remote VM
Show Answer
Correct Answer: B
Explanation:
Azure Machine Learning compute clusters are the only compute target that natively supports all three requirements: automated machine learning, machine learning pipelines, and Azure Machine Learning designer training. They are managed, scalable, and fully integrated with Azure ML services, unlike HDInsight, Azure Batch, or remote VMs, which do not support all these features together.

Question 178

HOTSPOT - You create an Azure Data Lake Storage Gen2 storage account named storage1containing a file system named fs1 and a folder named folder1. The contents of folder1 must be accessible from jobs on compute targets in the Azure Machine Learning workspace. You need to construct a URI to reference folder1. How should you construct the URI? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Illustration for DP-100 question 178
Show Answer
Correct Answer: abfss:// [email protected]/folder1
Explanation:
Azure Machine Learning jobs access Azure Data Lake Storage Gen2 using the secure ABFSS scheme. The correct URI format is abfss://<filesystem>@<storageaccount>.dfs.core.windows.net/<path>. Here, the filesystem is fs1, the storage account is storage1, and the path is folder1.

$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.