@Stability(value=Stable)
public static interface CfnEndpointConfig.ProductionVariantProperty
extends software.amazon.jsii.JsiiSerializable
If you are deploying multiple models, tell Amazon SageMaker how to distribute traffic among the models by specifying the InitialVariantWeight objects.
Example:
// 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.*;
ProductionVariantProperty productionVariantProperty = ProductionVariantProperty.builder()
.initialVariantWeight(123)
.modelName("modelName")
.variantName("variantName")
// the properties below are optional
.acceleratorType("acceleratorType")
.initialInstanceCount(123)
.instanceType("instanceType")
.serverlessConfig(ServerlessConfigProperty.builder()
.maxConcurrency(123)
.memorySizeInMb(123)
.build())
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
CfnEndpointConfig.ProductionVariantProperty.Builder
A builder for
CfnEndpointConfig.ProductionVariantProperty |
static class |
CfnEndpointConfig.ProductionVariantProperty.Jsii$Proxy
An implementation for
CfnEndpointConfig.ProductionVariantProperty |
| Modifier and Type | Method and Description |
|---|---|
static CfnEndpointConfig.ProductionVariantProperty.Builder |
builder() |
default String |
getAcceleratorType()
The size of the Elastic Inference (EI) instance to use for the production variant.
|
default Number |
getInitialInstanceCount()
Number of instances to launch initially.
|
Number |
getInitialVariantWeight()
Determines initial traffic distribution among all of the models that you specify in the endpoint configuration.
|
default String |
getInstanceType()
The ML compute instance type.
|
String |
getModelName()
The name of the model that you want to host.
|
default Object |
getServerlessConfig()
The serverless configuration for an endpoint.
|
String |
getVariantName()
The name of the production variant.
|
@Stability(value=Stable) @NotNull Number getInitialVariantWeight()
The traffic to a production variant is determined by the ratio of the VariantWeight to the sum of all VariantWeight values across all ProductionVariants. If unspecified, it defaults to 1.0.
@Stability(value=Stable) @NotNull String getModelName()
This is the name that you specified when creating the model.
@Stability(value=Stable) @NotNull String getVariantName()
@Stability(value=Stable) @Nullable default String getAcceleratorType()
EI instances provide on-demand GPU computing for inference. For more information, see Using Elastic Inference in Amazon SageMaker . For more information, see Using Elastic Inference in Amazon SageMaker .
@Stability(value=Stable) @Nullable default Number getInitialInstanceCount()
@Stability(value=Stable) @Nullable default String getInstanceType()
@Stability(value=Stable) @Nullable default Object getServerlessConfig()
Specifies a serverless endpoint configuration instead of an instance-based endpoint configuration.
@Stability(value=Stable) static CfnEndpointConfig.ProductionVariantProperty.Builder builder()
Copyright © 2022. All rights reserved.