diff --git a/README.rst b/README.rst index f422bfa7..be122ac5 100644 --- a/README.rst +++ b/README.rst @@ -84,6 +84,22 @@ Python 3 + Qt5 (Works on macOS High Sierra) python labelImg.py python labelImg.py [IMAGE_PATH] [PRE-DEFINED CLASS FILE] +*NEW* Python 3 Virtualenv + Binary +This avoids a lot of the QT / Python version issues, +and gives you a nice .app file with a new SVG Icon +in your /Applications folder. + +.. code:: + + brew install python3 + pip install pipenv + pipenv --three + pipenv shell + pip install pyqt5 lxml + make qt5py3 + rm -rf build dist + python setup.py py2app + cp -rf dist/labelImg.app /Applications Windows ^^^^^^^ @@ -239,3 +255,5 @@ Related download image, create a label text for machine learning, etc 2. `Use Docker to run labelImg `__ 3. `Generating the PASCAL VOC TFRecord files `__ +4. `App Icon based on Icon by Nick Roach (GPL)` __ + diff --git a/icons/app.icns b/icons/app.icns new file mode 100644 index 00000000..3cfa8ed3 Binary files /dev/null and b/icons/app.icns differ diff --git a/icons/app.png b/icons/app.png new file mode 100644 index 00000000..94345add Binary files /dev/null and b/icons/app.png differ diff --git a/icons/app.svg b/icons/app.svg new file mode 100644 index 00000000..bcb03e3b --- /dev/null +++ b/icons/app.svg @@ -0,0 +1,19 @@ + + + + + + + + background + + + + Layer 1 + + + + VOC + + + \ No newline at end of file diff --git a/resources.qrc b/resources.qrc index 805fe421..0a8c83c0 100644 --- a/resources.qrc +++ b/resources.qrc @@ -2,7 +2,7 @@ icons/help.png -icons/expert2.png +icons/app.png icons/expert2.png icons/done.png icons/file.png diff --git a/setup.py b/setup.py index c4c6823a..424325a2 100644 --- a/setup.py +++ b/setup.py @@ -17,7 +17,14 @@ requirements = [ required_packages = find_packages() required_packages.append('labelImg') +APP = ['labelImg.py'] +OPTIONS = { + 'argv_emulation': True, + 'iconfile': 'icons/app.icns' +} + setup( + app=APP, name='labelImg', version=__version__, description="LabelImg is a graphical image annotation tool and label object bounding boxes in images", @@ -51,5 +58,7 @@ setup( 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', ], - package_data={'data/predefined_classes.txt': ['data/predefined_classes.txt']} + package_data={'data/predefined_classes.txt': ['data/predefined_classes.txt']}, + options={'py2app': OPTIONS}, + setup_requires=['py2app'] )