LabelImg 是影像標註工具,它是用python 和 QT 寫成的.
支持的儲存格式包括PASCAL VOC format, YOLO, createML.
Linux/Ubuntu/Mac 需要 Python 和 PyQt
Python 3 + Qt5
sudo apt-get install pyqt5-dev-tools
sudo pip3 install -r requirements/requirements-linux-python3.txt
make qt5py3
python3 labelImg.py
python3 labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
Python 3 + Qt5
brew install qt # Install qt-5.x.x by Homebrew
brew install libxml2
or using pip
pip3 install pyqt5 lxml # Install qt and lxml by pip
make qt5py3
python3 labelImg.py
python3 labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
Python 3 Virtualenv (推薦方法)
Virtualenv 可以避免版本和相依性問題
brew install python3
pip3 install pipenv
pipenv run pip install pyqt5==5.15.2 lxml
pipenv run make qt5py3
pipenv run python3 labelImg.py
[Optional] rm -rf build dist; python setup.py py2app -A;mv "dist/labelImg.app" /Applications
安裝 Python, PyQt5 和 install lxml.
安裝並到 labelImg 目錄
pyrcc4 -o libs/resources.py resources.qrc
For pyqt5, pyrcc5 -o libs/resources.py resources.qrc
python labelImg.py
python labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
下載並安裝 Anaconda (Python 3+)
打開 Anaconda Prompt 然後到 labelImg 目錄
conda install pyqt=5
conda install -c anaconda lxml
pyrcc5 -o libs/resources.py resources.qrc
python labelImg.py
python labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
pip3 install labelImg
labelImg
labelImg [IMAGE_PATH] [PRE-DEFINED CLASS FILE]
docker run -it \
--user $(id -u) \
-e DISPLAY=unix$DISPLAY \
--workdir=$(pwd) \
--volume="/home/$USER:/home/$USER" \
--volume="/etc/group:/etc/group:ro" \
--volume="/etc/passwd:/etc/passwd:ro" \
--volume="/etc/shadow:/etc/shadow:ro" \
--volume="/etc/sudoers.d:/etc/sudoers.d:ro" \
-v /tmp/.X11-unix:/tmp/.X11-unix \
tzutalin/py2qt4
make qt4py2;./labelImg.py
修改這個檔案 data/predefined_classes.txt
Ctrl + u | 讀取所有影像從每個目錄 |
Ctrl + r | 改變標示結果的存檔目錄 |
Ctrl + s | 存檔 |
Ctrl + d | 複製目前的標籤和物件的區塊 |
Ctrl + Shift + d | 刪除目前影像 |
Space | 標示目前照片已經處理過 |
w | 產生新的物件區塊 |
d | 下張影像 |
a | 上張影像 |
del | 刪除所選的物件區塊 |
Ctrl++ | 放大影像 |
Ctrl-- | 縮小影像 |
↑→↓← | 移動所選的物件區塊 |
歡迎上傳程式碼直接貢獻