Google Cloud Dataproc V1 Client - Class AcceleratorConfig (2.2.1)

Reference documentation and code samples for the Google Cloud Dataproc V1 Client class AcceleratorConfig.

Specifies the type and number of accelerator cards attached to the instances of an instance. See GPUs on Compute Engine.

Generated from protobuf message google.cloud.dataproc.v1.AcceleratorConfig

Namespace

Google \ Cloud \ Dataproc \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ accelerator_type_uri string

Full URL, partial URI, or short name of the accelerator type resource to expose to this instance. See Compute Engine AcceleratorTypes. Examples: * * https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4 * * projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4 * * nvidia-tesla-t4 Auto Zone Exception: If you are using the Dataproc Auto Zone Placement feature, you must use the short name of the accelerator type resource, for example, nvidia-tesla-t4.

↳ accelerator_count int

The number of the accelerator cards of this type exposed to this instance.

getAcceleratorTypeUri

Full URL, partial URI, or short name of the accelerator type resource to expose to this instance. See Compute Engine AcceleratorTypes.

Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4
  • projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4
  • nvidia-tesla-t4 Auto Zone Exception: If you are using the Dataproc Auto Zone Placement feature, you must use the short name of the accelerator type resource, for example, nvidia-tesla-t4.
Returns
Type Description
string

setAcceleratorTypeUri

Full URL, partial URI, or short name of the accelerator type resource to expose to this instance. See Compute Engine AcceleratorTypes.

Examples:

  • https://www.googleapis.com/compute/v1/projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4
  • projects/[project_id]/zones/[zone]/acceleratorTypes/nvidia-tesla-t4
  • nvidia-tesla-t4 Auto Zone Exception: If you are using the Dataproc Auto Zone Placement feature, you must use the short name of the accelerator type resource, for example, nvidia-tesla-t4.
Parameter
Name Description
var string
Returns
Type Description
$this

getAcceleratorCount

The number of the accelerator cards of this type exposed to this instance.

Returns
Type Description
int

setAcceleratorCount

The number of the accelerator cards of this type exposed to this instance.

Parameter
Name Description
var int
Returns
Type Description
$this