Class CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder
java.lang.Object
software.amazon.awscdk.cfnpropertymixins.services.sagemaker.CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty>
- Enclosing interface:
CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty
@Stability(Stable)
public static final class CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.maxMemoryRequiredInMb(Number maxMemoryRequiredInMb) minMemoryRequiredInMb(Number minMemoryRequiredInMb) numberOfAcceleratorDevicesRequired(Number numberOfAcceleratorDevicesRequired) numberOfCpuCoresRequired(Number numberOfCpuCoresRequired)
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
maxMemoryRequiredInMb
@Stability(Stable) public CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder maxMemoryRequiredInMb(Number maxMemoryRequiredInMb) Sets the value ofCfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.getMaxMemoryRequiredInMb()- Parameters:
maxMemoryRequiredInMb- The maximum MB of memory to allocate to run a model that you assign to an inference component.- Returns:
this
-
minMemoryRequiredInMb
@Stability(Stable) public CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder minMemoryRequiredInMb(Number minMemoryRequiredInMb) Sets the value ofCfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.getMinMemoryRequiredInMb()- Parameters:
minMemoryRequiredInMb- The minimum MB of memory to allocate to run a model that you assign to an inference component.- Returns:
this
-
numberOfAcceleratorDevicesRequired
@Stability(Stable) public CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder numberOfAcceleratorDevicesRequired(Number numberOfAcceleratorDevicesRequired) Sets the value ofCfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.getNumberOfAcceleratorDevicesRequired()- Parameters:
numberOfAcceleratorDevicesRequired- The number of accelerators to allocate to run a model that you assign to an inference component. Accelerators include GPUs and AWS Inferentia.- Returns:
this
-
numberOfCpuCoresRequired
@Stability(Stable) public CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.Builder numberOfCpuCoresRequired(Number numberOfCpuCoresRequired) Sets the value ofCfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty.getNumberOfCpuCoresRequired()- Parameters:
numberOfCpuCoresRequired- The number of CPU cores to allocate to run a model that you assign to an inference component.- Returns:
this
-
build
@Stability(Stable) public CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty build()Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty>- Returns:
- a new instance of
CfnInferenceComponentPropsMixin.InferenceComponentComputeResourceRequirementsProperty - Throws:
NullPointerException- if any required attribute was not provided
-