A lightweight JAX-based library offering a collection of distance and similarity measures for data analysis. Designed for scalability and accelerator support, it includes high-performance, parallelizable implementations of a wide range of commonly used metrics.
pip install -e .
This library is still in development and more metrics will be added over time. The following metrics are currently implemented.
- Minkowski Distance
- Euclidean Distance
- Cosine Distance
- Mahalanobis Distance
- Dynamic Time Warping
- Discrete Frechet Distance
- Sinkhorn Distance
- Relative Entropy (Kullback-Leibler Divergence)
- Frechet Inception Distance
- Maximum Mean Discrepancy
- Wassersteim Distance
To test, there are two examples: Either compare batches of particles
python examples/example_particle_data.py
or batches of time series data
python examples/example_time_series_data.py
If you use this libarary in your work, please consider citing it as follows:
@software{metrix2024github,
author = {Pompetzki, Kay and Gruner, Theo and Al-Hafez, Firas, and Peters, Jan},
title = {MetriX: A JAX-Based Collection of Similarity and Statistical Measures for Accelerated Data Analysis.},
url = {https://github.com/pompetzki/metriX},
year = {2024},
}