资源简介
图片标注工具
代码片段和文件信息
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import codecs
import distutils.spawn
import os.path
import platform
import re
import sys
import subprocess
from functools import partial
from collections import defaultdict
try:
from PyQt5.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtWidgets import *
except ImportError:
# needed for py3+qt4
# Ref:
# http://pyqt.sourceforge.net/Docs/PyQt4/incompatible_apis.html
# http://stackoverflow.com/questions/21217399/pyqt4-qtcore-qvariant-object-instead-of-a-string
if sys.version_info.major >= 3:
import sip
sip.setapi(‘QVariant‘ 2)
from PyQt4.QtGui import *
from PyQt4.QtCore import *
import resources
# Add internal libs
from libs.constants import *
from libs.lib import struct newAction newIcon addActions fmtShortcut generateColorByText
from libs.settings import Settings
from libs.shape import Shape DEFAULT_LINE_COLOR DEFAULT_FILL_COLOR
from libs.stringBundle import StringBundle
from libs.canvas import Canvas
from libs.zoomWidget import ZoomWidget
from libs.labelDialog import LabelDialog
from libs.colorDialog import ColorDialog
from libs.labelFile import LabelFile LabelFileError
from libs.toolBar import ToolBar
from libs.pascal_voc_io import PascalVocReader
from libs.pascal_voc_io import xml_EXT
from libs.yolo_io import YoloReader
from libs.yolo_io import TXT_EXT
from libs.ustr import ustr
from libs.version import __version__
from libs.hashableQListWidgetItem import HashableQListWidgetItem
__appname__ = ‘labelImg‘
# Utility functions and classes.
def have_qstring():
‘‘‘p3/qt5 get rid of QString wrapper as py3 has native unicode str type‘‘‘
return not (sys.version_info.major >= 3 or QT_VERSION_STR.startswith(‘5.‘))
def util_qt_strlistclass():
return QStringList if have_qstring() else list
class WindowMixin(object):
def menu(self title actions=None):
menu = self.menuBar().addMenu(title)
if actions:
addActions(menu actions)
return menu
def toolbar(self title actions=None):
toolbar = ToolBar(title)
toolbar.setobjectName(u‘%sToolBar‘ % title)
# toolbar.setOrientation(Qt.Vertical)
toolbar.setToolButtonstyle(Qt.ToolButtonTextUnderIcon)
if actions:
addActions(toolbar actions)
self.addToolBar(Qt.LeftToolBarArea toolbar)
return toolbar
class MainWindow(QMainWindow WindowMixin):
FIT_WINDOW FIT_WIDTH MANUAL_ZOOM = list(range(3))
def __init__(self defaultFilename=None defaultPrefdefClassFile=None defaultSaveDir=None):
super(MainWindow self).__init__()
self.setWindowtitle(__appname__)
# Load setting in the main thread
self.settings = Settings()
self.settings.load()
settings = self.settings
# Load string bundle for i18n
self.stringBundle = StringBundle.getBundle()
getStr = lambda strId: self.stringBundle.getString(strId)
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-12-03 05:21 labelImg-1.8.1\
文件 152 2018-12-03 05:21 labelImg-1.8.1\.gitignore
文件 2461 2018-12-03 05:21 labelImg-1.8.1\.travis.yml
文件 83 2018-12-03 05:21 labelImg-1.8.1\CONTRIBUTING.rst
文件 1339 2018-12-03 05:21 labelImg-1.8.1\HISTORY.rst
文件 1197 2018-12-03 05:21 labelImg-1.8.1\LICENSE
文件 300 2018-12-03 05:21 labelImg-1.8.1\MANIFEST.in
文件 381 2018-12-03 05:21 labelImg-1.8.1\Makefile
文件 8345 2018-12-03 05:21 labelImg-1.8.1\README.rst
文件 0 2018-12-03 05:21 labelImg-1.8.1\__init__.py
目录 0 2018-12-03 05:21 labelImg-1.8.1\build-tools\
文件 108 2018-12-03 05:21 labelImg-1.8.1\build-tools\.gitignore
文件 454 2018-12-03 05:21 labelImg-1.8.1\build-tools\README.md
文件 725 2018-12-03 05:21 labelImg-1.8.1\build-tools\build-for-macos.sh
文件 680 2018-12-03 05:21 labelImg-1.8.1\build-tools\build-for-pypi.sh
文件 656 2018-12-03 05:21 labelImg-1.8.1\build-tools\build-ubuntu-binary.sh
文件 882 2018-12-03 05:21 labelImg-1.8.1\build-tools\build-windows-binary.sh
文件 1566 2018-12-03 05:21 labelImg-1.8.1\build-tools\envsetup.sh
文件 383 2018-12-03 05:21 labelImg-1.8.1\build-tools\run-in-container.sh
目录 0 2018-12-03 05:21 labelImg-1.8.1\data\
文件 145 2018-12-03 05:21 labelImg-1.8.1\data\predefined_classes.txt
目录 0 2018-12-03 05:21 labelImg-1.8.1\demo\
文件 58243 2018-12-03 05:21 labelImg-1.8.1\demo\demo.jpg
文件 91238 2018-12-03 05:21 labelImg-1.8.1\demo\demo3.jpg
文件 2843527 2018-12-03 05:21 labelImg-1.8.1\demo\demo4.png
文件 3240759 2018-12-03 05:21 labelImg-1.8.1\demo\demo5.png
文件 145 2018-12-03 05:21 labelImg-1.8.1\issue_template.md
文件 59021 2018-12-03 05:21 labelImg-1.8.1\labelImg.py
目录 0 2018-12-03 05:21 labelImg-1.8.1\libs\
文件 0 2018-12-03 05:21 labelImg-1.8.1\libs\__init__.py
文件 25982 2018-12-03 05:21 labelImg-1.8.1\libs\canvas.py
............此处省略77个文件信息
相关资源
- 蓝奏云批量上传工具.zip
- Python开发的全栈股票系统.zip
- python+labview+No1.vi
- python源码制作whl文件.rar
- 12306火车班次.zip
- Python-gzipencoding如何压缩HTTP请求发送到
- 毕业设计压缩包.zip(基于Python飞机大
- GitHack-python3.zip
- 蚁狮算法(Ant Lion AlgorithmPython实现和
- python暴力破解蓝奏网盘密码.zip
- Python爬虫相关书籍.zip
- Python-100-Days-master.zip
- XATU_Project.zip
- python小波包文档及论文.zip
- 星巴克数据分析案例及数据集.zip
- 多目标优化算法(二)MOEADMATLAB
- 轻量级PythonWeb框架Mole.zip
- pytorch_pose_proposal_networks-master.zip
- Python黑帽子(黑客与渗透测试编程之
- ENU与WGS84相互转换,基于python与matla
- python坦克大战图片源码.zip
- selenium3离线安装包whl和setup安装包.z
- 基于hadoop的电影推荐系统源码.zip
- 坦克大战.zip
- python数据结构与算法中文版.zip
- python入门笔记强烈推荐.zip
- Python-冲顶大会芝士超人西瓜视频头脑
- MATLAB版本的2Dpca和欧式距离算法
- NeMo_脉冲神经网络工具_spiking neural n
- time_series_forecasting_with_python.zip
评论
共有 条评论