Class: Google::Apis::ComputeV1::AcceleratorConfig
- Inherits:
-
Object
- Object
- Google::Apis::ComputeV1::AcceleratorConfig
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/compute_v1/classes.rb,
lib/google/apis/compute_v1/representations.rb,
lib/google/apis/compute_v1/representations.rb
Overview
A specification of the type and number of accelerator cards attached to the instance.
Instance Attribute Summary collapse
-
#accelerator_count ⇒ Fixnum
The number of the guest accelerator cards exposed to this instance.
-
#accelerator_type ⇒ String
Full or partial URL of the accelerator type resource to attach to this instance.
Instance Method Summary collapse
-
#initialize(**args) ⇒ AcceleratorConfig
constructor
A new instance of AcceleratorConfig.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ AcceleratorConfig
Returns a new instance of AcceleratorConfig.
90 91 92 |
# File 'lib/google/apis/compute_v1/classes.rb', line 90 def initialize(**args) update!(**args) end |
Instance Attribute Details
#accelerator_count ⇒ Fixnum
The number of the guest accelerator cards exposed to this instance.
Corresponds to the JSON property acceleratorCount
79 80 81 |
# File 'lib/google/apis/compute_v1/classes.rb', line 79 def accelerator_count @accelerator_count end |
#accelerator_type ⇒ String
Full or partial URL of the accelerator type resource to attach to this
instance. For example: projects/my-project/zones/us-central1-c/
acceleratorTypes/nvidia-tesla-p100 If you are creating an instance template,
specify only the accelerator name. See GPUs on Compute Engine for a full list
of accelerator types.
Corresponds to the JSON property acceleratorType
88 89 90 |
# File 'lib/google/apis/compute_v1/classes.rb', line 88 def accelerator_type @accelerator_type end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
95 96 97 98 |
# File 'lib/google/apis/compute_v1/classes.rb', line 95 def update!(**args) @accelerator_count = args[:accelerator_count] if args.key?(:accelerator_count) @accelerator_type = args[:accelerator_type] if args.key?(:accelerator_type) end |