Home

Awesome

<h1 align='center'> quaxed </h1> <h3 align="center">Pre-<code>Quaxify</code>'ed <code>JAX</code></h3> <p align="center"> <a href="https://pypi.org/project/quaxed/"> <img alt="PyPI: quaxed" src="https://img.shields.io/pypi/v/quaxed?style=flat" /> </a> <a href="https://pypi.org/project/quaxed/"> <img alt="PyPI versions: quaxed" src="https://img.shields.io/pypi/pyversions/quaxed" /> </a> <a href="https://quaxed.readthedocs.io/en/"> <img alt="ReadTheDocs" src="https://img.shields.io/badge/read_docs-here-orange" /> </a> <a href="https://pypi.org/project/quaxed/"> <img alt="quaxed license" src="https://img.shields.io/github/license/GalacticDynamics/quaxed" /> </a> </p> <p align="center"> <a href="https://github.com/GalacticDynamics/quaxed/actions/workflows/ci.yml"> <img alt="CI status" src="https://github.com/GalacticDynamics/quaxed/actions/workflows/ci.yml/badge.svg?branch=main" /> </a> <a href="https://quaxed.readthedocs.io/en/"> <img alt="ReadTheDocs" src="https://readthedocs.org/projects/quaxed/badge/?version=latest" /> </a> <a href="https://codecov.io/gh/GalacticDynamics/quaxed"> <img alt="codecov" src="https://codecov.io/gh/GalacticDynamics/quaxed/graph/badge.svg" /> </a> <a href="https://scientific-python.org/specs/spec-0000/"> <img alt="ruff" src="https://img.shields.io/badge/SPEC-0-green?labelColor=%23004811&color=%235CA038" /> </a> <a href="https://docs.astral.sh/ruff/"> <img alt="ruff" src="https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v2.json" /> </a> <a href="https://pre-commit.com"> <img alt="pre-commit" src="https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit" /> </a> </p>

Quaxed wraps jax libraries (using quax) to enable using those libraries with custom array-ish objects, not only jax arrays.

Installation

PyPI version PyPI platforms

<!-- [![Conda-Forge][conda-badge]][conda-link] -->
pip install quaxed

Documentation

Read The Docs

Quick Start

To understand how quax works it's magic, see quax.quaxify and the tutorials.

To use this library, it's as simple as:

# Import pre-quaxified library
>>> import quaxed.numpy as jnp  # this is quaxify(jax.numpy)

# As an example, let's import an array-ish object
>>> from unxt import Quantity
>>> x = Quantity(2, "km")
>>> jnp.square(w)
Quantity['area'](Array(4, dtype=int64, weak_type=True), unit='km2')

Development

Actions Status Documentation Status codecov SPEC 0 — Minimum Supported Dependencies pre-commit ruff

We welcome contributions!

Citation

DOI

If you found this library to be useful and want to support the development and maintenance of lower-level utility libraries for the scientific community, please consider citing this work.

<!-- prettier-ignore-start --> <!-- prettier-ignore-end -->