This is the new CloudFormation Template Reference Guide. Please update your bookmarks and links. For help getting started with CloudFormation, see the AWS CloudFormation User Guide.
AWS::SageMaker::TrainingJob AlgorithmSpecification
Specifies the training algorithm to use in a CreateTrainingJob request.
Important
SageMaker uses its own SageMaker account credentials to pull and access built-in algorithms so built-in algorithms are universally accessible across all AWS accounts. As a result, built-in algorithms have standard, unrestricted access. You cannot restrict built-in algorithms using IAM roles. Use custom algorithms if you require specific access controls.
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.
Syntax
To declare this entity in your CloudFormation template, use the following syntax:
JSON
{ "AlgorithmName" :String, "ContainerArguments" :[ String, ... ], "ContainerEntrypoint" :[ String, ... ], "EnableSageMakerMetricsTimeSeries" :Boolean, "MetricDefinitions" :[ MetricDefinition, ... ], "TrainingImage" :String, "TrainingImageConfig" :TrainingImageConfig, "TrainingInputMode" :String}
YAML
AlgorithmName:StringContainerArguments:- StringContainerEntrypoint:- StringEnableSageMakerMetricsTimeSeries:BooleanMetricDefinitions:- MetricDefinitionTrainingImage:StringTrainingImageConfig:TrainingImageConfigTrainingInputMode:String
Properties
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 AWS Marketplace.
Note
You must specify either the algorithm name to the
AlgorithmNameparameter or the image URI of the algorithm container to theTrainingImageparameter.Note that the
AlgorithmNameparameter is mutually exclusive with theTrainingImageparameter. If you specify a value for theAlgorithmNameparameter, you can't specify a value forTrainingImage, 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
nullerror.Required: No
Type: String
Pattern:
(arn:aws[a-z\-]*:sagemaker:[a-z0-9\-]*:[0-9]{12}:[a-z\-]*\/)?([a-zA-Z0-9]([a-zA-Z0-9-]){0,62})(?<!-)$Minimum:
1Maximum:
170Update requires: Replacement
ContainerArguments-
The arguments for a container used to run a training job. See How Amazon SageMaker Runs Your Training Image for additional information.
Required: No
Type: Array of String
Maximum:
256 | 100Update requires: Replacement
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. Required: No
Type: Array of String
Maximum:
256 | 100Update requires: Replacement
EnableSageMakerMetricsTimeSeries-
To generate and save time-series metrics during training, set to
true. The default isfalseand 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
Required: No
Type: Boolean
Update requires: Replacement
-
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.
Required: No
Type: Array of MetricDefinition
Maximum:
40Update requires: Replacement
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]andregistry/repository[@digest]image path formats. For more information about using your custom training container, see Using Your Own Algorithms with Amazon SageMaker.Note
You must specify either the algorithm name to the
AlgorithmNameparameter or the image URI of the algorithm container to theTrainingImageparameter.For more information, see the note in the
AlgorithmNameparameter description.Required: No
Type: String
Pattern:
.*Maximum:
255Update requires: Replacement
TrainingImageConfig-
The configuration to use an image from a private Docker registry for a training job.
Required: No
Type: TrainingImageConfig
Update requires: Replacement
TrainingInputModeProperty description not available.
Required: Yes
Type: String
Allowed values:
Pipe | File | FastFileUpdate requires: Replacement