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

Update requirements.txt to solve cv2 import error ( libGL.so.1 ) #38

Open
TarcisioOliveira2021 opened this issue Oct 25, 2024 · 0 comments

Comments

@TarcisioOliveira2021
Copy link

When I tried to run iasam_app.py, I encountered the following error:

File "/inpaint-anything/iasam_app.py", line 17, in <module>
    import cv2
File "/opt/conda/envs/inpaint/lib/python3.10/site-packages/cv2/__init__.py", line 181, in <module>
    bootstrap()
File "/opt/conda/envs/inpaint/lib/python3.10/site-packages/cv2/__init__.py", line 153, in bootstrap
    native_module = importlib.import_module("cv2")
File "/opt/conda/envs/inpaint/lib/python3.10/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
ImportError: libGL.so.1: cannot open shared object file: No such file or directory

After researching, I found a similar issue here: GitHub Issue #1270.

It seems like switching the OpenCV import to opencv-python-headless==4.8.1.78 is a good solution to avoid this error.

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

1 participant