DP-100 · Question #360
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…
The correct answer is B. No1. The provided solution using Workspace.from_config() is insufficient to guarantee obtaining a reference to a specific 'ml-project' workspace, especially when multiple subscriptions and workspaces exist without explicit parameters.
Question
Exhibit
Options
- AYes
- BNo1
How the community answered
(44 responses)- A14% (6)
- B86% (38)
Why each option
The provided solution using `Workspace.from_config()` is insufficient to guarantee obtaining a reference to a specific 'ml-project' workspace, especially when multiple subscriptions and workspaces exist without explicit parameters.
`Workspace.from_config()` might load *a* workspace, but it does not inherently ensure that the loaded workspace is specifically 'ml-project' when multiple workspaces and subscriptions are present without further explicit configuration or parameters.
The `Workspace.from_config()` method by default attempts to load workspace configuration from a local file. In a scenario with multiple subscriptions and workspaces, this method alone cannot reliably target a specific workspace like 'ml-project' without explicit parameters for subscription ID, resource group, and workspace name, or ensuring the local config points to the correct one.
Concept tested: Azure ML Python SDK workspace reference
Source: https://learn.microsoft.com/en-us/python/api/azureml-core/azureml.core.workspace.workspace?view=azureml-py#from-config-path-none--subscription-id-none--resource-group-none--workspace-name-none--_logger-none--base-path-none-
Topics
Community Discussion
No community discussion yet for this question.
