Rya*_*her 5 python scikit-learn data-science amazon-sagemaker
我正在使用SageMaker python sdk并希望传入一些参数以供我的入口点使用,但我不知道如何执行此操作。
from sagemaker.sklearn.estimator import SKLearn # sagemaker python sdk
entrypoint = 'entrypoint_script.py'
sklearn = SKLearn(entry_point=entrypoint, # <-- need to pass args to this
train_instance_type=instance_class,
role=role,
sagemaker_session=sm)
Run Code Online (Sandbox Code Playgroud)
Rya*_*her 10
答案是否定的,因为 Estimator 基类或 fit 方法上没有参数可以接受传递给入口点的参数。
我通过将参数作为超参数字典的一部分传递来解决了这个问题。这将作为参数传递到入口点。
| 归档时间: |
|
| 查看次数: |
1668 次 |
| 最近记录: |