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

cannot import properly on windows with python3.10 #68620

Open
3 tasks done
jianlins opened this issue Oct 9, 2024 · 2 comments
Open
3 tasks done

cannot import properly on windows with python3.10 #68620

jianlins opened this issue Oct 9, 2024 · 2 comments
Assignees

Comments

@jianlins
Copy link

jianlins commented Oct 9, 2024

🔎 Search before asking

  • I have searched the PaddleOCR Docs and found no similar bug report.
  • I have searched the PaddleOCR Issues and found no similar bug report.
  • I have searched the PaddleOCR Discussions and found no similar bug report.

🐛 Bug (问题描述)

When using:
from paddleocr import PaddleOCR
Get the following error:
lib\site-packages\paddle\base\core.py:375
366 if has_paddle_dy_lib:
367 sys.stderr.write(
368 'Error: Can not import paddle core while this file exists: '
369 + current_path
(...)
373 + '\n'
374 )
--> 375 if not avx_supported() and libpaddle.is_compiled_with_avx():
376 sys.stderr.write(
377 "Error: Your machine doesn't support AVX, but the installed PaddlePaddle is avx core, "
378 "you should reinstall paddlepaddle with no-avx core.\n"
379 )
380 raise e

NameError: name 'libpaddle' is not defined

🏃‍♂️ Environment (运行环境)

on windows 11 arm, not sure if other windows have the same issue.
conda create --name testocr python=3.10 pip
pip install paddlepaddle paddleocr

🌰 Minimal Reproducible Example (最小可复现问题的Demo)

python -c "from paddleocr import PaddleOCR;"

@GreatV GreatV transferred this issue from PaddlePaddle/PaddleOCR Oct 11, 2024
@wangna11BD
Copy link
Contributor

你的paddle未成功安装,windows安装paddle需要avx的包,你的机器不支持avx,可以运行paddle.utils.run_check() 确认paddle未成功安装。

@jianlins
Copy link
Author

There is no avx here: https://github.com/PaddlePaddle/Paddle/blob/develop/python/requirements.txt
Is this package I should try to install ? https://pypi.org/project/avx/
But this is likely a python2 package.

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

3 participants