CfnInferenceExperimentProps
- class aws_cdk.aws_sagemaker.CfnInferenceExperimentProps(*, endpoint_name, model_variants, name, role_arn, type, data_storage_config=None, description=None, desired_state=None, kms_key=None, schedule=None, shadow_mode_config=None, status_reason=None, tags=None)
Bases:
object
Properties for defining a
CfnInferenceExperiment
.- Parameters:
endpoint_name (
str
) – The name of the endpoint.model_variants (
Union
[IResolvable
,Sequence
[Union
[IResolvable
,ModelVariantConfigProperty
,Dict
[str
,Any
]]]]) – An array ofModelVariantConfigSummary
objects. There is one for each variant in the inference experiment. EachModelVariantConfigSummary
object in the array describes the infrastructure configuration for deploying the corresponding variant.name (
str
) – The name of the inference experiment.role_arn (
str
) – The ARN of the IAM role that Amazon SageMaker can assume to access model artifacts and container images, and manage Amazon SageMaker Inference endpoints for model deployment.type (
str
) – The type of the inference experiment.data_storage_config (
Union
[IResolvable
,DataStorageConfigProperty
,Dict
[str
,Any
],None
]) – The Amazon S3 location and configuration for storing inference request and response data.description (
Optional
[str
]) – The description of the inference experiment.desired_state (
Optional
[str
]) – The desired state of the experiment after stopping. The possible states are the following:. -Completed
: The experiment completed successfully -Cancelled
: The experiment was canceledkms_key (
Optional
[str
]) – The AWS Key Management Service key that Amazon SageMaker uses to encrypt captured data at rest using Amazon S3 server-side encryption.schedule (
Union
[IResolvable
,InferenceExperimentScheduleProperty
,Dict
[str
,Any
],None
]) – The duration for which the inference experiment ran or will run. The maximum duration that you can set for an inference experiment is 30 days.shadow_mode_config (
Union
[IResolvable
,ShadowModeConfigProperty
,Dict
[str
,Any
],None
]) – The configuration ofShadowMode
inference experiment type, which shows the production variant that takes all the inference requests, and the shadow variant to which Amazon SageMaker replicates a percentage of the inference requests. For the shadow variant it also shows the percentage of requests that Amazon SageMaker replicates.status_reason (
Optional
[str
]) – The error message for the inference experiment status result.tags (
Optional
[Sequence
[Union
[CfnTag
,Dict
[str
,Any
]]]]) – An array of key-value pairs to apply to this resource. For more information, see Tag .
- See:
- ExampleMetadata:
fixture=_generated
Example:
# 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 cfn_inference_experiment_props = sagemaker.CfnInferenceExperimentProps( endpoint_name="endpointName", model_variants=[sagemaker.CfnInferenceExperiment.ModelVariantConfigProperty( infrastructure_config=sagemaker.CfnInferenceExperiment.ModelInfrastructureConfigProperty( infrastructure_type="infrastructureType", real_time_inference_config=sagemaker.CfnInferenceExperiment.RealTimeInferenceConfigProperty( instance_count=123, instance_type="instanceType" ) ), model_name="modelName", variant_name="variantName" )], name="name", role_arn="roleArn", type="type", # the properties below are optional data_storage_config=sagemaker.CfnInferenceExperiment.DataStorageConfigProperty( destination="destination", # the properties below are optional content_type=sagemaker.CfnInferenceExperiment.CaptureContentTypeHeaderProperty( csv_content_types=["csvContentTypes"], json_content_types=["jsonContentTypes"] ), kms_key="kmsKey" ), description="description", desired_state="desiredState", kms_key="kmsKey", schedule=sagemaker.CfnInferenceExperiment.InferenceExperimentScheduleProperty( end_time="endTime", start_time="startTime" ), shadow_mode_config=sagemaker.CfnInferenceExperiment.ShadowModeConfigProperty( shadow_model_variants=[sagemaker.CfnInferenceExperiment.ShadowModelVariantConfigProperty( sampling_percentage=123, shadow_model_variant_name="shadowModelVariantName" )], source_model_variant_name="sourceModelVariantName" ), status_reason="statusReason", tags=[CfnTag( key="key", value="value" )] )
Attributes
- data_storage_config
The Amazon S3 location and configuration for storing inference request and response data.
- description
The description of the inference experiment.
- desired_state
.
Completed
: The experiment completed successfullyCancelled
: The experiment was canceled
- See:
- Type:
The desired state of the experiment after stopping. The possible states are the following
- endpoint_name
The name of the endpoint.
- kms_key
The AWS Key Management Service key that Amazon SageMaker uses to encrypt captured data at rest using Amazon S3 server-side encryption.
- model_variants
An array of
ModelVariantConfigSummary
objects.There is one for each variant in the inference experiment. Each
ModelVariantConfigSummary
object in the array describes the infrastructure configuration for deploying the corresponding variant.
- name
The name of the inference experiment.
- role_arn
The ARN of the IAM role that Amazon SageMaker can assume to access model artifacts and container images, and manage Amazon SageMaker Inference endpoints for model deployment.
- schedule
The duration for which the inference experiment ran or will run.
The maximum duration that you can set for an inference experiment is 30 days.
- shadow_mode_config
The configuration of
ShadowMode
inference experiment type, which shows the production variant that takes all the inference requests, and the shadow variant to which Amazon SageMaker replicates a percentage of the inference requests.For the shadow variant it also shows the percentage of requests that Amazon SageMaker replicates.
- status_reason
The error message for the inference experiment status result.
- type
The type of the inference experiment.