PaddlePaddle / X2Paddle

Deep learning model converter for PaddlePaddle. (『飞桨』深度学习模型转换工具)
http://www.paddlepaddle.org/
Apache License 2.0
736 stars 164 forks source link

onnx转换paddle报错AssertionError: Couldn't find x2paddle_1322 in previous layers, the layers should be make by topological sort #916

Open ffbai opened 1 year ago

ffbai commented 1 year ago

感谢您参与 X2Paddle 社区! 问题模版为了 X2Paddle 能更好的迭代,例如新功能发布、 RoadMaps 和错误跟踪. :smile_cat:

问题描述

Traceback (most recent call last): File "C:\Users\35357\AppData\Local\Continuum\anaconda3\lib\runpy.py", line 193, in _run_module_as_main "main", mod_spec) File "C:\Users\35357\AppData\Local\Continuum\anaconda3\lib\runpy.py", line 85, in _run_code exec(code, run_globals) File "C:\Users\35357\AppData\Local\Continuum\anaconda3\Scripts\x2paddle.exe__main__.py", line 7, in File "C:\Users\35357\AppData\Local\Continuum\anaconda3\lib\site-packages\x2paddle\convert.py", line 488, in main enable_onnx_checker=args.enable_onnx_checker) File "C:\Users\35357\AppData\Local\Continuum\anaconda3\lib\site-packages\x2paddle\convert.py", line 297, in onnx2paddle mapper.paddle_graph.build() File "C:\Users\35357\AppData\Local\Continuum\anaconda3\lib\site-packages\x2paddle\core\program.py", line 180, in build v) AssertionError: Couldn't find x2paddle_1322 in previous layers, the layers should be make by topological sort

具体信息

ffbai commented 1 year ago

onnx文件 链接:https://pan.baidu.com/s/1DKWwE5q_LZwWAx2pQ852qQ 提取码:1111

wjj19950828 commented 1 year ago

@ffbai 感谢反馈,这个具体是哪个模型呢,可以给一下repo链接吗

另外,可以描述一下以下两个问题吗: 1、具体业务场景 2、为什么有转到Paddle部署的需求呢?

感谢~

wjj19950828 commented 1 year ago

@ffbai Bug已在这个PR修复,可以拉去对应代码手动安装下,我这边验证无问题:https://github.com/PaddlePaddle/X2Paddle/pull/917

ffbai commented 1 year ago

谢谢!

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2022年12月5日(星期一) 下午2:29 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [PaddlePaddle/X2Paddle] onnx转换paddle报错AssertionError: Couldn't find x2paddle_1322 in previous layers, the layers should be make by topological sort (Issue #916)

@ffbai Bug已在这个PR修复,可以拉去对应代码手动安装下,我这边验证无问题:#917

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.***>

wjj19950828 commented 1 year ago

@ffbai 这是哪个模型呢,有开源代码吗

ffbai commented 1 year ago

@ffbai 这是哪个模型呢,有开源代码吗

论文刚见刊 代码还没有上传哦

ffbai commented 1 year ago

`from paddlelite.lite import *

opt=Opt() opt.set_model_dir("./LDNet/inference_model") opt.set_valid_places("arm") opt.set_model_type("naive_buffer") opt.set_optimize_out("model") opt.run()` 已经成功转化到paddle了 可是下一步转化.nb又报错了,上面是转换代码,报错信息如下: Loading topology data from ./LDNet/inference_model/model.pdmodel Loading params data from ./LDNet/inference_model/model.pdiparams

  1. Model is successfully loaded!

Process finished with exit code -1073741819 (0xC0000005) 已经用其他paddle模型尝试 不是文件路径的问题

wjj19950828 commented 1 year ago

@ffbai 转nb问题可以去PaddleLite Issue咨询

ffbai commented 1 year ago

好的谢谢

------------------ 原始邮件 ------------------ 发件人: @.>; 发送时间: 2022年12月5日(星期一) 下午4:43 收件人: @.>; 抄送: @.>; @.>; 主题: Re: [PaddlePaddle/X2Paddle] onnx转换paddle报错AssertionError: Couldn't find x2paddle_1322 in previous layers, the layers should be make by topological sort (Issue #916)

@ffbai 转nb问题可以去PaddleLite Issue咨询

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you were mentioned.Message ID: @.***>