/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace SageMaker { namespace Model { /** *

Defines how the algorithm is used for a training job.

See * Also:

AWS * API Reference

*/ class TrainingSpecification { public: AWS_SAGEMAKER_API TrainingSpecification(); AWS_SAGEMAKER_API TrainingSpecification(Aws::Utils::Json::JsonView jsonValue); AWS_SAGEMAKER_API TrainingSpecification& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_SAGEMAKER_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline const Aws::String& GetTrainingImage() const{ return m_trainingImage; } /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline bool TrainingImageHasBeenSet() const { return m_trainingImageHasBeenSet; } /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline void SetTrainingImage(const Aws::String& value) { m_trainingImageHasBeenSet = true; m_trainingImage = value; } /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline void SetTrainingImage(Aws::String&& value) { m_trainingImageHasBeenSet = true; m_trainingImage = std::move(value); } /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline void SetTrainingImage(const char* value) { m_trainingImageHasBeenSet = true; m_trainingImage.assign(value); } /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline TrainingSpecification& WithTrainingImage(const Aws::String& value) { SetTrainingImage(value); return *this;} /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline TrainingSpecification& WithTrainingImage(Aws::String&& value) { SetTrainingImage(std::move(value)); return *this;} /** *

The Amazon ECR registry path of the Docker image that contains the training * algorithm.

*/ inline TrainingSpecification& WithTrainingImage(const char* value) { SetTrainingImage(value); return *this;} /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline const Aws::String& GetTrainingImageDigest() const{ return m_trainingImageDigest; } /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline bool TrainingImageDigestHasBeenSet() const { return m_trainingImageDigestHasBeenSet; } /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline void SetTrainingImageDigest(const Aws::String& value) { m_trainingImageDigestHasBeenSet = true; m_trainingImageDigest = value; } /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline void SetTrainingImageDigest(Aws::String&& value) { m_trainingImageDigestHasBeenSet = true; m_trainingImageDigest = std::move(value); } /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline void SetTrainingImageDigest(const char* value) { m_trainingImageDigestHasBeenSet = true; m_trainingImageDigest.assign(value); } /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline TrainingSpecification& WithTrainingImageDigest(const Aws::String& value) { SetTrainingImageDigest(value); return *this;} /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline TrainingSpecification& WithTrainingImageDigest(Aws::String&& value) { SetTrainingImageDigest(std::move(value)); return *this;} /** *

An MD5 hash of the training algorithm that identifies the Docker image used * for training.

*/ inline TrainingSpecification& WithTrainingImageDigest(const char* value) { SetTrainingImageDigest(value); return *this;} /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline const Aws::Vector& GetSupportedHyperParameters() const{ return m_supportedHyperParameters; } /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline bool SupportedHyperParametersHasBeenSet() const { return m_supportedHyperParametersHasBeenSet; } /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline void SetSupportedHyperParameters(const Aws::Vector& value) { m_supportedHyperParametersHasBeenSet = true; m_supportedHyperParameters = value; } /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline void SetSupportedHyperParameters(Aws::Vector&& value) { m_supportedHyperParametersHasBeenSet = true; m_supportedHyperParameters = std::move(value); } /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline TrainingSpecification& WithSupportedHyperParameters(const Aws::Vector& value) { SetSupportedHyperParameters(value); return *this;} /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline TrainingSpecification& WithSupportedHyperParameters(Aws::Vector&& value) { SetSupportedHyperParameters(std::move(value)); return *this;} /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline TrainingSpecification& AddSupportedHyperParameters(const HyperParameterSpecification& value) { m_supportedHyperParametersHasBeenSet = true; m_supportedHyperParameters.push_back(value); return *this; } /** *

A list of the HyperParameterSpecification objects, that define * the supported hyperparameters. This is required if the algorithm supports * automatic model tuning.>

*/ inline TrainingSpecification& AddSupportedHyperParameters(HyperParameterSpecification&& value) { m_supportedHyperParametersHasBeenSet = true; m_supportedHyperParameters.push_back(std::move(value)); return *this; } /** *

A list of the instance types that this algorithm can use for training.

*/ inline const Aws::Vector& GetSupportedTrainingInstanceTypes() const{ return m_supportedTrainingInstanceTypes; } /** *

A list of the instance types that this algorithm can use for training.

*/ inline bool SupportedTrainingInstanceTypesHasBeenSet() const { return m_supportedTrainingInstanceTypesHasBeenSet; } /** *

A list of the instance types that this algorithm can use for training.

*/ inline void SetSupportedTrainingInstanceTypes(const Aws::Vector& value) { m_supportedTrainingInstanceTypesHasBeenSet = true; m_supportedTrainingInstanceTypes = value; } /** *

A list of the instance types that this algorithm can use for training.

*/ inline void SetSupportedTrainingInstanceTypes(Aws::Vector&& value) { m_supportedTrainingInstanceTypesHasBeenSet = true; m_supportedTrainingInstanceTypes = std::move(value); } /** *

A list of the instance types that this algorithm can use for training.

*/ inline TrainingSpecification& WithSupportedTrainingInstanceTypes(const Aws::Vector& value) { SetSupportedTrainingInstanceTypes(value); return *this;} /** *

A list of the instance types that this algorithm can use for training.

*/ inline TrainingSpecification& WithSupportedTrainingInstanceTypes(Aws::Vector&& value) { SetSupportedTrainingInstanceTypes(std::move(value)); return *this;} /** *

A list of the instance types that this algorithm can use for training.

*/ inline TrainingSpecification& AddSupportedTrainingInstanceTypes(const TrainingInstanceType& value) { m_supportedTrainingInstanceTypesHasBeenSet = true; m_supportedTrainingInstanceTypes.push_back(value); return *this; } /** *

A list of the instance types that this algorithm can use for training.

*/ inline TrainingSpecification& AddSupportedTrainingInstanceTypes(TrainingInstanceType&& value) { m_supportedTrainingInstanceTypesHasBeenSet = true; m_supportedTrainingInstanceTypes.push_back(std::move(value)); return *this; } /** *

Indicates whether the algorithm supports distributed training. If set to * false, buyers can't request more than one instance during training.

*/ inline bool GetSupportsDistributedTraining() const{ return m_supportsDistributedTraining; } /** *

Indicates whether the algorithm supports distributed training. If set to * false, buyers can't request more than one instance during training.

*/ inline bool SupportsDistributedTrainingHasBeenSet() const { return m_supportsDistributedTrainingHasBeenSet; } /** *

Indicates whether the algorithm supports distributed training. If set to * false, buyers can't request more than one instance during training.

*/ inline void SetSupportsDistributedTraining(bool value) { m_supportsDistributedTrainingHasBeenSet = true; m_supportsDistributedTraining = value; } /** *

Indicates whether the algorithm supports distributed training. If set to * false, buyers can't request more than one instance during training.

*/ inline TrainingSpecification& WithSupportsDistributedTraining(bool value) { SetSupportsDistributedTraining(value); return *this;} /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline const Aws::Vector& GetMetricDefinitions() const{ return m_metricDefinitions; } /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline bool MetricDefinitionsHasBeenSet() const { return m_metricDefinitionsHasBeenSet; } /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline void SetMetricDefinitions(const Aws::Vector& value) { m_metricDefinitionsHasBeenSet = true; m_metricDefinitions = value; } /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline void SetMetricDefinitions(Aws::Vector&& value) { m_metricDefinitionsHasBeenSet = true; m_metricDefinitions = std::move(value); } /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline TrainingSpecification& WithMetricDefinitions(const Aws::Vector& value) { SetMetricDefinitions(value); return *this;} /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline TrainingSpecification& WithMetricDefinitions(Aws::Vector&& value) { SetMetricDefinitions(std::move(value)); return *this;} /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline TrainingSpecification& AddMetricDefinitions(const MetricDefinition& value) { m_metricDefinitionsHasBeenSet = true; m_metricDefinitions.push_back(value); return *this; } /** *

A list of MetricDefinition objects, which are used for parsing * metrics generated by the algorithm.

*/ inline TrainingSpecification& AddMetricDefinitions(MetricDefinition&& value) { m_metricDefinitionsHasBeenSet = true; m_metricDefinitions.push_back(std::move(value)); return *this; } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline const Aws::Vector& GetTrainingChannels() const{ return m_trainingChannels; } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline bool TrainingChannelsHasBeenSet() const { return m_trainingChannelsHasBeenSet; } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline void SetTrainingChannels(const Aws::Vector& value) { m_trainingChannelsHasBeenSet = true; m_trainingChannels = value; } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline void SetTrainingChannels(Aws::Vector&& value) { m_trainingChannelsHasBeenSet = true; m_trainingChannels = std::move(value); } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline TrainingSpecification& WithTrainingChannels(const Aws::Vector& value) { SetTrainingChannels(value); return *this;} /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline TrainingSpecification& WithTrainingChannels(Aws::Vector&& value) { SetTrainingChannels(std::move(value)); return *this;} /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline TrainingSpecification& AddTrainingChannels(const ChannelSpecification& value) { m_trainingChannelsHasBeenSet = true; m_trainingChannels.push_back(value); return *this; } /** *

A list of ChannelSpecification objects, which specify the input * sources to be used by the algorithm.

*/ inline TrainingSpecification& AddTrainingChannels(ChannelSpecification&& value) { m_trainingChannelsHasBeenSet = true; m_trainingChannels.push_back(std::move(value)); return *this; } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline const Aws::Vector& GetSupportedTuningJobObjectiveMetrics() const{ return m_supportedTuningJobObjectiveMetrics; } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline bool SupportedTuningJobObjectiveMetricsHasBeenSet() const { return m_supportedTuningJobObjectiveMetricsHasBeenSet; } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline void SetSupportedTuningJobObjectiveMetrics(const Aws::Vector& value) { m_supportedTuningJobObjectiveMetricsHasBeenSet = true; m_supportedTuningJobObjectiveMetrics = value; } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline void SetSupportedTuningJobObjectiveMetrics(Aws::Vector&& value) { m_supportedTuningJobObjectiveMetricsHasBeenSet = true; m_supportedTuningJobObjectiveMetrics = std::move(value); } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline TrainingSpecification& WithSupportedTuningJobObjectiveMetrics(const Aws::Vector& value) { SetSupportedTuningJobObjectiveMetrics(value); return *this;} /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline TrainingSpecification& WithSupportedTuningJobObjectiveMetrics(Aws::Vector&& value) { SetSupportedTuningJobObjectiveMetrics(std::move(value)); return *this;} /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline TrainingSpecification& AddSupportedTuningJobObjectiveMetrics(const HyperParameterTuningJobObjective& value) { m_supportedTuningJobObjectiveMetricsHasBeenSet = true; m_supportedTuningJobObjectiveMetrics.push_back(value); return *this; } /** *

A list of the metrics that the algorithm emits that can be used as the * objective metric in a hyperparameter tuning job.

*/ inline TrainingSpecification& AddSupportedTuningJobObjectiveMetrics(HyperParameterTuningJobObjective&& value) { m_supportedTuningJobObjectiveMetricsHasBeenSet = true; m_supportedTuningJobObjectiveMetrics.push_back(std::move(value)); return *this; } private: Aws::String m_trainingImage; bool m_trainingImageHasBeenSet = false; Aws::String m_trainingImageDigest; bool m_trainingImageDigestHasBeenSet = false; Aws::Vector m_supportedHyperParameters; bool m_supportedHyperParametersHasBeenSet = false; Aws::Vector m_supportedTrainingInstanceTypes; bool m_supportedTrainingInstanceTypesHasBeenSet = false; bool m_supportsDistributedTraining; bool m_supportsDistributedTrainingHasBeenSet = false; Aws::Vector m_metricDefinitions; bool m_metricDefinitionsHasBeenSet = false; Aws::Vector m_trainingChannels; bool m_trainingChannelsHasBeenSet = false; Aws::Vector m_supportedTuningJobObjectiveMetrics; bool m_supportedTuningJobObjectiveMetricsHasBeenSet = false; }; } // namespace Model } // namespace SageMaker } // namespace Aws