labelImg command gives me the following error on my installation and I am unable to figure out a fix for the problem:
Traceback (most recent call last):
File "/usr/local/bin/labelImg", line 11, in <module>
sys.exit(main())
File "/home/shubham/.local/lib/python3.6/site-packages/labelImg/labelImg.py", line 1473, in main
app, _win = get_main_app(sys.argv)
File "/home/shubham/.local/lib/python3.6/site-packages/labelImg/labelImg.py", line 1466, in get_main_app
argv[3] if len(argv) >= 4 else None)
File "/home/shubham/.local/lib/python3.6/site-packages/labelImg/labelImg.py", line 130, in __init__
self.useDefaultLabelCheckbox = QCheckBox(getStr('useDefaultLabel'))
File "/home/shubham/.local/lib/python3.6/site-packages/labelImg/labelImg.py", line 95, in <lambda>
getStr = lambda strId: self.stringBundle.getString(strId)
File "/home/shubham/.local/lib/python3.6/site-packages/libs/stringBundle.py", line 36, in getString
assert(stringId in self.idToMessage), "Missing string id : " + stringId
AssertionError: Missing string id : useDefaultLabel
Did you forget to make ?
Try make qt5py3
I am having the same issue.
Platform: Windows + Anaconda
PyQt Version: pyqt 5
I cant make.
but I tried :
pyrcc5 -o resources.py resources.qrc
and then it works.
I am having the issue as well
Platform: MacOs Mojave10.14.1
PyQt Version: pyqt 5
I am having the issue as well
I was having the same issue on WIndows 10 + Anaconda platform with python 3.6. but as @zh7117 suggested
pyrcc5 -o resources.py resources.qrc works
i had tried it, we must cd into the LabelImg file and input the command "pyrcc5 -o resources.py resources.qrc"
There are new changes related to the resource. In general, it has to compile the resource again.
Go to the root, and run:
make qt5py3 or make qt4py2
I am having the issue as well
Platform: MacOs Mojave10.14.1
PyQt Version: pyqt 5
as @wuqingshan2010 action, I fixed it, thanks!
I am having the issue as well
Platform: MacOs Mojave10.14.1
PyQt Version: pyqt 5
how to solve
After tried all methods above (didn't work), I found out the solution.
(both MacOS Mojave and Catakiina, Python3, PyQt5)
cd into the LabelImg file and input the command: make all
then: python labelimg.py
In Windows + Anaconda installations, I am getting the same error.
Any solution found?
$>python labelImg.py
Traceback (most recent call last):
File "labelImg.py", line 1475, in <module>
sys.exit(main())
File "labelImg.py", line 1471, in main
app, _win = get_main_app(sys.argv)
File "labelImg.py", line 1464, in get_main_app
argv[3] if len(argv) >= 4 else None)
File "labelImg.py", line 120, in __init__
self.useDefaultLabelCheckbox = QCheckBox(getStr('useDefaultLabel'))
File "labelImg.py", line 85, in <lambda>
getStr = lambda strId: self.stringBundle.getString(strId)
File "C:\Users\Yaser.Sakkaf\Downloads\labelImg-master\libs\stringBundle.py", line 43, in getString
assert(stringId in self.idToMessage), "Missing string id : " + stringId
AssertionError: Missing string id : useDefaultLabel
I faced same issue and solving it like this:
cd path_to_lablelImg_folder
pyrcc5 -o resources.py resources.qrc
cd path_to_lablelImg_folder/libs
pyrcc5 -o resources.py resources.qrc
cd ..
python labelImg.py
I hope this help to all.
-notice: every line is separate command and my Platform is: Windows + Anaconda
Most helpful comment
I cant make.
but I tried :
pyrcc5 -o resources.py resources.qrc
and then it works.