ResourceConfig

class aws_cdk.aws_stepfunctions_tasks.ResourceConfig(*, instance_count, instance_type, volume_size, volume_encryption_key=None)

Bases: object

Specifies the resources, ML compute instances, and ML storage volumes to deploy for model training.

Parameters
  • instance_count (Union[int, float]) – The number of ML compute instances to use. Default: 1 instance.

  • instance_type (InstanceType) – ML compute instance type. Default: ec2.InstanceType(ec2.InstanceClass.M4, ec2.InstanceType.XLARGE)

  • volume_size (Size) – Size of the ML storage volume that you want to provision. Default: 10 GB EBS volume.

  • volume_encryption_key (Optional[IKey]) – KMS key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance(s) that run the training job. Default: - Amazon SageMaker uses the default KMS key for Amazon S3 for your role’s account

Attributes

instance_count

The number of ML compute instances to use.

Default

1 instance.

Return type

Union[int, float]

instance_type

ML compute instance type.

Default

ec2.InstanceType(ec2.InstanceClass.M4, ec2.InstanceType.XLARGE)

See

https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_ResourceConfig.html#sagemaker-Type-ResourceConfig-InstanceType

Example:

# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
Toprovideaninstancetype from thetaskinput , write
`new ec2.InstanceType(sfn.JsonPath.stringAt('$.path.to.instanceType'))` , wherethevalue in thetaskinputisanEC2instancetype prepended with"ml.".
Return type

InstanceType

volume_encryption_key

KMS key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance(s) that run the training job.

Default
  • Amazon SageMaker uses the default KMS key for Amazon S3 for your role’s account

Return type

Optional[IKey]

volume_size

Size of the ML storage volume that you want to provision.

Default

10 GB EBS volume.

Return type

Size