Skip to content

TrainingJobDefinition

Source code in docs_src/capo_sagemaker/types/training_job_definition.py
class TrainingJobDefinition(TypedDict, closed=True):
    training_input_mode: NotRequired[
        "capo_sagemaker.types.training_input_mode.TrainingInputMode"
    ]
    hyper_parameters: NotRequired[
        "capo_sagemaker.types.hyper_parameters.HyperParameters"
    ]
    """<p>The hyperparameters used for the training job.</p>"""
    input_data_config: NotRequired[
        "capo_sagemaker.types.input_data_config.InputDataConfig"
    ]
    """<p>An array of <code>Channel</code> objects, each of which specifies an input source.</p>"""
    output_data_config: NotRequired[
        "capo_sagemaker.types.output_data_config.OutputDataConfig"
    ]
    """<p>the path to the S3 bucket where you want to store model artifacts. SageMaker creates subfolders for the artifacts.</p>"""
    resource_config: NotRequired["capo_sagemaker.types.resource_config.ResourceConfig"]
    """<p>The resources, including the ML compute instances and ML storage volumes, to use for model training.</p>"""
    stopping_condition: NotRequired[
        "capo_sagemaker.types.stopping_condition.StoppingCondition"
    ]
    """<p>Specifies a limit to how long a model training job can run. It also specifies how long a managed Spot training job has to complete. When the job reaches the time limit, SageMaker ends the training job. Use this API to cap model training costs.</p> <p>To stop a job, SageMaker sends the algorithm the SIGTERM signal, which delays job termination for 120 seconds. Algorithms can use this 120-second window to save the model artifacts.</p>"""

hyper_parameters instance-attribute

hyper_parameters: NotRequired[HyperParameters]

The hyperparameters used for the training job.

input_data_config instance-attribute

input_data_config: NotRequired[InputDataConfig]

An array of Channel objects, each of which specifies an input source.

output_data_config instance-attribute

output_data_config: NotRequired[OutputDataConfig]

the path to the S3 bucket where you want to store model artifacts. SageMaker creates subfolders for the artifacts.

resource_config instance-attribute

resource_config: NotRequired[ResourceConfig]

The resources, including the ML compute instances and ML storage volumes, to use for model training.

stopping_condition instance-attribute

stopping_condition: NotRequired[StoppingCondition]

Specifies a limit to how long a model training job can run. It also specifies how long a managed Spot training job has to complete. When the job reaches the time limit, SageMaker ends the training job. Use this API to cap model training costs.

To stop a job, SageMaker sends the algorithm the SIGTERM signal, which delays job termination for 120 seconds. Algorithms can use this 120-second window to save the model artifacts.

training_input_mode instance-attribute

training_input_mode: NotRequired[TrainingInputMode]