Skip to content
v2.278.0

ModelDataSourceProperty Struct ​

Specifies the location of ML model data to deploy.

If specified, you must specify one and only one of the available data sources.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_sagemaker as sagemaker } from 'aws-cdk-lib';
const modelDataSourceProperty: sagemaker.CfnModelPackage.ModelDataSourceProperty = {
  s3DataSource: {
    compressionType: 'compressionType',
    s3DataType: 's3DataType',
    s3Uri: 's3Uri',

    // the properties below are optional
    modelAccessConfig: {
      acceptEula: false,
    },
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_sagemaker as sagemaker

model_data_source_property = sagemaker.CfnModelPackage.ModelDataSourceProperty(
    s3_data_source=sagemaker.CfnModelPackage.S3ModelDataSourceProperty(
        compression_type="compressionType",
        s3_data_type="s3DataType",
        s3_uri="s3Uri",

        # the properties below are optional
        model_access_config=sagemaker.CfnModelPackage.ModelAccessConfigProperty(
            accept_eula=False
        )
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.sagemaker.*;

ModelDataSourceProperty modelDataSourceProperty = ModelDataSourceProperty.builder()
        .s3DataSource(S3ModelDataSourceProperty.builder()
                .compressionType("compressionType")
                .s3DataType("s3DataType")
                .s3Uri("s3Uri")

                // the properties below are optional
                .modelAccessConfig(ModelAccessConfigProperty.builder()
                        .acceptEula(false)
                        .build())
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Sagemaker;

var modelDataSourceProperty = new ModelDataSourceProperty {
    S3DataSource = new S3ModelDataSourceProperty {
        CompressionType = "compressionType",
        S3DataType = "s3DataType",
        S3Uri = "s3Uri",

        // the properties below are optional
        ModelAccessConfig = new ModelAccessConfigProperty {
            AcceptEula = false
        }
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

modelDataSourceProperty := &ModelDataSourceProperty{
	S3DataSource: &S3ModelDataSourceProperty{
		CompressionType: jsii.String("compressionType"),
		S3DataType: jsii.String("s3DataType"),
		S3Uri: jsii.String("s3Uri"),

		// the properties below are optional
		ModelAccessConfig: &ModelAccessConfigProperty{
			AcceptEula: jsii.Boolean(false),
		},
	},
}

Properties ​

s3DataSourceoptionalIResolvable | CfnModelPackage.S3ModelDataSourcePropertys3_data_sourceoptionaltyping.Union[IResolvable, S3ModelDataSourceProperty]s3DataSourceoptionalIResolvableS3DataSourceoptionalIResolvableS3DataSourceoptionalinterface{} #
Specifies the S3 location of ML model data to deploy.