Kernel Density Estimation accelerated with Fast Fourier Transform and JAX (JIT+GPU support+AD).
Features
-
FFT-accelerated KDE (inspired by KernelDensity.jl):
fft_kde1d: 1D KDE with FFT convolution (requires regular grid)fft_kde2d: 2D KDE with FFT convolution (requires regular grid)fft_kde3d: 3D KDE with FFT convolution (requires regular grid)
The KDE can be evaluated on non-regular grid by interpolation, such as
jax.numpy.interporjax.scipy.interpolate.RegularGridInterpolator -
Binned-accelerated implementation:
binned_kde1d: 1D KDE with data binning
-
Bandwidth estimators:
- Scott's rule (
scott_bw1d/2d/3d) - Silverman's rule (
silverman_bw1d/2d/3d)
- Scott's rule (
Installation
-
Install JAX following the instructions at: https://github.com/jax-ml/jax, e.g
pip install "jax[cpu]" # For CPU-only version
or
pip install "jax[cuda12]" # For GPU support (CUDA)
-
Install with
pippip install KDExpress
-
Alternative way:
-
Clone the
KDExpressrepogit clone https://github.com/mtagliazucchi/KDExpress
-
Install the code
a. Editable install:
cd KDExpress pip install -e .
b. Or use it ad-hoc:
import sys; sys.path.append("/path/to/KDExpress") from KDExpress import fft_kde1d
-
Usage and benchmarks
See the examples folder.
License
MIT © Matteo Tagliazucchi
Metadata
Release files for KDExpress 0.2.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 |
|---|---|---|---|---|
| kdexpress-0.2.3.tar.gz | 10.9 kB | With provenance | Details for kdexpress-0.2.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| kdexpress-0.2.3-py3-none-any.whl | Python 3 | none | any | Details for kdexpress-0.2.3-py3-none-any.whl |
Total release size: 21.6 kB
Release files / kdexpress-0.2.3.tar.gz
| Download URL | kdexpress-0.2.3.tar.gz |
|---|---|
| Size | 10.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
01a5259b345a03a849c39d6dccfc753ac18516066ac7a57e2736ca493c10ae7b
|
|
BLAKE2b-256 checksum How to use checksums |
64d89013b087cd99501261e1b4b8d404b479bbeb4810b42690177f9a3f98b85d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.
Transparency logRelease files / kdexpress-0.2.3-py3-none-any.whl
| Download URL | kdexpress-0.2.3-py3-none-any.whl |
|---|---|
| Size | 10.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f7378dc3a432144dc62be621e6a98d1595607ef78cd068054e607d5e5048e0b8
|
|
BLAKE2b-256 checksum How to use checksums |
88e6729deb40c6c2bbc32c46f690c4da5be6e01c629eb6bfdb01466ff352a17d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.
Transparency logSecurity for KDExpress 0.2.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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for kdexpress-0.2.3.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.
Transparency logA 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.