describeTrainingJob method

Future<DescribeTrainingJobResponse> describeTrainingJob({
  1. required String trainingJobName,
})

Returns information about a training job.

Some of the attributes below only appear if the training job successfully starts. If the training job fails, TrainingJobStatus is Failed and, depending on the FailureReason, attributes like TrainingStartTime, TrainingTimeInSeconds, TrainingEndTime, and BillableTimeInSeconds may not be present in the response.

May throw ResourceNotFound.

Parameter trainingJobName : The name of the training job.

Implementation

Future<DescribeTrainingJobResponse> describeTrainingJob({
  required String trainingJobName,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SageMaker.DescribeTrainingJob'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'TrainingJobName': trainingJobName,
    },
  );

  return DescribeTrainingJobResponse.fromJson(jsonResponse.body);
}