exam questions

Exam DP-100 All Questions

View all questions & answers for the DP-100 exam

Exam DP-100 topic 3 question 146 discussion

Actual exam question from Microsoft's DP-100
Question #: 146
Topic #: 3
[All DP-100 Questions]

HOTSPOT
-

You manage an Azure Machine Learning workspace named workspace1 by using the Python SDK v2.

The default datastore of workspace1 contains a folder named sample_data. The folder structure contains the following content:

|— sample_data
|— MLTable
|— file1.txt
|— file2.txt
|— file3.txt

You write Python SDK v2 code to materialize the data from the files in the sample_data folder into a Pandas data frame.

You need to complete the Python SDK v2 code to use the MLTable folder as the materialization blueprint.

How should you complete the code? To answer, select the appropriate options in the answer area.

NOTE: Each correct selection is worth one point.

Show Suggested Answer Hide Answer
Suggested Answer:

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
jojashi
5 months ago
CORRECT. from Chat GPT, - The mltable.load function is used to load the data from the folder. It returns an MLTable object. -In Azure Machine Learning, when you have a folder containing an MLTable file along with data files (like file1.txt, file2.txt), the MLTable file serves as a configuration file that describes how to load and parse the data. You should load the directory containing the MLTable file, not the MLTable file itself.
upvoted 1 times
...
sl_mslconsulting
5 months, 1 week ago
Correct. MLTable is a yaml file not a directory. Check the link here: https://learn.microsoft.com/en-us/python/api/mltable/mltable?view=azure-ml-py#mltable-load
upvoted 1 times
...
Lion007
10 months, 1 week ago
WRONG. The Correct answer is: load, ./sample_data/MLTable The Python SDK v2 code is for the purpose of materializing data into a Pandas data frame using an MLTable folder as a blueprint. Materialization in this context refers to the process of loading data from various sources and formats into a Pandas data frame which can be used for data analysis and model training within Python. Given the context and the folder structure in the default datastore of workspace1, the MLTable folder should contain the blueprint for materialization, which includes information about how to read the data and convert it into a format suitable for machine learning tasks. Therefore, to complete the Python SDK v2 code to use the MLTable folder as the materialization blueprint, you would use the load method on the mltable object, and specify the path to the MLTable folder, which is ./sample_data/MLTable. This path points to the MLTable folder in the sample_data directory, which is expected to contain the MLTable file that defines the data to be materialized into a Pandas data frame.
upvoted 4 times
Lion007
10 months, 1 week ago
import mltable tbl = mltable.load("./sample_data/MLTable") df = tbl.to_pandas_dataframe()
upvoted 1 times
...
...
phdykd
1 year, 3 months ago
load and . sample data MLTable
upvoted 4 times
...
damaldon
1 year, 3 months ago
Correct. import mltable # load the previously saved MLTable file tbl = mltable.load("./titanic/") https://learn.microsoft.com/en-us/azure/machine-learning/how-to-mltable?view=azureml-api-2&tabs=cli
upvoted 2 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago