Class: Google::Apis::BatchV1::Accelerator
- Inherits:
-
Object
- Object
- Google::Apis::BatchV1::Accelerator
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/batch_v1/classes.rb,
lib/google/apis/batch_v1/representations.rb,
lib/google/apis/batch_v1/representations.rb
Overview
Accelerator describes Compute Engine accelerators to be attached to the VM.
Instance Attribute Summary collapse
-
#count ⇒ Fixnum
The number of accelerators of this type.
-
#install_gpu_drivers ⇒ Boolean
(also: #install_gpu_drivers?)
Deprecated: please use instances[0].install_gpu_drivers instead.
-
#type ⇒ String
The accelerator type.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Accelerator
constructor
A new instance of Accelerator.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Accelerator
Returns a new instance of Accelerator.
46 47 48 |
# File 'lib/google/apis/batch_v1/classes.rb', line 46 def initialize(**args) update!(**args) end |
Instance Attribute Details
#count ⇒ Fixnum
The number of accelerators of this type.
Corresponds to the JSON property count
32 33 34 |
# File 'lib/google/apis/batch_v1/classes.rb', line 32 def count @count end |
#install_gpu_drivers ⇒ Boolean Also known as: install_gpu_drivers?
Deprecated: please use instances[0].install_gpu_drivers instead.
Corresponds to the JSON property installGpuDrivers
37 38 39 |
# File 'lib/google/apis/batch_v1/classes.rb', line 37 def install_gpu_drivers @install_gpu_drivers end |
#type ⇒ String
The accelerator type. For example, "nvidia-tesla-t4". See gcloud compute
accelerator-types list
.
Corresponds to the JSON property type
44 45 46 |
# File 'lib/google/apis/batch_v1/classes.rb', line 44 def type @type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
51 52 53 54 55 |
# File 'lib/google/apis/batch_v1/classes.rb', line 51 def update!(**args) @count = args[:count] if args.key?(:count) @install_gpu_drivers = args[:install_gpu_drivers] if args.key?(:install_gpu_drivers) @type = args[:type] if args.key?(:type) end |