# Google Cloud Notebooks V2 Client - Class AcceleratorConfig (1.1.3)

1.1.3 (latest) 1.1.2 1.0.5 0.7.5 0.6.2 0.5.0 0.4.1 0.3.6 Reference documentation and code samples for the Google Cloud Notebooks V2 Client class AcceleratorConfig.

An accelerator configuration for a VM instance
Definition of a hardware accelerator. Note that there is no check on `type`
and `core_count` combinations. TPUs are not supported.

See [GPUs on Compute
Engine](https://cloud.google.com/compute/docs/gpus/#gpus-list) to find a
valid combination.

Generated from protobuf message `google.cloud.notebooks.v2.AcceleratorConfig`

## Namespace

Google \\ Cloud \\ Notebooks \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ type` | `int` Optional. Type of this accelerator. |
| `↳ core_count` | `int|string` Optional. Count of cores of this accelerator. |

### getType

Optional. Type of this accelerator.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [AcceleratorType](https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V2.AcceleratorConfig.AcceleratorType). |

### setType

Optional. Type of this accelerator.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [AcceleratorType](https://docs.cloud.google.com/php/docs/reference/cloud-notebooks/latest/V2.AcceleratorConfig.AcceleratorType). |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCoreCount

Optional. Count of cores of this accelerator.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### setCoreCount

Optional. Count of cores of this accelerator.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |