python - 安装 LabelImg Windows

标签 python image image-processing computer-vision

我尝试按照网站上的步骤安装 LabelImg (https://github.com/tzutalin/labelImg)。我已经安装了 PyQt4 和 lxml。但是当我运行这个命令时:

pyrcc4 -o resources.py resources.qrc

我收到这个错误:

C:\Users\Christian\Desktop\labelImg-1.7.0>pyrcc4 -o resources.py resources.qrc 'pyrcc4' is not recognized as an internal or external command, operable program or batch file.

尝试使用 pip 我得到这个错误:

C:\Users\Christian>pip install labelImg Collecting labelImg Using cached https://files.pythonhosted.org/packages/c1/5d/4b8a6dc5e352543199bc3991785af2e1cd58e50f1016e3725db826e3f4bb/labelImg-1.7.0.tar.gz Complete output from command python setup.py egg_info: Traceback (most recent call last): File "", line 1, in File "C:\Users\CHRIST~1\AppData\Local\Temp\pip-install-ifgpd1gr\labelImg\setup.py", line 8, in readme = readme_file.read() File "c:\users\christian\appdata\local\programs\python\python36\lib\encodings\cp1252.py", line 23, in decode return codecs.charmap_decode(input,self.errors,decoding_table)[0] UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position 7235: character maps to ---------------------------------------- Command "python setup.py egg_info" failed with error code 1 in C:\Users\CHRIST~1\AppData\Local\Temp\pip-install-ifgpd1gr\labelImg\

我想在没有预构建二进制文件的情况下安装它,因为我想修改 labelImg 以便它保留以前图片的注释,如下所示:https://github.com/tzutalin/labelImg/issues/118

感谢您的任何提示!

编辑:(将 pyrcc4 添加到我的 PATH 变量后)

C:\Users\Christian\Desktop\labelImg-1.7.0>pyrcc4 -o resources.py resources.qrc
C:\Users\Christian\Desktop\labelImg-1.7.0>python labelImg.py

现在我得到这个错误:

Traceback (most recent call last): File "labelImg.py", line 29, in import resources File "C:\Users\Christian\Desktop\labelImg-1.7.0\resources.py", line 9, in from PyQt4 import QtCore ValueError: PyCapsule_GetPointer called with incorrect name

最佳答案

通过安装Python3
https://www.python.org/downloads/release/python-357/
使用以下命令通过 PIP 安装 PyQt5 和 lxml
pip3 安装 pyqt5 lxml

**Download, unzip and run the LabelImg.exe file via**

https://www.dropbox.com/s/kqoxr10l3rkstqd/windows_v1.8.0.zip?dl=1

关于python - 安装 LabelImg Windows,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52259623/

相关文章:

python - 在 Django 管理中,在初始保存时发推文?

image - 图片的默认过期时间

python - 如何使用 python 和 opencv 查找图像的 pca?

javascript - 随着变量的增加,如何逐像素重新创建预制 png

matlab - medfilt2 过滤器期望输入是二维的

python - 使用现有主键插入的惩罚?

python - 替换python中的多字节字符

python - Windows 上 Python 中的 Wordcloud

image - 变形 2 张面孔图像

html - 通过 SVG 将图像添加到列表中