compute_quotas
Creates, updates, deletes, gets or lists a compute_quotas resource.
Overview
| Name | compute_quotas |
| Type | Resource |
| Id | aws.sagemaker.compute_quotas |
Fields
The following fields are returned by SELECT queries:
- describe_compute_quota
- list_compute_quotas
| Name | Datatype | Description |
|---|---|---|
activation_state | string | The state of the compute allocation being described. Use to enable or disable compute allocation. Default is Enabled. (Enabled, Disabled) |
cluster_arn | string | ARN of the cluster. (pattern: <code>arn:aws[a-z-]:sagemaker:[a-z0-9-]:[0-9]{12}:cluster/[a-z0-9]{12}</code>) |
compute_quota_arn | string | ARN of the compute allocation definition. (pattern: <code>arn:aws[a-z-]:sagemaker:[a-z0-9-]:[0-9]{12}:compute-quota/[a-z0-9]{12}</code>) |
compute_quota_config | object | Configuration of the compute allocation definition. This includes the resource sharing option, and the setting to preempt low priority tasks. |
compute_quota_id | string | ID of the compute allocation definition. (pattern: <code>[a-z0-9]{12}</code>) |
compute_quota_target | object | The target entity to allocate compute resources to. |
compute_quota_version | integer | Version of the compute allocation definition. |
created_by | object | Information about the user who created or modified a SageMaker resource. |
creation_time | string (date-time) | Creation time of the compute allocation configuration. |
description | string | Description of the compute allocation definition. (pattern: <code>[\p{L}\p{M}\p{Z}\p{S}\p{N}\p{P}]*</code>) |
failure_reason | string | Failure reason of the compute allocation definition. |
last_modified_by | object | Information about the user who created or modified a SageMaker resource. |
last_modified_time | string (date-time) | Last modified time of the compute allocation configuration. |
name | string | Name of the compute allocation definition. (pattern: <code>[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}</code>) |
status | string | Status of the compute allocation definition. (Creating, CreateFailed, CreateRollbackFailed, Created, Updating, UpdateFailed, UpdateRollbackFailed, Updated, Deleting, DeleteFailed, DeleteRollbackFailed, Deleted) |
| Name | Datatype | Description |
|---|---|---|
activation_state | string | The state of the compute allocation being described. Use to enable or disable compute allocation. Default is Enabled. (Enabled, Disabled) |
cluster_arn | string | ARN of the cluster. (pattern: <code>arn:aws[a-z-]:sagemaker:[a-z0-9-]:[0-9]{12}:cluster/[a-z0-9]{12}</code>) |
compute_quota_arn | string | ARN of the compute allocation definition. (pattern: <code>arn:aws[a-z-]:sagemaker:[a-z0-9-]:[0-9]{12}:compute-quota/[a-z0-9]{12}</code>) |
compute_quota_config | object | Configuration of the compute allocation definition. This includes the resource sharing option, and the setting to preempt low priority tasks. |
compute_quota_id | string | ID of the compute allocation definition. (pattern: <code>[a-z0-9]{12}</code>) |
compute_quota_target | object | The target entity to allocate compute resources to. |
compute_quota_version | integer | Version of the compute allocation definition. |
creation_time | string (date-time) | Creation time of the compute allocation definition. |
last_modified_time | string (date-time) | Last modified time of the compute allocation definition. |
name | string | Name of the compute allocation definition. (pattern: <code>[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}</code>) |
status | string | Status of the compute allocation definition. (Creating, CreateFailed, CreateRollbackFailed, Created, Updating, UpdateFailed, UpdateRollbackFailed, Updated, Deleting, DeleteFailed, DeleteRollbackFailed, Deleted) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
describe_compute_quota | select | region | Description of the compute allocation definition. | |
list_compute_quotas | select | region | List the resource allocation definitions. | |
create_compute_quota | insert | region, ClusterArn, ComputeQuotaConfig, ComputeQuotaTarget | Create compute allocation definition. This defines how compute is allocated, shared, and borrowed for specified entities. Specifically, how to lend and borrow idle compute and assign a fair-share weight to the specified entities. | |
update_compute_quota | update | region, ComputeQuotaId, TargetVersion | Update the compute allocation definition. | |
delete_compute_quota | delete | region | Deletes the compute allocation from the cluster. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
region | string | AWS region (default: us-east-1) |
SELECT examples
- describe_compute_quota
- list_compute_quotas
Description of the compute allocation definition.
SELECT
activation_state,
cluster_arn,
compute_quota_arn,
compute_quota_config,
compute_quota_id,
compute_quota_target,
compute_quota_version,
created_by,
creation_time,
description,
failure_reason,
last_modified_by,
last_modified_time,
name,
status
FROM aws.sagemaker.compute_quotas
WHERE region = '{{ region }}' -- required
;
List the resource allocation definitions.
SELECT
activation_state,
cluster_arn,
compute_quota_arn,
compute_quota_config,
compute_quota_id,
compute_quota_target,
compute_quota_version,
creation_time,
last_modified_time,
name,
status
FROM aws.sagemaker.compute_quotas
WHERE region = '{{ region }}' -- required
;
INSERT examples
- create_compute_quota
- Manifest
Create compute allocation definition. This defines how compute is allocated, shared, and borrowed for specified entities. Specifically, how to lend and borrow idle compute and assign a fair-share weight to the specified entities.
INSERT INTO aws.sagemaker.compute_quotas (
Name,
Description,
ClusterArn,
ComputeQuotaConfig,
ComputeQuotaTarget,
ActivationState,
Tags,
region
)
SELECT
'{{ Name }}',
'{{ Description }}',
'{{ ClusterArn }}' /* required */,
'{{ ComputeQuotaConfig }}' /* required */,
'{{ ComputeQuotaTarget }}' /* required */,
'{{ ActivationState }}',
'{{ Tags }}',
'{{ region }}'
RETURNING
compute_quota_arn,
compute_quota_id
;
# Description fields are for documentation purposes
- name: compute_quotas
props:
- name: region
value: "{{ region }}"
description: Required parameter for the compute_quotas resource.
- name: Name
value: "{{ Name }}"
description: |
Name to the compute allocation definition.
- name: Description
value: "{{ Description }}"
description: |
Description of the compute allocation definition.
- name: ClusterArn
value: "{{ ClusterArn }}"
description: |
ARN of the cluster.
- name: ComputeQuotaConfig
description: |
Configuration of the compute allocation definition. This includes the resource sharing option, and the setting to preempt low priority tasks.
value:
ComputeQuotaResources:
- InstanceType: "{{ InstanceType }}"
Count: {{ Count }}
Accelerators: {{ Accelerators }}
VCpu: {{ VCpu }}
MemoryInGiB: {{ MemoryInGiB }}
AcceleratorPartition:
Type: "{{ Type }}"
Count: {{ Count }}
ResourceSharingConfig:
Strategy: "{{ Strategy }}"
BorrowLimit: {{ BorrowLimit }}
AbsoluteBorrowLimits:
- InstanceType: "{{ InstanceType }}"
Count: {{ Count }}
Accelerators: {{ Accelerators }}
VCpu: {{ VCpu }}
MemoryInGiB: {{ MemoryInGiB }}
AcceleratorPartition:
Type: "{{ Type }}"
Count: {{ Count }}
PreemptTeamTasks: "{{ PreemptTeamTasks }}"
- name: ComputeQuotaTarget
description: |
The target entity to allocate compute resources to.
value:
TeamName: "{{ TeamName }}"
FairShareWeight: {{ FairShareWeight }}
- name: ActivationState
value: "{{ ActivationState }}"
description: |
The state of the compute allocation being described. Use to enable or disable compute allocation. Default is Enabled.
valid_values: ['Enabled', 'Disabled']
- name: Tags
description: |
Tags of the compute allocation definition.
value:
- Key: "{{ Key }}"
Value: "{{ Value }}"
UPDATE examples
- update_compute_quota
Update the compute allocation definition.
UPDATE aws.sagemaker.compute_quotas
SET
ComputeQuotaId = '{{ ComputeQuotaId }}',
TargetVersion = {{ TargetVersion }},
ComputeQuotaConfig = '{{ ComputeQuotaConfig }}',
ComputeQuotaTarget = '{{ ComputeQuotaTarget }}',
ActivationState = '{{ ActivationState }}',
Description = '{{ Description }}'
WHERE
region = '{{ region }}' --required
AND ComputeQuotaId = '{{ ComputeQuotaId }}' --required
AND TargetVersion = '{{ TargetVersion }}' --required
RETURNING
compute_quota_arn,
compute_quota_version;
DELETE examples
- delete_compute_quota
Deletes the compute allocation from the cluster.
DELETE FROM aws.sagemaker.compute_quotas
WHERE region = '{{ region }}' --required
;