cmcrameri
Making Fabio Crameri's perceptually uniform colourmaps for geosciences available on PyPI and conda-forge
Science Score: 57.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 2 DOI reference(s) in README -
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (13.1%) to scientific vocabulary
Keywords
Keywords from Contributors
Repository
Making Fabio Crameri's perceptually uniform colourmaps for geosciences available on PyPI and conda-forge
Basic Info
- Host: GitHub
- Owner: callumrollo
- License: other
- Language: Python
- Default Branch: main
- Homepage: http://www.fabiocrameri.ch/colourmaps.php
- Size: 1.34 MB
Statistics
- Stars: 178
- Watchers: 5
- Forks: 12
- Open Issues: 4
- Releases: 21
Topics
Metadata Files
README.md
cmcrameri
This is a Python wrapper around Fabio Crameri's perceptually uniform colormaps.
https://www.fabiocrameri.ch/colourmaps/
All credit for creating the colormaps to Fabio. Any errors in the Python implementation of colormaps are my own.
This version is based on Scientific colour maps version 8.0 (2023-06-14).
Install
With pip:
sh
python -m pip install cmcrameri
With conda:
sh
conda install -c conda-forge cmcrameri
Usage example
```python import cmcrameri.cm as cmc import matplotlib.pyplot as plt import numpy as np
x = np.linspace(0, 1, 100)[np.newaxis, :]
plt.imshow(x, aspect='auto', cmap=cmc.batlow) plt.axis('off') plt.show() ```
For a discretized colormap like batlow split into 25 levels, you can use the .resampled method on any of the colormaps:
plt.imshow(x, aspect='auto', cmap=cmc.batlow.resampled(25))
Alternatively, the registered name string can be used.
python
import cmcrameri # required in order to register the colormaps with Matplotlib
...
plt.imshow(x, aspect='auto', cmap='cmc.batlow')
Extra instructions
You can access all the core colormaps from Fabio Crameri's list by cmcrameri.cm.<colormapname>.
You can use tab autocompletion on cmcrameri.cm if your editor supports it.
For a reversed colormap, append _r to the colormap name.
Categorical colormaps have the suffix S.
For an image of all the available colormaps without leaving the comfort of your Python session:
```python from cmcrameri import show_cmaps
show_cmaps() ```

The original colormap text files are shipped as part of the package. Find them on your system with:
```python from cmcrameri.cm import paths
paths ```
License
This work is licensed under an MIT license.
Usage
Owner
- Name: Callum Rollo
- Login: callumrollo
- Kind: user
- Location: Gothenburg, Sweden
- Company: Voice of the Ocean Foundation
- Website: https://callumrollo.github.io/
- Repositories: 86
- Profile: https://github.com/callumrollo
Oceanographer, Pythonista and data science-ish. Breaks things on Fridays
Citation (CITATION.cff)
cff-version: 1.2.0 message: "If you use this software, please cite it as below." authors: - family-names: "Rollo" given-names: "Callum" orcid: "https://orcid.org/0000-0002-5134-7886" title: "cmcrameri" version: 1.9 date-released: 2024-04-22 url: "https://github.com/callumrollo/cmcrameri"
GitHub Events
Total
- Issues event: 2
- Watch event: 39
- Delete event: 5
- Issue comment event: 12
- Push event: 28
- Pull request event: 24
- Fork event: 3
- Create event: 6
Last Year
- Issues event: 2
- Watch event: 39
- Delete event: 5
- Issue comment event: 12
- Push event: 28
- Pull request event: 24
- Fork event: 3
- Create event: 6
Committers
Last synced: 7 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Callum Rollo | c****o@o****m | 63 |
| zmoon | z****2@g****m | 17 |
| Filipe Fernandes | o****f@g****m | 16 |
| pre-commit-ci[bot] | 6****] | 13 |
| dependabot[bot] | 4****] | 6 |
| Stewart Allen | s****n@b****u | 2 |
| Ryuichi Arafune | r****e@g****m | 1 |
| Kian-Meng Ang | k****g@c****g | 1 |
| FloLangenfeld | f****d@g****m | 1 |
| ESiddle | 5****e | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 4 months ago
All Time
- Total issues: 13
- Total pull requests: 59
- Average time to close issues: about 2 months
- Average time to close pull requests: about 1 month
- Total issue authors: 11
- Total pull request authors: 10
- Average comments per issue: 2.46
- Average comments per pull request: 0.8
- Merged pull requests: 46
- Bot issues: 0
- Bot pull requests: 35
Past Year
- Issues: 1
- Pull requests: 24
- Average time to close issues: N/A
- Average time to close pull requests: 5 days
- Issue authors: 1
- Pull request authors: 3
- Average comments per issue: 0.0
- Average comments per pull request: 0.5
- Merged pull requests: 17
- Bot issues: 0
- Bot pull requests: 21
Top Authors
Issue Authors
- ocefpaf (2)
- callumrollo (2)
- MarkWieczorek (1)
- fangfufu (1)
- mohseniaref (1)
- Nkehoe-QUB (1)
- gwerbin (1)
- zak489 (1)
- beskep (1)
- brosaplanella (1)
- QuLogic (1)
Pull Request Authors
- pre-commit-ci[bot] (21)
- callumrollo (15)
- dependabot[bot] (14)
- ocefpaf (3)
- zmoon (1)
- kianmeng (1)
- ESiddle (1)
- arafune (1)
- scrallen (1)
- FloLangenfeld (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 2
-
Total downloads:
- pypi 39,307 last-month
- Total docker downloads: 52
-
Total dependent packages: 21
(may contain duplicates) -
Total dependent repositories: 26
(may contain duplicates) - Total versions: 25
- Total maintainers: 1
pypi.org: cmcrameri
Perceptually uniform colormaps by Fabio Crameri
- Documentation: https://cmcrameri.readthedocs.io/
- License: MIT License Colormaps in cmcrameri/cm/cmaps: Copyright (c) 2020 Fabio Crameri Python scripts and packaging: Copyright (c) 2020 Callum Rollo Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
Latest release: 1.9
published over 1 year ago
Rankings
Maintainers (1)
conda-forge.org: cmcrameri
cmcrameri is a Python wrapper around Fabio Crameri's perceptually uniform colour maps http://www.fabiocrameri.ch/colourmaps.php
- Homepage: https://github.com/callumrollo/cmcrameri
- License: MIT
-
Latest release: 1.4
published about 4 years ago
Rankings
Dependencies
- matplotlib *
- matplotlib *
- numpy *