mpl-image-labeller
Use Matplotlib to label images for classification. Works anywhere Matplotlib does - from the notebook to a standalone gui!
Key features
- Simple interface
- Uses keys instead of mouse
- Only depends on Matplotlib
- Works anywhere - from inside Jupyter to any supported GUI framework
- Easily configurable keymap
- Smart interactions with default Matplotlib keymap
Usage
import matplotlib.pyplot as plt
import numpy as np
from mpl_image_labeller import image_labeller
images = np.random.randn(5, 10, 10)
labeller = image_labeller(
images, classes=["good", "bad", "meh"], label_keymap=["a", "s", "d"]
)
plt.show()
Controls
<-move one image back->move one image forward
To label images use the keys defined in the label_keymap argument - default 0, 1, 2...
Get the labels by accessing the labels property.
Overwriting default keymap
Matplotlib has default keybindings that it applied to all figures via rcparams.keymap that allow for actions such as s to save or q to quit. If you inlcude one of these keys as a shortcut for labelling as a class then that default keymap will be disabled for that figure.
Related Projects
This is not the first project to implement easy image labelling but seems to be the first to do so entirely in Matplotlib. The below projects implement varying degrees of complexity and/or additional features in different frameworks.
Metadata
Release files for mpl-image-labeller 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mpl_image_labeller-0.1.0.tar.gz | 577.3 kB | Without provenance | Details for mpl_image_labeller-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mpl_image_labeller-0.1.0-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for mpl_image_labeller-0.1.0-py2.py3-none-any.whl |
Total release size: 583.6 kB
Release files / mpl_image_labeller-0.1.0.tar.gz
| Download URL | mpl_image_labeller-0.1.0.tar.gz |
|---|---|
| Size | 577.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a035850d74c9a63d56ee970317a6235fa2ad472ecd9daa3891772be963232f8d
|
|
BLAKE2b-256 checksum How to use checksums |
48e9144f6a71fdd474647fdf605db9fd306062a31b265839a5f5f1c3ee370af9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Release files / mpl_image_labeller-0.1.0-py2.py3-none-any.whl
| Download URL | mpl_image_labeller-0.1.0-py2.py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
48eb10453511bef6e45272888ad366a80031d05bd5417b5da7ca942681cd4bc1
|
|
BLAKE2b-256 checksum How to use checksums |
190db25d6e42e67149a9c62d561ec5de9c6e83c60f4c965b4bed26389903df31
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
|
Security for mpl-image-labeller 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.