I'm trying to merge my ground truth values with data captured(for Model Quality Monitoring) using sagemaker-model-monitor-groundtruth-merger container image.
def run_merge_job_processor(
region,
instance_type,
role,
bucket_name,
groundtruth_path,
endpoint_input,
merge_path,
instance_count=1,
):
groundtruth_input_1 = ProcessingInput(input_name="groundtruth_input_1",
source="s3://{}/{}".format(bucket_name, groundtruth_path),
destination=f"/opt/ml/processing/groundtruth{datetime.utcnow():%Y/%m/%d/%H}",
s3_data_type="S3Prefix",
s3_input_mode="File")
"/".join(endpoint_input.split("/")[3:])
endpoint_input_1 = ProcessingInput(
input_name="endpoint_input_1",
source="s3://{}/{}".format(bucket_name, endpoint_input),
destination="/opt/ml/processing/input_data/{}".format("/".join(endpoint_input.split("/")[3:])),
s3_data_type="S3Prefix",
s3_input_mode="File")
output = ProcessingOutput(
output_name="result",
source="/opt/ml/processing/output",
destination=f"s3://{bucket_name}/{merge_path}")
inputs = [ groundtruth_input_1, endpoint_input_1 ]
outputs = [ output ]
env = {
"dataset_format": "{\"sagemakerCaptureJson\": {\"captureIndexNames\": [\"endpointInput\",\"endpointOutput\"]}}",
'dataset_source': '/opt/ml/processing/input_data',
'ground_truth_source': '/opt/ml/processing/groundtruth',
'output_path': '/opt/ml/processing/output'
}
processor = Processor(image_uri=get_model_monitor_container_uri(region),
instance_count=instance_count,
instance_type=instance_type,
role=role,
env=env,
)
return processor.run(
inputs=inputs,
outputs=outputs,
wait=True
The above code that I've used for creating the processing job where my processing job is getting failed with the following error.

