/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
/*
* Do not modify this file. This file is generated from the sagemaker-2017-07-24.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;
using System.Net;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
namespace Amazon.SageMaker.Model
{
///
/// Specifies the training algorithm to use in a CreateTrainingJob
/// request.
///
///
///
/// For more information about algorithms provided by SageMaker, see Algorithms.
/// For information about using your own algorithms, see Using
/// Your Own Algorithms with Amazon SageMaker.
///
///
public partial class AlgorithmSpecification
{
private string _algorithmName;
private List _containerArguments = new List();
private List _containerEntrypoint = new List();
private bool? _enableSageMakerMetricsTimeSeries;
private List _metricDefinitions = new List();
private string _trainingImage;
private TrainingImageConfig _trainingImageConfig;
private TrainingInputMode _trainingInputMode;
///
/// Gets and sets the property AlgorithmName.
///
/// The name of the algorithm resource to use for the training job. This must be an algorithm
/// resource that you created or subscribe to on Amazon Web Services Marketplace.
///
///
///
/// You must specify either the algorithm name to the AlgorithmName
parameter
/// or the image URI of the algorithm container to the TrainingImage
parameter.
///
///
///
/// Note that the AlgorithmName
parameter is mutually exclusive with the
/// TrainingImage
parameter. If you specify a value for the AlgorithmName
/// parameter, you can't specify a value for TrainingImage
, and vice versa.
///
///
///
/// If you specify values for both parameters, the training job might break; if you don't
/// specify any value for both parameters, the training job might raise a null
/// error.
///
///
///
[AWSProperty(Min=1, Max=170)]
public string AlgorithmName
{
get { return this._algorithmName; }
set { this._algorithmName = value; }
}
// Check to see if AlgorithmName property is set
internal bool IsSetAlgorithmName()
{
return this._algorithmName != null;
}
///
/// Gets and sets the property ContainerArguments.
///
/// The arguments for a container used to run a training job. See How
/// Amazon SageMaker Runs Your Training Image for additional information.
///
///
[AWSProperty(Min=1, Max=100)]
public List ContainerArguments
{
get { return this._containerArguments; }
set { this._containerArguments = value; }
}
// Check to see if ContainerArguments property is set
internal bool IsSetContainerArguments()
{
return this._containerArguments != null && this._containerArguments.Count > 0;
}
///
/// Gets and sets the property ContainerEntrypoint.
///
/// The entrypoint script
/// for a Docker container used to run a training job. This script takes precedence
/// over the default train processing instructions. See How
/// Amazon SageMaker Runs Your Training Image for more information.
///
///
[AWSProperty(Min=1, Max=10)]
public List ContainerEntrypoint
{
get { return this._containerEntrypoint; }
set { this._containerEntrypoint = value; }
}
// Check to see if ContainerEntrypoint property is set
internal bool IsSetContainerEntrypoint()
{
return this._containerEntrypoint != null && this._containerEntrypoint.Count > 0;
}
///
/// Gets and sets the property EnableSageMakerMetricsTimeSeries.
///
/// To generate and save time-series metrics during training, set to true
.
/// The default is false
and time-series metrics aren't generated except
/// in the following cases:
///
/// -
///
/// You use one of the SageMaker built-in algorithms
///
///
-
///
/// You use one of the following Prebuilt
/// SageMaker Docker Images:
///
///
-
///
/// Tensorflow (version >= 1.15)
///
///
-
///
/// MXNet (version >= 1.6)
///
///
-
///
/// PyTorch (version >= 1.3)
///
///
-
///
/// You specify at least one MetricDefinition
///
///
///
///
public bool EnableSageMakerMetricsTimeSeries
{
get { return this._enableSageMakerMetricsTimeSeries.GetValueOrDefault(); }
set { this._enableSageMakerMetricsTimeSeries = value; }
}
// Check to see if EnableSageMakerMetricsTimeSeries property is set
internal bool IsSetEnableSageMakerMetricsTimeSeries()
{
return this._enableSageMakerMetricsTimeSeries.HasValue;
}
///
/// Gets and sets the property MetricDefinitions.
///
/// A list of metric definition objects. Each object specifies the metric name and regular
/// expressions used to parse algorithm logs. SageMaker publishes each metric to Amazon
/// CloudWatch.
///
///
[AWSProperty(Min=0, Max=40)]
public List MetricDefinitions
{
get { return this._metricDefinitions; }
set { this._metricDefinitions = value; }
}
// Check to see if MetricDefinitions property is set
internal bool IsSetMetricDefinitions()
{
return this._metricDefinitions != null && this._metricDefinitions.Count > 0;
}
///
/// Gets and sets the property TrainingImage.
///
/// The registry path of the Docker image that contains the training algorithm. For information
/// about docker registry paths for SageMaker built-in algorithms, see Docker
/// Registry Paths and Example Code in the Amazon SageMaker developer guide.
/// SageMaker supports both registry/repository[:tag]
and registry/repository[@digest]
/// image path formats. For more information about using your custom training container,
/// see Using
/// Your Own Algorithms with Amazon SageMaker.
///
///
///
/// You must specify either the algorithm name to the AlgorithmName
parameter
/// or the image URI of the algorithm container to the TrainingImage
parameter.
///
///
///
/// For more information, see the note in the AlgorithmName
parameter description.
///
///
///
[AWSProperty(Max=255)]
public string TrainingImage
{
get { return this._trainingImage; }
set { this._trainingImage = value; }
}
// Check to see if TrainingImage property is set
internal bool IsSetTrainingImage()
{
return this._trainingImage != null;
}
///
/// Gets and sets the property TrainingImageConfig.
///
/// The configuration to use an image from a private Docker registry for a training job.
///
///
public TrainingImageConfig TrainingImageConfig
{
get { return this._trainingImageConfig; }
set { this._trainingImageConfig = value; }
}
// Check to see if TrainingImageConfig property is set
internal bool IsSetTrainingImageConfig()
{
return this._trainingImageConfig != null;
}
///
/// Gets and sets the property TrainingInputMode.
///
[AWSProperty(Required=true)]
public TrainingInputMode TrainingInputMode
{
get { return this._trainingInputMode; }
set { this._trainingInputMode = value; }
}
// Check to see if TrainingInputMode property is set
internal bool IsSetTrainingInputMode()
{
return this._trainingInputMode != null;
}
}
}