CommandJobLimits Class

Limits for Command Jobs.

Inheritance
azure.ai.ml.entities._job.job_limits.JobLimits
CommandJobLimits

Constructor

CommandJobLimits(*, timeout: int | str | None = None)

Keyword-Only Parameters

Name Description
timeout

The maximum run duration, in seconds, after which the job will be cancelled.

Examples

Configuring a CommandJob with CommandJobLimits.


   command_job = CommandJob(
       code="./src",
       command="python train.py --ss {search_space.ss}",
       inputs={"input1": Input(path="trial.csv")},
       outputs={"default": Output(path="./foo")},
       compute="trial",
       environment="AzureML-sklearn-1.0-ubuntu20.04-py38-cpu:33",
       limits=CommandJobLimits(timeout=120),
   )