Class CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder
java.lang.Object
software.amazon.awscdk.services.sagemaker.CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty>
- Enclosing interface:
CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty
@Stability(Stable)
public static final class CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnInferenceComponent.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 CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder maxMemoryRequiredInMb(Number maxMemoryRequiredInMb) Sets the value ofCfnInferenceComponent.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 CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder minMemoryRequiredInMb(Number minMemoryRequiredInMb) Sets the value ofCfnInferenceComponent.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 CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder numberOfAcceleratorDevicesRequired(Number numberOfAcceleratorDevicesRequired) Sets the value ofCfnInferenceComponent.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 CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty.Builder numberOfCpuCoresRequired(Number numberOfCpuCoresRequired) Sets the value ofCfnInferenceComponent.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 CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty build()Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty>- Returns:
- a new instance of
CfnInferenceComponent.InferenceComponentComputeResourceRequirementsProperty - Throws:
NullPointerException- if any required attribute was not provided
-