Skip to content
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

NameError: name 'predict_system' is not defined #11997

Closed
sugarandgugu opened this issue Apr 25, 2024 · 3 comments
Closed

NameError: name 'predict_system' is not defined #11997

sugarandgugu opened this issue Apr 25, 2024 · 3 comments
Assignees

Comments

@sugarandgugu
Copy link

请提供下述完整信息以便快速定位问题/Please provide the following information to quickly locate the problem

  • 系统环境/System Environment:
    MacBook M1 cpu
  • 版本号/Version:Paddle: PaddleOCR: 问题相关组件/Related components:
    paddlepaddle:2.6.1 paddleocr: 2.7.5
  • 运行指令/Command Code:
  • paddleocr --image_dir=/Downloads/1.jpg --type=structure --image_orientation=true
  • 完整报错/Complete Error Message:
image
@sugarandgugu
Copy link
Author

去源码里面进行修改在54行没有导入predict_system导致,可以将第54行改为如下部分,然后再报错的第576行将改成class PaddleOCR(TextSystem)即可。
from ppstructure.predict_system import StructureSystem, save_structure_res, to_excel,TextSystem
ref: https://blog.csdn.net/wang602125218/article/details/137175714

@UserWangZz
Copy link
Collaborator

感谢讨论,使用文档分析功能,也可以使用这个脚本ppstructure/predict_system.py哦

@xiaocode337317439
Copy link

去源码里面进行修改在54行没有导入predict_system导致,可以将第54行改为如下部分,然后再报错的第576行将改成class PaddleOCR(TextSystem)即可。 from ppstructure.predict_system import StructureSystem, save_structure_res, to_excel,TextSystem ref: https://blog.csdn.net/wang602125218/article/details/137175714

在docker build如何去修改?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants