DsvmCompute Class

Manages a Data Science Virtual Machine compute target in Azure Machine Learning.

The Azure Data Science Virtual Machine (DSVM) is a pre-configured data science and AI development environment in Azure. The VM offers a curated choice of tools and frameworks for full-lifecycle machine learning development. For more information, see Data Science Virtual Machine.

Class ComputeTarget constructor.

Retrieve a cloud representation of a Compute object associated with the provided workspace. Returns an instance of a child class corresponding to the specific type of the retrieved Compute object.

Inheritance
DsvmCompute

Constructor

DsvmCompute(workspace, name)

Parameters

workspace
Workspace
Required

The workspace object containing the DsvmCompute object to retrieve.

name
str
Required

The name of the of the DsvmCompute object to retrieve.

workspace
Workspace
Required

The workspace object containing the Compute object to retrieve.

name
str
Required

The name of the of the Compute object to retrieve.

Methods

delete

Remove the DsvmCompute object from its associated workspace.

deserialize

Convert a JSON object into a DsvmCompute object.

detach

Detach is not supported for a DsvmCompute object. Use delete instead.

get_credentials

Retrieve the credentials for the DsvmCompute target.

provisioning_configuration

Create a configuration object for provisioning a DsvmCompute target.

refresh_state

Perform an in-place update of the properties of the object.

This method updates the properties based on the current state of the corresponding cloud object. This is primarily used for manual polling of compute state.

serialize

Convert this DsvmCompute object into a JSON serialized dictionary.

delete

Remove the DsvmCompute object from its associated workspace.

delete()

Exceptions

Remarks

If this object was created through Azure Machine Learning, the corresponding cloud based objects will also be deleted. If this object was created externally and only attached to the workspace, it will raise exception and nothing will be changed.

deserialize

Convert a JSON object into a DsvmCompute object.

static deserialize(workspace, object_dict)

Parameters

workspace
Workspace
Required

The workspace object the DsvmCompute object is associated with.

object_dict
dict
Required

A JSON object to convert to a DsvmCompute object.

Returns

The DsvmCompute representation of the provided JSON object.

Return type

Exceptions

Remarks

Raises a ComputeTargetException if the provided workspace is not the workspace the Compute is associated with.

detach

Detach is not supported for a DsvmCompute object. Use delete instead.

detach()

Exceptions

get_credentials

Retrieve the credentials for the DsvmCompute target.

get_credentials()

Returns

The credentials for the DsvmCompute target.

Return type

Exceptions

provisioning_configuration

Create a configuration object for provisioning a DsvmCompute target.

static provisioning_configuration(vm_size=None, ssh_port=None, location=None)

Parameters

vm_size
str
default value: None

Specifies the size of the VM to provision. More details can be found here: https://aka.ms/azureml-vm-details. Defaults to Standard_DS3_v2.

ssh_port
str
default value: None

The SSH port to open on the VM.

location
str
default value: None

Location to provision cluster in. If not specified, will default to workspace location. Available regions for different desired VM sizes can be found here: https://azure.microsoft.com/global-infrastructure/services/?regions=all&products=virtual-machines

Returns

A configuration object to be used when creating a Compute object.

Return type

Exceptions

refresh_state

Perform an in-place update of the properties of the object.

This method updates the properties based on the current state of the corresponding cloud object. This is primarily used for manual polling of compute state.

refresh_state()

Exceptions

serialize

Convert this DsvmCompute object into a JSON serialized dictionary.

serialize()

Returns

The JSON representation of this DsvmCompute object.

Return type

Exceptions