gpt4 book ai didi

Python - 带有线程错误的pyqt xcb插件

转载 作者:行者123 更新时间:2023-12-05 01:53:46 25 4
gpt4 key购买 nike

我正在使用 Ubuntu,当我从 pyqt 运行我的程序时,出现了这个错误,

QObject::moveToThread: Current thread (0xa549e0) is not the object's thread (0x4b7bfc0).
Cannot move to target thread (0xa549e0)

qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "/home/mialo/.local/lib/python3.8/site-packages/cv2/qt/plugins" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: xcb, eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, webgl.

Aborted (core dumped)

pip3 list|grep Qt 这个命令,我得到了

PyQt5                        5.15.5              
PyQt5-Qt5 5.15.2
PyQt5-sip 12.9.0
QtPy 1.11.1

我尝试了很多解决方案,包括卸载 opencv-python 和安装 opencv-headless、export DISPLAY=:1.0

但是没有任何效果,我们应该怎么做才能解决这个问题,

谢谢

最佳答案

你在 python 代码中使用 opencv 吗?

尝试:pip 卸载 opencv-python, 并在代码中删除你的 cv2

如果可行,请降级您的 opencv-python,可能是 opencv-python==4.3.0.36

更多信息请看这里: https://github.com/Yuliang-Liu/Curve-Text-Detector/issues/11

关于Python - 带有线程错误的pyqt xcb插件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71029300/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com