🌍 All Study Guides📊 Dashboard📰 Blog💡 About
Coursera Microsoft Azure Data Scientist Associate (DP-100) • STUDY MODE

INTRODUCTION – Exam Preparation Course 4

QUESTION 1 OF 9

You have an AirBnB housing dataframe which you preprocessed and filtered down to only the relevant columns.

A
airbnbDF.replaceTempView(“airbnbDF”)
B
spark.udf.register(“sql_udf”, firstInitialFunction)
C
airbnbDF.createTempView(“airbnbDF”)
D
spark.udf.register(sql_udf = firstInitialFunction)
E
airbnbDF.createAndReplaceTempView(“airbnbDF”)
F
spark.udf.register(sql_udf.firstInitialFunction)
G
airbnbDF.createOrReplaceTempView(“airbnbDF”)Correct Answer
QUESTION 2 OF 9

You have a Boston Housing dataset where you find a median value for a number variables such as the number of rooms, per capita crime and economic status of residents.

A
from pyspark.ml.regression import LinearRegression
B
lr = LinearRegression(featuresCol=”features”, labelCol=”medv”)
C
lrModel = lr.fit(bostonFeaturizedDF)
D
lr = LinearRegression(featuresCol=”rm”, labelCol=”medv”)
E
lrModel = lr_fit(bostonFeaturizedDF)
F
from pyspark.ml import LinearRegression
G
lr = LinearRegression(featuresCol=”rm “, labelCol=”medv”)
H
from pyspark import LinearRegressionCorrect Answer
QUESTION 3 OF 9

You are using MLflow to track the runs of a Linear Regression model of an AirBnB dataset.

A
predDF = pipelineModel.estimate(testDF)
B
regressionEvaluator = RegressionEvaluator(labelCol=”price”, predictionCol=”prediction”)
C
rmse = regressionEvaluator.setMetricName(“rmse”).evaluate(predDF)
D
r2 = regressionEvaluator.setMetricName(“r2”).evaluate(predDF)
E
predDF = pipelineModel.evaluate(testDF)
F
predDF = pipelineModel.transform(testDF)Correct Answer
G
regression = RegressionEvaluator(labelCol=”price”, predictionCol=”prediction”)
QUESTION 4 OF 9

You are running Python code interactively in a Conda environment. The environment includes all required Azure Machine Learning SDK and MLflow packages.

A
#1 mlflow.tracking.client = ws, #2 mlflow.set_tracking_uri(ws.get_mlflow_tracking_uri()), #3 mlflow.active_run(), #4 mlflow.log_metric
B
#1 mlflow.set_tracking_uri(ws.get_mlflow_tracking_uri()), #2 mlflow.get_run(‘mlflow-experiment), #3 mlflow.start_run(), #4 mlflow.log_metric
C
#1 mlflow.set_tracking_uri(ws.get_mlflow_tracking_uri()), #2 mlflow.set_experiment(‘mlflow-experiment), #3 mlflow.start_run(), #4 mlflow.log_metricCorrect Answer
D
#1 mlflow.set_tracking_uri(ws.get_mlflow_tracking_uri()), #2 mlflow.get_run(‘mlflow-experiment), #3 mlflow.start_run(), #4 run.log()
QUESTION 5 OF 9

You are evaluating a Python NumPy array that contains six data points defined as follows: data = [10, 20, 30, 40, 50, 60]

A
K-fold, 3, array
B
K-fold, 3, dataCorrect Answer
C
K-means, 6, array
QUESTION 6 OF 9

You use the following code to run a script as an experiment in Azure Machine Learning: 

A
files = run.get_fine_names()Correct Answer
B
 files = run.get_properties()
C
files = run.get_metrics()
D
run.get_details_with_logs()
QUESTION 7 OF 9

You have a Boston Housing dataset from which you want to train a model to predict the value of housing based on one or more input measures.

A
from pyspark.ml.feature import VectorAssemblerCorrect Answer
B
featureCols = [“rm”, “age”, “tax”]
C
assembler = VectorAssembler(inputCols=featureCols, outputCol=”features”)
D
bostonFeaturizedDF = assembler.transform(bostonDF)
E
display(bostonFeaturizedDF)
F
bostonFeaturizedDF = vector.assembler_transform(bostonDF)
G
assembler = Vector(inputCols=featureCols, outputCol=”features”)
H
assembler = VectorAssembler(Cols=featureCols, outputCol=”features”)
QUESTION 8 OF 9

You are running a training experiment on remote compute in Azure Machine Learning.

A
#1 import mlflow, #2 mlflow.start_run(), #3 logger.info(‘ ..’), #4 mlflow.end_run()
B
#1 from azureml.core import Run, #2 run = Run.get_context(), #3 logger.info(‘ ..’), #4 run.complete()Correct Answer
C
#1 import mlflow, #2 mlflow.start_run(), #3 mlflow.log_metric(‘ ..’), #4 mlflow.end_run()
D
#1 import logging, #2 mlflow.start_run(), #3 mlflow.log_metric(‘ ..’), #4 run.complete()
QUESTION 9 OF 9

You’re working with the Boston Housing dataset and you want to tune the Hyperparameters for the Linear Regression algorithm you’re using.

A
from pyspark.ml.tuning import ParamGridBuilder
B
paramGrid = (ParamGridBuilder().addGrid(lr.maxIter, [1, 10, 100])
C
.addGrid(lr.fitIntercept, [True, False])
D
.addGrid(lr.standardization, [True, False])
E
.search())
F
paramGrid = (ParamGridBuilder(lr)
G
.addGrid(lr.maxIter, [1, 10, 100])
H
.run()
I
)
J
.create()
K
paramGrid = (ParamGridBuilder()
L
.build()
M
)10. 

Ready to test your recall?

You have an AirBnB housing dataframe which you preprocessed and filtered down to only the relevant columns.

A
airbnbDF.replaceTempView(“airbnbDF”)
B
spark.udf.register(“sql_udf”, firstInitialFunction)
C
airbnbDF.createTempView(“airbnbDF”)
D
spark.udf.register(sql_udf = firstInitialFunction)
E
airbnbDF.createAndReplaceTempView(“airbnbDF”)
F
spark.udf.register(sql_udf.firstInitialFunction)
G
airbnbDF.createOrReplaceTempView(“airbnbDF”)

How confident are you in this answer?