-
Notifications
You must be signed in to change notification settings - Fork 7.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
paddlepaddle/paddle:3.0.0b2表格识别报错:InvalidArgumentError: The shape of input[0] and input[1] is expected to be equal #14163
Comments
试试使用paddlex可以正常推理吗?paddle3.0.0b2可能需要重新进行一下模型导出 |
|
文档里就有,用paddle3.0.0b2将动态图重新导出一下试试 |
请问该如何复现呢?目前无法复现 |
我也安装最新的docker也遇到这个问题 请问具体的模型导出文档再哪里呢 我找不到谢谢 |
同样的问题 |
问题一,图片中提取表格报错InvalidArgumentError,使用python中的标准库,paddleocr版本是2.9.1,怎么能够解决这个问题? |
我复现了问题,应该是paddle的默认行为导致了这个差异,我们需要将这个模型重新导出再上传一下,并且更改相关的模型代码,我先提供一个绕过去的方式:
|
修复PR已经合入,可以拉取main分支的代码,重新构建wheel,即可解决问题。当然paddleocr的下一个版本的wheel也会体现。 |
🔎 Search before asking
🐛 Bug (问题描述)
docker 在paddlepaddle/paddle:3.0.0b2环境尝试表格识别报错,提示:In user code:\n\n\n InvalidArgumentError: The shape of input[0] and input[1] is expected to be equal.But received input[0]'s shape = [], input[1]'s shape = [1].\n [Hint: Expected inputs_dims[i].size() == out_dims.size(), but received inputs_dims[i].size():1 != out_dims.size():0.] (at /paddle/paddle/phi/kernels/funcs/concat_funcs.h:55)\n [operator < pd_kernel.phi_kernel > error]
同样配置在paddlepaddle/paddle:2.6.2环境可以正常表格识别
🏃♂️ Environment (运行环境)
paddle = paddlepaddle/paddle:3.0.0b2
model = ch_ppstructure_mobile_v2.0_SLANet_infer/ch_ppstructure_openatom_SLANetv2_infer、ch_PP-OCRv4_det_infer、ch_PP-OCRv4_rec_infer
🌰 Minimal Reproducible Example (最小可复现问题的Demo)
python table/predict_structure.py --table_model_dir=../inference/ch_ppstructure_openatom_SLANetv2_infer/ --table_char_dict_path=../ppocr/utils/dict/table_structure_dict.txt --image_dir=docs/table/table.jpg --output=../output/table_slanet_lcnetv2 --use_gpu=False --enable_mkldnn=True --table_max_len=512
The text was updated successfully, but these errors were encountered: