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

qt.qpa.plugin: Could not find the Qt platform plugin "offscreen" in "/root/miniconda3/envs/human/lib/python3.8/site-packages/cv2/qt/plugins" #26

Open
einstein99ium opened this issue Jul 21, 2024 · 1 comment

Comments

@einstein99ium
Copy link

I got an error about opencv-python-4.10.0.84:

qt.qpa.plugin: Could not find the Qt platform plugin "offscreen" in "/root/miniconda3/envs/human/lib/python3.8/site-packages/cv2/qt/plugins.This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem."

and I tried 3 methods:

  1. pip install opencv-pythonand pip install opencv-python-headless. then the error occurred

cv2.error: OpenCV(4.10.0) /io/opencv/modules/highgui/src/window.cpp:1284: error: (-2:Unspecified error) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Cocoa support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function 'cvNamedWindow'

  1. pip install PyQt5or pip install PyQt6didn't work
  2. remove the folder /root/miniconda3/envs/human/lib/python3.8/site-packages/cv2/qt/plugins didn't work.
@einstein99ium
Copy link
Author

This error will cause all gui-related functions of cv2,like cv2.imshow() and cv2.waitKey() to be unavailable. I don’t know if it’s because of this that ,process1.join() has never been able to end.By the way,I tried lowering the version of opencv-python to 3.4.18.65,it didn't work.

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