开发者社区 > 大数据与机器学习 > 人工智能平台PAI > 正文

麻烦您给看个机器学习PAI报错,客户说是使用multitower模型,打分报错。?

问题1:麻烦您给看个机器学习PAI报错,客户说是使用multitower模型,打分报错。https://easyrec.readthedocs.io/en/latest/models/multi_tower.html
6f07b35c-b3fa-4684-8af1-3ccc7f0e3e3a-20230727154839-396
[2023-07-27 15:23:29] 2023-07-27 15:23:29.130182: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:29] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:29] 2023-07-27 15:23:29.147776: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:29] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:29] 2023-07-27 15:23:29.161761: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:29] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:29] 2023-07-27 15:23:29.172331: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:29] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:38] 2023-07-27 15:23:38.001328: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:38] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:38] 2023-07-27 15:23:38.023058: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:38] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:38] 2023-07-27 15:23:38.059251: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:38] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:38] 2023-07-27 15:23:38.069146: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:38] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:44] 2023-07-27 15:23:44.809759: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:44] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:44] 2023-07-27 15:23:44.831616: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:44] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:44] 2023-07-27 15:23:44.844542: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:44] [[{{node input_layer/concat}}]]
[2023-07-27 15:23:44] 2023-07-27 15:23:44.877554: E /larec/larec/processor/saved_model_loader.cpp:1747] Call Session Run Error: ConcatOp : Dimension 0 in both shapes must be equal: shape[0] = [2,1] vs. shape[1] = [1,8]
[2023-07-27 15:23:44] [[{{node input_layer/concat}}]],之前feature_type :raw_feature 的加了embedding_dim:8
为了优化打分速度去掉embedding_dim:8 ,然后dataworks里可以跑出predict 但是eas里发送请求打分就会报错
问题2:这个是一个user 但是是两个item的,这个可以吗

展开
收起
cuicuicuic 2023-07-31 08:28:04 49 0
2 条回答
写回答
取消 提交回答
  • 当涉及到使用 Multitower 模型并且在打分过程中出现报错时,需要更多的上下文信息才能准确地确定问题所在。以下是一些常见的可能原因和解决方案:

    1. 训练和评估阶段的模型配置不匹配:请确保训练和评估阶段使用相同的 Multitower 模型配置。检查模型的层次结构、输入特征和输出设置是否一致,并确认评估阶段加载了正确的模型参数。

    2. 输入数据的格式错误:检查输入数据的格式是否与模型的要求一致。Multitower 模型通常期望多个输入特征,每个特征可能具有不同的维度或形状。确保输入数据的特征顺序和形状与模型的期望相匹配。

    3. 数据预处理问题:如果在 Multitower 模型中进行了任何数据预处理操作,请确保这些预处理操作在评估阶段也得到正确应用。例如,图像数据的缩放、归一化或标准化等操作应该与训练阶段一致。

    4. 模型参数加载问题:确保在评估阶段正确加载了模型的参数。检查模型参数文件路径或加载代码部分,确保路径正确以及文件存在。

    5. 联系技术支持:如果以上措施都无法解决问题,建议联系机器学习 PAI 的技术支持团队。提供详细的错误信息、模型配置、数据示例以及相关代码片段,以便他们能够更好地帮助您。

    2023-07-31 16:30:07
    赞同 展开评论 打赏
  • 回答1:一次请求只能打一个user的分,不能打两个
    回答2:可以的,那你检查一下你的请求,应该有item特征错误的标记成了user特征,此回答整理自钉群“【EasyRec】推荐算法交流群”

    2023-07-31 09:24:24
    赞同 展开评论 打赏

相关产品

  • 人工智能平台 PAI
  • 热门讨论

    热门文章

    相关电子书

    更多
    大规模机器学习在蚂蚁+阿里的应用 立即下载
    基于Spark的面向十亿级别特征的 大规模机器学习 立即下载
    基于Spark的大规模机器学习在微博的应用 立即下载