pyts
A python package for time series classification
What it is and what it does
Pyts is a scikit-learn-style library for time series classification that implements state-of-the-art algorithms and provides a suite of preprocessing and transformation tools. It bridges the gap between raw temporal data and machine learning by offering multiple ways to represent time series—from symbolic approximations (Piecewise Aggregate Approximation, Symbolic Aggregate approXimation) to image-based encodings (Recurrence Plot, Gramian Angular Field) to bag-of-words models. The library also includes specialized classifiers like SAXVSM, BOSSVS, Learning Shapelets, and Time Series Forest, as well as time-series-specific metrics such as Dynamic Time Warping variants and the BOSS metric.
The package is built on top of numpy, scipy, scikit-learn, joblib, and numba, inheriting their maturity and performance characteristics. It is designed for developers and researchers who need to classify temporal sequences—whether univariate or multivariate—without building these algorithms from scratch. The modular structure (approximation, bag_of_words, classification, decomposition, image, metrics, preprocessing, transformation) allows you to compose pipelines for custom workflows, and it includes utilities to fetch benchmark datasets from the UEA & UCR Time Series Classification Repository.
Use it for:
- Classify sensor time series (e.g., accelerometer data, ECG signals) using shapelet or bag-of-words approaches.
- Transform raw time series into symbolic or image representations for use with standard classifiers.
- Compute specialized distance metrics (Dynamic Time Warping) between temporal sequences for nearest-neighbor classification.
- Preprocess multivariate time series (e.g., stock prices, weather data) sample-wise before feeding to downstream models.
- Benchmark your own time series classifier against state-of-the-art algorithms using UCR/UEA datasets.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Pyts provides time series classification algorithms and preprocessing tools, including transformations like symbolic approximation, bag-of-words encoding, and image-based representations, along with specialized classifiers and metrics for temporal data.
Yes, if you need time series classification and want a well-structured, scikit-learn-compatible library with multiple algorithms and transformations. The permissive license, low install friction, and established dependencies make it low-risk. However, the last release was in June 2023, so verify that the package's algorithms and dependencies align with your Python and library versions before committing to production use.
Install
pyts on PyPI
pip
pip install pytsuv
uv add pytspoetry
poetry add pytsInstalling pyts
Before you install
Low friction install with a pure-Python wheel. Depends on five established scientific packages (numpy, scipy, scikit-learn, joblib, numba); all are widely available. Last release was in June 2023 and the repository remains active, though the package is marked as aging in maintenance status.
License in practice
Licensed under new BSD (permissive), which allows commercial and private use with minimal restrictions—suitable for most projects without legal friction.
Quickstart
pip install pyts
from pyts.classification import SAXVSM
from pyts.datasets import load_UCR
X_train, X_test, y_train, y_test = load_UCR('GunPoint')
clf = SAXVSM()
clf.fit(X_train, y_train)
clf.score(X_test, y_test)
Requires Python >= 3.8 and working installations of numpy, scipy, scikit-learn, joblib, and numba; Numba in particular may require a C compiler on some systems.
Verify before relying
- Specific performance benchmarks or accuracy comparisons against other time series classification libraries.
- Whether the package is actively maintained beyond the June 2023 release or if recent commits represent only minor updates.
- Real-world scalability limits for very long time series or high-dimensional multivariate data.
Package facts
| License | new BSD (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 5 — numpy, scipy, scikit-learn, joblib, numba |
| Maintenance | aging — 1,153 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 131,673/month — #11,579 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pyts-0.13.0-py3-none-any.whl
Tags
More Software Development packages
Provides backported and experimental type hints…
permissive · top 100 on PyPI
numpyNumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
distlibDistlib provides low-level packaging utilities…
permissive · top 1,000 on PyPI
antropyAntroPy computes entropy and fractal dimension…
permissive · top 15,000 on PyPI
pypotsPyPOTS provides machine learning algorithms for…
permissive · top 15,000 on PyPI
stumpySTUMPY computes the matrix profile for time…
permissive · top 15,000 on PyPI
tslearntslearn provides machine learning algorithms…
permissive · top 15,000 on PyPI
sktimesktime provides a unified interface for time…
permissive · top 5,000 on PyPI
benchpotsBenchPOTS provides standardized preprocessing…
permissive · top 15,000 on PyPI
dtw-pythonComputes Dynamic Time Warping alignments…
copyleft · top 15,000 on PyPI
dartsDarts provides forecasting and anomaly…
permissive · top 15,000 on PyPI
pyriemannpyRiemann provides scikit-learn-compatible…
permissive · top 15,000 on PyPI
rupturesDetects change points in time series and signal…
permissive · top 5,000 on PyPI