Paletas de cores colorblind-safe derivadas de plumagens de aves (categórica + colormaps).
Project description
plumaria
Paletas de cores colorblind-safe derivadas de plumagens de aves: uma paleta categórica de 8 cores e três colormaps contínuos (um sequencial, dois divergentes). Núcleo enxuto (só numpy para acessar cores); matplotlib é opcional, só para registrar colormaps e ajustar padrões de plotagem.
As cores foram amostradas de fotografias de plumagens (fonte: Vinícius Kohn, @viniciuskohnpassaros) e ajustadas para permanecerem distinguíveis sob os três tipos de daltonismo (deuteranopia, protanopia, tritanopia). A paleta categórica foi selecionada maximizando a distância perceptual mínima (CIE Lab), simulando o daltonismo pelas matrizes de Machado et al. (2009); o ΔE mínimo (~15) fica na mesma faixa da paleta Okabe-Ito.
Extraído de
neurotools.vizpara um pacote autônomo.neurotoolsconsome o plumaria como submódulo git.
Instalação
pip install -e '.[viz]' # com matplotlib (colormaps + set_defaults)
pip install -e . # só o acesso às cores (numpy)
Uso
import plumaria
plumaria.categorical(3) # ['#0A458A', '#F76F24', '#126C7D']
plumaria.register() # registra os colormaps "aves_*" no matplotlib
plumaria.set_defaults() # ciclo de cores categórico + cmap padrão
import matplotlib.pyplot as plt
plt.get_cmap("aves_saiazul") # sequencial
plt.get_cmap("aves_gaturamo") # divergente
plumaria.palettes também está disponível (from plumaria import palettes).
Colormaps
| Nome | Tipo |
|---|---|
aves_saiazul |
sequencial (mono-matiz) |
aves_gaturamo |
divergente |
aves_beijaflor |
divergente |
Cada colormap tem a variante invertida _r (ex.: aves_saiazul_r).
API
categorical, colormap, register, set_defaults, hex_to_rgb e os dados
CATEGORICAL, CATEGORICAL_NAMES, SEQUENTIAL, DIVERGING, COLORMAPS.
Testes
pytest
Licença
MIT.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file plumaria-0.1.0.tar.gz.
File metadata
- Download URL: plumaria-0.1.0.tar.gz
- Upload date:
- Size: 13.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
80ef81c21d81912395d4e36c4fb0a67f05fca240d31abe0bec238bc9b4d3faad
|
|
| MD5 |
bbccdc7eb52ce5e4b00f0db23a1a242f
|
|
| BLAKE2b-256 |
b2735b2ba1a3205a100627a6dac647c0ad97934a83f79609dc6a3ba22b97ec1e
|
Provenance
The following attestation bundles were made for plumaria-0.1.0.tar.gz:
Publisher:
release.yml on napvasconcelos/plumaria
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
plumaria-0.1.0.tar.gz -
Subject digest:
80ef81c21d81912395d4e36c4fb0a67f05fca240d31abe0bec238bc9b4d3faad - Sigstore transparency entry: 2086231794
- Sigstore integration time:
-
Permalink:
napvasconcelos/plumaria@71709218eaa8cb9fb53cdae4b7e77548f78e76c2 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/napvasconcelos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@71709218eaa8cb9fb53cdae4b7e77548f78e76c2 -
Trigger Event:
release
-
Statement type:
File details
Details for the file plumaria-0.1.0-py3-none-any.whl.
File metadata
- Download URL: plumaria-0.1.0-py3-none-any.whl
- Upload date:
- Size: 12.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
77ff75d8df945568646be592c330d8a655b0db1b00d58db41b0600630289a938
|
|
| MD5 |
7fe8c6d6ffa472b8d1dcbb64bd4250b7
|
|
| BLAKE2b-256 |
84cc1a9385445387e3c7eccecd65ec04cbcec75c5c3ee811a48363c446772553
|
Provenance
The following attestation bundles were made for plumaria-0.1.0-py3-none-any.whl:
Publisher:
release.yml on napvasconcelos/plumaria
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
plumaria-0.1.0-py3-none-any.whl -
Subject digest:
77ff75d8df945568646be592c330d8a655b0db1b00d58db41b0600630289a938 - Sigstore transparency entry: 2086231953
- Sigstore integration time:
-
Permalink:
napvasconcelos/plumaria@71709218eaa8cb9fb53cdae4b7e77548f78e76c2 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/napvasconcelos
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@71709218eaa8cb9fb53cdae4b7e77548f78e76c2 -
Trigger Event:
release
-
Statement type: