aws / aws/aws-step-functions-data-science-sdk-python

adding tags to a Sagemaker estimator in the training step does not seem to be supported

Đang mở
#200 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
bug
Ngôn ngữ chính
Python
Star
299
Fork
84
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Extract from the workbook "machine_learning_workflow_abalone.ipynb"
When adding tags in the following estimator :

mes_tags = [{'key': 'cart', 'value': 'dataengineering'}]

xgb = sagemaker.estimator.Estimator(
image_uris.retrieve("xgboost", region, "1.2-1"),
sagemaker_execution_role,
train_instance_count=1,
train_instance_type="ml.m4.4xlarge",
train_volume_size=5,
output_path=bucket_path + "/" + prefix + "/single-xgboost",
base_job_name=base_job_name,
tags=mes_tags,
sagemaker_session=session,
)
No error when creating the sagemaker.estimator object

The workflow creation fails
When running the command (later in the notebook):
workflow.create()
I got the exception :
"InvalidDefinition: An error occurred (InvalidDefinition) when calling the CreateStateMachine operation: Invalid State Machine Definition: 'SCHEMA_VALIDATION_FAILED: The field "key" is not supported by Step Functions at /States/Train Step/Parameters"

Which is clearly related to the tags I previously added.
Apparently, adding tags to a Sagemaker estimator in the training step does not seem to be supported by the current version of the SDK.

To reproduce
You can comment "tags=mes_tags" and re-rerun the notebook and the state machine is created without any errors.

Logs
Only the stack trace in the notebook

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Start with machine_learning_workflow_abalone.ipynb and compare workflow.create() with and without the estimator's tags argument. Inspect the generated Train Step Parameters around the reported key validation error and the estimator/workflow entry points involved. Done means the tagged training workflow is accepted by Step Functions without the reported InvalidDefinition error.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
aws, jupyter-notebook, python
Lĩnh vực
cloud, machine-learning
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
45/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.