我无法使用 labelLImg 标记图像

Ahm*_*man 5 computer-vision deep-learning conv-neural-network tensorflow labelimg


我是使用 python tensorflow 进行对象检测的新手,我的文件夹包含我需要标记的图像,因此我下载 pyqt5 、 lableImg ,当我打开 labelImg 并选择我的图像文件夹的目录时,它工作正常并在 labelImg 中打开文件夹但是当我选择创建矩形框并转到图像在其上绘制矩形标签,labelImg停止运行,然后在cmd上出现此错误:

Traceback (most recent call last):
  File "C:\Users\DCLAP\AppData\Local\Programs\Python\Python310\lib\site-packages\libs\canvas.py", line 530, in paintEvent
    p.drawLine(self.prev_point.x(), 0, self.prev_point.x(), self.pixmap.height())
TypeError: arguments did not match any overloaded call:
  drawLine(self, QLineF): argument 1 has unexpected type 'float'
  drawLine(self, QLine): argument 1 has unexpected type 'float'
  drawLine(self, int, int, int, int): argument 1 has unexpected type 'float'
  drawLine(self, QPoint, QPoint): argument 1 has unexpected type 'float'
  drawLine(self, Union[QPointF, QPoint], Union[QPointF, QPoint]): argument 1 has unexpected type 'float'

Run Code Online (Sandbox Code Playgroud)

github 上的 LabelImg 存储库我的文件夹包含 jpg 照片和不同的图像大小,所以我希望有人可以提供帮助,谢谢。

mar*_*lli 5

显然问题出在 Python 3.10 上:https://github.com/tzutalin/labelImg/issues/811

您可以降级到 Python 3.9 或使用 labelImg 的 master 分支,它应该已经有修复。