airflow.providers.amazon.aws.sensors.sagemaker¶
Module Contents¶
Classes¶
| Contains general sensor behavior for SageMaker. | |
| Polls the endpoint state until it reaches a terminal state. Raises an | |
| Polls the transform job until it reaches a terminal state. Raises an | |
| Asks for the state of the tuning state until it reaches a terminal state. | |
| Polls the training job until it reaches a terminal state. Raises an | 
- class airflow.providers.amazon.aws.sensors.sagemaker.SageMakerBaseSensor(*, aws_conn_id='aws_default', **kwargs)[source]¶
- Bases: - airflow.sensors.base.BaseSensorOperator- Contains general sensor behavior for SageMaker. - Subclasses should implement get_sagemaker_response() and state_from_response() methods. Subclasses should also implement NON_TERMINAL_STATES and FAILED_STATE methods. - poke(self, context)[source]¶
- Function that the sensors defined while deriving this class should override. 
 - abstract non_terminal_states(self)[source]¶
- Placeholder for returning states with should not terminate. 
 
- class airflow.providers.amazon.aws.sensors.sagemaker.SageMakerEndpointSensor(*, endpoint_name, **kwargs)[source]¶
- Bases: - SageMakerBaseSensor- Polls the endpoint state until it reaches a terminal state. Raises an AirflowException with the failure reason if a failed state is reached. - See also - For more information on how to use this sensor, take a look at the guide: Wait on an Amazon SageMaker endpoint state - Parameters
- endpoint_name -- Name of the endpoint instance to watch. 
 
- class airflow.providers.amazon.aws.sensors.sagemaker.SageMakerTransformSensor(*, job_name, **kwargs)[source]¶
- Bases: - SageMakerBaseSensor- Polls the transform job until it reaches a terminal state. Raises an AirflowException with the failure reason if a failed state is reached. - See also - For more information on how to use this sensor, take a look at the guide: Wait on an Amazon SageMaker transform job state - Parameters
- job_name (str) -- Name of the transform job to watch. 
 
- class airflow.providers.amazon.aws.sensors.sagemaker.SageMakerTuningSensor(*, job_name, **kwargs)[source]¶
- Bases: - SageMakerBaseSensor- Asks for the state of the tuning state until it reaches a terminal state. Raises an AirflowException with the failure reason if a failed state is reached. - See also - For more information on how to use this sensor, take a look at the guide: Wait on an Amazon SageMaker tuning job state - Parameters
- job_name (str) -- Name of the tuning instance to watch. 
 
- class airflow.providers.amazon.aws.sensors.sagemaker.SageMakerTrainingSensor(*, job_name, print_log=True, **kwargs)[source]¶
- Bases: - SageMakerBaseSensor- Polls the training job until it reaches a terminal state. Raises an AirflowException with the failure reason if a failed state is reached. - See also - For more information on how to use this sensor, take a look at the guide: Wait on an Amazon SageMaker training job state - Parameters
- job_name -- Name of the training job to watch. 
- print_log -- Prints the cloudwatch log if True; Defaults to True. 
 
 
