Closed heXiangpeng closed 3 years ago
预测库是哪个版本的。也是develop分支的吗,试试编译Paddle-Lite 2.6.3分支
切换到2.6.3之后,按照deploy下lite目录下的文档 使用转化工具出现如下问题
/opt --model_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/model --param_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/params --optimize_out=./ch_ppocr_mobile_v1.1_rec_quant_opt --valid_targets=arm
报错如下: /Paddle-Lite/lite/core/optimizer.h:232 RunPasses] == Running pass: static_kernel_pick_pass [F 10/10 10:42:23.635 ...lite/core/mir/static_kernel_pick_pass.cc:65 Apply] Check failed: !instruct.kernels().empty(): No kernels found for fake_channel_wise_dequantize_max_abs [3] 56875 abort ./opt --model_file=./quant_model/model --param_file=./quant_model/params
切换到2.6.3之后,按照deploy下lite目录下的文档 使用转化工具出现如下问题
/opt --model_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/model --param_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/params --optimize_out=./ch_ppocr_mobile_v1.1_rec_quant_opt --valid_targets=arm
报错如下: /Paddle-Lite/lite/core/optimizer.h:232 RunPasses] == Running pass: static_kernel_pick_pass [F 10/10 10:42:23.635 ...lite/core/mir/static_kernel_pick_pass.cc:65 Apply] Check failed: !instruct.kernels().empty(): No kernels found for fake_channel_wise_dequantize_max_abs [3] 56875 abort ./opt --model_file=./quant_model/model --param_file=./quant_model/params
那还是用paddle-lite develop分支试一下吧
paddle-lite develop 分之的opt 和 预测库 在iOS 14中报错
报错代码
net_ocr1 = CreatePaddlePredictor<MobileConfig>(config);
Check failed: op: no Op found for feed
直接用官网的nb文件,paddle-lite 2.6.3 预测库报错
LoadModelNaiveFromFile] warning: the version of opt that transformed this model is not consistent with current Paddle-Lite version. version of opt:b92e8c4 version of current Paddle-Lite:v2.6.3 paddle-lite-ocr(2524,0x101a83880) malloc: can't allocate region : mach_vm_map(size=68719493120, flags: 100) failed (error code=3) paddle-lite-ocr(2524,0x101a83880) malloc: set a breakpoint in malloc_error_break to debug libc++abi.dylib: terminating with uncaught exception of type std::bad_alloc: std::bad_alloc terminating with uncaught exception of type std::bad_alloc: std::bad_alloc (lldb)
同样的问题 2.6.3模型初始化时报错bad_alloc;develop分支读取模型文件时报错no Op
同样的问题 2.6.3模型初始化时报错bad_alloc;develop分支读取模型文件时报错no Op
你解决了吗?
同样的问题 2.6.3模型初始化时报错bad_alloc;develop分支读取模型文件时报错no Op
你解决了吗?
没有 上周一直在换预测库和模型搞,一直有问题 两个git也没有更新 只能等等看了
同样的问题 2.6.3模型初始化时报错bad_alloc;develop分支读取模型文件时报错no Op
你解决了吗?
没有 上周一直在换预测库和模型搞,一直有问题 两个git也没有更新 只能等等看了
我也是天天看他们更新的代码
@LDOUBLEV 请看下当前进展
@heXiangpeng 你的可以跑了吗
Update:
@LDOUBLEV 我IOS这边用2.7的转换工具和预测库,转换工具在服务器上编译并转换,预测库在mac上编译,purne和原始的east都会报错:np Op found for feed
遇到了同样的问题,请问有新的进展吗? @qizhen816 @LDOUBLEV
没有进展,好像ios停止维护了
@qizhen816 @CoderMaurice iOS 修复了吗?
@qizhen816 @heXiangpeng @CoderMaurice @LDOUBLEV @shangzhizhou 有进展吗?同样的问题
使用的是静态库吗,静态库需要增加使用两个头文件:
/////////////////////////////////////////////////////////////////////////
// If this demo is linked to static library:libpaddle_api_light_bundled.a
// , you should include `paddle_use_ops.h` and `paddle_use_kernels.h` to
// avoid linking errors such as `unsupport ops or kernels`.
/////////////////////////////////////////////////////////////////////////
// #include "paddle_use_kernels.h" // NOLINT
// #include "paddle_use_ops.h" // NOLINT
@DannyIsFunny 好的,已经测试过lite 2.7 加了这个就运行正常了,感谢
@DannyIsFunny 多谢 搞定了
我放开了所有出现这两个头文件的地方编译了paddle lite 2.7 用的模型是 ch_ppocr_mobile_v1.1_det_prune_opt.nb ch_ppocr_mobile_v1.1_rec_quant_opt.nb 还是报no Op found for feed
@heXiangpeng @qizhen816 你们是怎么操作的?
@CoderMaurice 在你的IOS工程里引用这两个头文件了吗
@qizhen816 是这几个吗 我引用之后报错 no Op found for hard_swish
@CoderMaurice 先确认一下模型转换工具和预测库的版本是不是一致2.7,工程里include的头文件是不是2.7编译后自动生成的,不行的话试试转换工具用develop分支?我也不是很懂,这个hard_swish激活函数的问题貌似有人遇到过。
@qizhen816
重新转换了一遍模型还是报错
能麻烦把你的模型和paddlelite静态库发给我吗 maurice_mjn@foxmail.com
多谢
@CoderMaurice 我是用的east检测 发给你了
@qizhen816 谢谢 我刚搞定 原来是我编译的paddle lite有问题 使用了默认的参数 没有加 extra 和 cv 参数 现在一切正常
lite预测库编译
./lite/tools/build_ios.sh --arch=armv8 --with_cv=ON --with_extra=ON
develop分之模型转化
./opt --model_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/model --param_file=./ch_ppocr_mobile_v1.1_rec_quant_infer/params --optimize_out=./ch_ppocr_mobile_v1.1_rec_quant_opt --valid_targets=arm
这样转化出来的模型和预测库替换iOS demo中老的预测库和模型,出现如下错误
.wnloads/Paddle-Lite/lite/core/program.cc:187 RuntimeProgram] Check failed: op: no Op found for feed