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

ModuleNotFoundError: No module named 'general_ocr._ext' #5

Open
ngthanhtin opened this issue Oct 26, 2021 · 3 comments
Open

ModuleNotFoundError: No module named 'general_ocr._ext' #5

ngthanhtin opened this issue Oct 26, 2021 · 3 comments

Comments

@ngthanhtin
Copy link

Dear author,
When I run the test command: python general_ocr/utils/ocr.py demo/mrbean.png --print-result --imshow --det TextSnake --recog SEG

The output error is like this: ModuleNotFoundError: No module named 'general_ocr._ext', although I have installed the repo following the instruction in https://github.com/phamdinhkhanh/general_ocr/blob/main/docs/install.md.

Do you know the problem and how to fix that, please?

@phamdinhkhanh
Copy link
Owner

gneeral_ocr._ext is a bunch of extension modules in general_ocr which load from pytorch. Thus you have to respond the configuration requirements before installing. Run code collect_env.py to show us your computer environment.

@ngthanhtin
Copy link
Author

I can not run collect_env.py because it imports the general_ocr module as well, so I also encounter the same error when running this file.

@phamdinhkhanh
Copy link
Owner

phamdinhkhanh commented Oct 26, 2021

Because you have not successfully installed it yet. So you can not import general_ocr package. I suggest you append absolute path of general_ocr module inside your code collect_env.py:

import sys
sys.path.append('your absolute path/general_general/general_ocr')

And take attention to 1.1. Prerequisites. You have to meet them all.

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

No branches or pull requests

2 participants