AWS:客户端:呼叫createTransFormjob操作时发生错误(验证Exception):找不到模型

发布于 2025-02-09 21:40:06 字数 1298 浏览 1 评论 0原文

我在这里是新手,对一些基本的事情感到沮丧。 我正在尝试实现DeepAR模型,但也许由于萨吉式制造商的更新,它找不到像示例上的正确路径。 有人可以告诉我为什么会发生以及如何修复它?

错误:客户端:呼叫createTransFormJob操作时发生错误(验证Exception):找不到模型“ ARN:AWS:AWS:SAGEMAKER:EU-CENTRAL-1:900386373554:Model/Model/forecasting-Deecasting-Deecar-2022-2022-2022-06-14-14-12-14-14-12 -51-560“。

这是我要实现的批处理

转换 : 导入boto3 - 创建SageMaker Boto3客户端 boto3_sm = boto3.client('sagemaker')

导入时间 从时间导入GMTime,strftime

batch_job_name ='batch-transform-' + strftime(“%y-%m-%d-%d-%h-%m-%s”,gmtime()) input_location ='s3://sagemaker-eu-central-1-900386373554/deepar-rossmann/input/prediction_input.json' output_location ='s3:// {}/{}/{}/output/{}'.format(bucket,prefix,batch_job_name)

request =
{ “批处理”:“ Singlerecord”, “ maxpayloadinmb”:100, “环境”: { “ deepar_inference_config”:“ {” {“ num_samples”:200,“ output_types”:[“ sane” sane']}” },, “ transformjobname”:batch_job_name, “ modelname”:'预测深度-2022-06-21-14-14-12-51-560', “ transformOutput”:{ “ s3Outputpath”:output_location, “接受”:“应用程序/jsonlines”, “ coptemblewith”:“ line” },, [...]

我正在关注此项目: https://githerline noreflofe 笔记本3 of 3步骤49-

> ModelName从AWS控制台完成的培训工作中复制

I am new here and am strugling with some basic things.
I am trying to implement a DeepAR model, but maybe due to an update from sagemaker it doesn't find the correct path as it did on the example..
Can someone tell me why is it happening and how o fix it?

Error: ClientError: An error occurred (ValidationException) when calling the CreateTransformJob operation: Could not find model "arn:aws:sagemaker:eu-central-1:900386373554:model/forecasting-deepar-2022-06-21-14-12-51-560".

This is the Batch Transformation I am trying to implement:

-Batch Transform
import boto3
-Create the SageMaker Boto3 client
boto3_sm = boto3.client('sagemaker')

import time
from time import gmtime, strftime

batch_job_name = 'Batch-Transform-' + strftime("%Y-%m-%d-%H-%M-%S", gmtime())
input_location = 's3://sagemaker-eu-central-1-900386373554/deepar-rossmann/input/prediction_input.json'
output_location = 's3://{}/{}/output/{}'.format(bucket, prefix, batch_job_name)

request =
{
"BatchStrategy": "SingleRecord",
"MaxPayloadInMB": 100,
"Environment": {
"DEEPAR_INFERENCE_CONFIG" : "{ "num_samples": 200, "output_types": ["mean"] }"
},
"TransformJobName": batch_job_name,
"ModelName": 'forecasting-deepar-2022-06-21-14-12-51-560',
"TransformOutput": {
"S3OutputPath": output_location,
"Accept": "application/jsonlines",
"AssembleWith": "Line"
},
[...]

I am following this project: https://github.com/CatherineSai/project_sales_prediction_DEEPAR
Notebook 3 of 3 step 49

--> ModelName is copied from the finished training job at aws console

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

少跟Wǒ拽 2025-02-16 21:40:06

为了启动SageMaker批处理转换作业,您需要sagemaker模型。请确认modelName您正在传递的model页面中的“ ”页面(推荐选项卡> models)

In order to launch a SageMaker Batch Transform Job you require a SageMaker Model. Kindly confirm that the ModelName you are passing exists in the Models page in the Console (Inference tab > Models)

enter image description here

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文