Styles for Matplotlib, Seaborn and Plotly.
Quickstart
pip install spektra
# OR
uv add spektra
Then import and apply the styles:
import spektra as sk
import matplotlib.pyplot as plt
# One of ['ember', 'neon', 'ash', 'raiden', 'sakura']
sk.style('ember') # <- This applies styles to matplotlib, seaborn and plotly~
Usage
import spektra as sk
import matplotlib.pyplot as plt
# One of ['ember', 'neon', 'ash', 'raiden', 'sakura']
sk.style('ember')
plt.plot([1, 2, 3], [1, 4, 9])
plt.show()
A few themes are available:
print(sk.get_available_themes())
# ['sakura', 'neon', 'ash', 'raiden', 'ember']
|
|
Raiden |
|
|
Neon |
|
|
Sakura |
|
|
Ember |
| Ash |
Quickview:
print(sk.get_available_themes())
# ['sakura', 'neon', 'ash', 'raiden', 'ember']
print(sk.get_theme())
# ember
print(sk.get_cmap())
# <matplotlib.colors.LinearSegmentedColormap object at 0x10d6ae750>
print(sk.get_palette(n=5))
# ['#FF003C', '#FF00FF', '#00F3FF', '#FFEA00', '#00FF41']
# Config as dict
print(sk.get_config())
#{'name': 'ember', 'colors': {'bg': '#050505', 'accent': '#FF003C', 'secondary': '#9D0025', 'text': '#FF003C', 'grid': '#1A0006'},
# 'palette': ['#FF003C', '#FF00FF', '#00F3FF', '#FFEA00', '#00FF41', '#FF9500'], 'settings': {'alpha': 0.4, 'op': 0.4, 'font':
# 'monospace'}, 'matplotlib': {'figure.facecolor': '#050505', 'axes.facecolor': '#050505', 'axes.edgecolor': '#444444', 'axes.
# labelcolor': '#FF003C', 'axes.titlesize': 10, 'axes.titleweight': 'bold', 'grid.color': '#1A0006', 'grid.alpha': 0.3, 'grid.
# linestyle': ':', 'xtick.color': '#FF003C', 'ytick.color': '#FF003C', 'text.color': '#FF003C', 'font.family': 'monospace', 'axes.
# spines.top': False, 'axes.spines.right': False, 'lines.color': '#FF003C', 'lines.marker': 's', 'lines.markersize': 4, 'patch.
# facecolor': '#FF003C', 'patch.edgecolor': '#050505', 'scatter.marker': 's', 'scatter.edgecolors': '#FF003C'}, 'plotly':
# {'paper_bgcolor': '#050505', 'plot_bgcolor': '#050505', 'font_color': '#FF003C', 'font_family': 'Roboto Mono, Cascadia Code,
# Source Code Pro, Courier New, monospace', 'grid_color': '#1A0006', 'axis_line_color': '#444444'}, 'cmap': <matplotlib.colors.
# LinearSegmentedColormap object at 0x1083e7d40>}
Theme Files
All theme files are stored under their respective spektra/themes/{THEME_NAME}.json file.
They're stored as JSON for ease of reusability between Maplotlib/Seaborn and Plotly.
spektra scans the directory, so adding a .json file to it will register a new theme.
License
Metadata
Release files for spektra 0.1.3
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 |
|---|---|---|---|---|
| spektra-0.1.3.tar.gz | 12.0 kB | Without provenance | Details for spektra-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| spektra-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for spektra-0.1.3-py3-none-any.whl |
Total release size: 25.6 kB
Release files / spektra-0.1.3.tar.gz
| Download URL | spektra-0.1.3.tar.gz |
|---|---|
| Size | 12.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0dd652ccc351209f7920d02d97a8404874643999f199860b2a5f9a8e18cf4c9
|
|
BLAKE2b-256 checksum How to use checksums |
0748c99f2183d9d60b31f1552de229d5e8357f3b46beb262c2c4856595c6af99
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.0
|
Release files / spektra-0.1.3-py3-none-any.whl
| Download URL | spektra-0.1.3-py3-none-any.whl |
|---|---|
| Size | 13.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f142426ca04b697b49b491071b624001fc995702b4a26b3123980cafbe012f33
|
|
BLAKE2b-256 checksum How to use checksums |
5bb00b43023d94418548791905c06798a4ee2d98a203a7b9420127ef57fc36fc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.0
|
Security for spektra 0.1.3
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.