Metadata-Version: 2.4
Name: SeisCM
Version: 0.1.3
Summary: Seismic Colormap Generator
Author-email: Lijun Zhu <gatechzhu@gmail.com>
License-Expression: MIT
Project-URL: Homepage, https://github.com/lijunzh/SeisCM
Project-URL: Documentation, https://github.com/lijunzh/SeisCM#readme
Project-URL: Issues, https://github.com/lijunzh/SeisCM/issues
Project-URL: Changelog, https://github.com/lijunzh/SeisCM/blob/master/CHANGELOG.md
Keywords: seismic,geophysics,colormap,matplotlib,visualization
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Visualization
Classifier: Typing :: Typed
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.24
Requires-Dist: matplotlib>=3.7
Dynamic: license-file

# Seismic Colormaps (SeisCM)

[![PyPI version](https://img.shields.io/pypi/v/SeisCM)](https://pypi.org/project/SeisCM/)
![License](https://img.shields.io/pypi/l/SeisCM)
![Python versions](https://img.shields.io/pypi/pyversions/SeisCM)
[![Code style: ruff](https://img.shields.io/badge/code%20style-ruff-000000.svg)](https://github.com/astral-sh/ruff)
[![CI/CD](https://github.com/lijunzh/seiscm/actions/workflows/cicd.yml/badge.svg)](https://github.com/lijunzh/seiscm/actions/workflows/cicd.yml)

## Introduction

Geophysicists can never agree on a standard colormap — so here's a package
with the most common ones, ready to import. SeisCM provides
[matplotlib](https://matplotlib.org/)-compatible colormaps designed
specifically for seismic and geophysical data visualization.

Pull requests for new colormaps are welcome!

## Available Colormaps

| Name | Description |
|------|-------------|
| `bwr` | Blue-White-Red with configurable mid-point transparency |
| `seismic` | Classic seismic amplitude display |
| `phase` | Phase attribute visualisation |
| `frequency` | Frequency attribute visualisation |

![Colormap Demo](/fig/colormaps.png?raw=true "Colormaps")

## Installation

### From PyPI

```bash
pip install seiscm
```

### From source (development)

```bash
git clone https://github.com/lijunzh/seiscm.git
cd seiscm
uv sync --dev
```

## Quick Start

```python
from seiscm import bwr
import matplotlib.pyplot as plt
import numpy as np

data = np.random.default_rng(42).standard_normal((100, 100))
plt.imshow(data, cmap=bwr())
plt.colorbar()
plt.show()
```

## Dependencies

- [NumPy](https://numpy.org/)
- [Matplotlib](https://matplotlib.org/)

## Development

```bash
uv run ruff check src tests   # lint
uv run ruff format src tests  # format
uv run mypy                   # type-check
uv run pytest --cov           # test with coverage
uv run pre-commit install     # set up git hooks
```

## Contributing

See [CONTRIBUTING.md](CONTRIBUTING.md) and the
[Code of Conduct](CODE_OF_CONDUCT.md). Security issues: see
[SECURITY.md](SECURITY.md).

## Citing

A [`CITATION.cff`](CITATION.cff) file is provided; GitHub's
"Cite this repository" button uses it.

## License

[MIT](LICENSE)

## Contact

For issues, please open a
[GitHub issue](https://github.com/lijunzh/seiscm/issues) or contact
*gatechzhu@gmail.com*.
