Skip to main content

A unified Python toolbox for machine learning with time series

Project description

A unified framework for machine learning with time series

We provide specialized time series algorithms and scikit-learn compatible tools to build, tune and validate time series models for multiple learning problems, including:

  • Forecasting,

  • Time series classification,

  • Time series regression.

For deep learning, see our companion package: sktime-dl.

CI

github appveyor azure codecov

Docs

readthedocs binder tutorial

Community

contributors gitter discord twitter

Code

pypi conda python codestyle zenodo

Installation

The package is available via PyPI using:

pip install sktime

Alternatively, you can install it via conda:

conda install -c conda-forge sktime

The package is actively being developed and some features may not be stable yet.

Development version

To install the development version, please see our advanced installation instructions.

Quickstart

Forecasting

from sktime.datasets import load_airline
from sktime.forecasting.base import ForecastingHorizon
from sktime.forecasting.model_selection import temporal_train_test_split
from sktime.forecasting.theta import ThetaForecaster
from sktime.performance_metrics.forecasting import mean_absolute_percentage_error

y = load_airline()
y_train, y_test = temporal_train_test_split(y)
fh = ForecastingHorizon(y_test.index, is_relative=False)
forecaster = ThetaForecaster(sp=12)  # monthly seasonal periodicity
forecaster.fit(y_train)
y_pred = forecaster.predict(fh)
mean_absolute_percentage_error(y_test, y_pred)
>>> 0.08661467738190656

For more, check out the forecasting tutorial.

Time Series Classification

from sktime.classification.interval_based import TimeSeriesForestClassifier
from sktime.datasets import load_arrow_head
from sklearn.model_selection import train_test_split
from sklearn.metrics import accuracy_score

X, y = load_arrow_head(return_X_y=True)
X_train, X_test, y_train, y_test = train_test_split(X, y)
classifier = TimeSeriesForestClassifier()
classifier.fit(X_train, y_train)
y_pred = classifier.predict(X_test)
accuracy_score(y_test, y_pred)
>>> 0.8679245283018868

For more, check out the time series classification tutorial.

Documentation

How to contribute

We follow the all-contributors specification - and all kinds of contributions are welcome!

If you have a question, chat with us or raise an issue. Your help and feedback is extremely welcome!

Development roadmap

  1. Multivariate/panel forecasting,

  2. Time series clustering,

  3. Time series annotation (segmentation and anomaly detection),

  4. Probabilistic time series modelling, including survival and point processes.

Read our detailed roadmap here.

How to cite sktime

If you use sktime in a scientific publication, we would appreciate citations to the following paper:

Markus Löning, Anthony Bagnall, Sajaysurya Ganesh, Viktor Kazakov, Jason Lines, Franz Király (2019): “sktime: A Unified Interface for Machine Learning with Time Series”

Bibtex entry:

@inproceedings{sktime,
    author = {L{\"{o}}ning, Markus and Bagnall, Anthony and Ganesh, Sajaysurya and Kazakov, Viktor and Lines, Jason and Kir{\'{a}}ly, Franz J},
    booktitle = {Workshop on Systems for ML at NeurIPS 2019},
    title = {{sktime: A Unified Interface for Machine Learning with Time Series}},
    date = {2019},
}

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sktime-0.7.0.tar.gz (9.5 MB view details)

Uploaded Source

Built Distributions

sktime-0.7.0-cp38-cp38-win_amd64.whl (4.5 MB view details)

Uploaded CPython 3.8 Windows x86-64

sktime-0.7.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (5.9 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

sktime-0.7.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (5.8 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.12+ x86-64

sktime-0.7.0-cp38-cp38-macosx_10_15_x86_64.whl (4.5 MB view details)

Uploaded CPython 3.8 macOS 10.15+ x86-64

sktime-0.7.0-cp37-cp37m-win_amd64.whl (4.5 MB view details)

Uploaded CPython 3.7m Windows x86-64

sktime-0.7.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (5.8 MB view details)

Uploaded CPython 3.7m manylinux: glibc 2.17+ x86-64

sktime-0.7.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (5.7 MB view details)

Uploaded CPython 3.7m manylinux: glibc 2.12+ x86-64

sktime-0.7.0-cp37-cp37m-macosx_10_15_x86_64.whl (4.5 MB view details)

Uploaded CPython 3.7m macOS 10.15+ x86-64

sktime-0.7.0-cp36-cp36m-win_amd64.whl (4.5 MB view details)

Uploaded CPython 3.6m Windows x86-64

sktime-0.7.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (5.8 MB view details)

Uploaded CPython 3.6m manylinux: glibc 2.17+ x86-64

sktime-0.7.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (5.7 MB view details)

Uploaded CPython 3.6m manylinux: glibc 2.12+ x86-64

sktime-0.7.0-cp36-cp36m-macosx_10_15_x86_64.whl (4.5 MB view details)

Uploaded CPython 3.6m macOS 10.15+ x86-64

File details

Details for the file sktime-0.7.0.tar.gz.

File metadata

  • Download URL: sktime-0.7.0.tar.gz
  • Upload date:
  • Size: 9.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10

File hashes

Hashes for sktime-0.7.0.tar.gz
Algorithm Hash digest
SHA256 9edc1652b527b98692a9fb92858a6dd720876f842dcc9fa6b0cf22d9bf252b7a
MD5 f3c1eddd79212556e3f6c813cd0d1b6f
BLAKE2b-256 d5ff0d122ee24212ad380ac602fb7d6ea2fa15b5277eca08b5ec1b45c5da2222

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10

File hashes

Hashes for sktime-0.7.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 dce5e7c5b57d8c4adea1a40445f09b49d15aff681e61e105b6956715665c8fbd
MD5 fc96b9ddfc4a411b4e305f75e58c49eb
BLAKE2b-256 e7434e4ce4a55ab9bb9cbed42960b527f45701bd86049680acf5d94c28d5fcfc

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 dfdaa5599ed87e7dcd87a932a0ec73f7e124b04fedfd069d7c9c6501f5262d31
MD5 3598ca16f98e61d89bbc5c301335296f
BLAKE2b-256 eb97dddf6138220cb01c0abf2d3f4e212f016e57ce075fcd828e73e7e86f18ee

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp38-cp38-manylinux_2_12_x86_64.manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 5d38b5d564f9521fad84c5efad215ec27ff3934617024ba3aea523a3c848dd8c
MD5 6e0d089c4e892d60d7a803cddc8fa190
BLAKE2b-256 eda4c8746bf99c7df15f82b801ef5af0407e8be120ab3ec45079562d7d27c1f5

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp38-cp38-macosx_10_15_x86_64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp38-cp38-macosx_10_15_x86_64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.8, macOS 10.15+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10

File hashes

Hashes for sktime-0.7.0-cp38-cp38-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 2c8647f8e16b63ab8bbcc580910726788b4c23c1265d14618c85919e70952540
MD5 a895cf7096678f0e650c1865315446ac
BLAKE2b-256 58de1ade593ec759cd691f919bcb93364bc7b3c95c741727f2a537751b694886

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.7.10

File hashes

Hashes for sktime-0.7.0-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 7836fd27f23698c1a1015032ec555960a9b2a91bab337ae5a90ad10fdc98d3f2
MD5 f65e20f8db122f2839b6116804dc926b
BLAKE2b-256 b9f8818e780ab35eef72d9fb58698bf8575795381d957acdcd51622a7e20e93c

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 d062f1a08596d88294ec5bb9adb5f3d3b86ef71921ab322536638f6146459d58
MD5 054d0347eda50b5dccfea003654202a0
BLAKE2b-256 0f0609c592a35ce03e9ba6f68f593218e1cebdb8ef3f6945e5dc974bf80f4289

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 d5067e3207ccb68b726a21cfd3a67b2dfea097bee3bc7b84a406ff236cc40180
MD5 a0765bacfdd17ce323d322b881613e43
BLAKE2b-256 dd7e8b4929e5c7e9e674e0cdc79b9a858da22d550b5429f5717d6d9da0581dd7

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp37-cp37m-macosx_10_15_x86_64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp37-cp37m-macosx_10_15_x86_64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.7m, macOS 10.15+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.7.10

File hashes

Hashes for sktime-0.7.0-cp37-cp37m-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 ca72ac0ba9d0722d4082b0f90f6a4934ef3d5e6906c670780902a684ad5af9e4
MD5 a23aaf7daf8f1a736321b47fd8380477
BLAKE2b-256 29a2f172b6baf1c48646ca8fbefd017008153a91237eb72f6f2551ed47b3f775

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.6.13

File hashes

Hashes for sktime-0.7.0-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 a5492919302bf88ed0ca6735ac71c602aa882ffd969104daa073ea44b68d30b0
MD5 9649276b89c995fe5daab5d7c1ec850d
BLAKE2b-256 6a07b718064049a2c5f88ff81190e19e48fead4b4d68735b0559f5a272d6aef5

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 93d11ff114c7739043f5f25994f93b577dd9a2cba33c190d31850cbcb3cc073e
MD5 53b19dde1669f8149ce23c843bbd023f
BLAKE2b-256 7d447f5c95216a2164fa27192ad12fcdcea0543322ded8ec9bef47ff42317b59

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl.

File metadata

File hashes

Hashes for sktime-0.7.0-cp36-cp36m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl
Algorithm Hash digest
SHA256 463dceb1fa5a99f097879d81ad145cba5b580ea52f3accd707192ae7e83ef3de
MD5 811f218437da0fcf45a0c1da75f27b6f
BLAKE2b-256 3263d130bf5c5db75e16121654a242c534e7d001e37e551893cba2c0a2baa2c9

See more details on using hashes here.

File details

Details for the file sktime-0.7.0-cp36-cp36m-macosx_10_15_x86_64.whl.

File metadata

  • Download URL: sktime-0.7.0-cp36-cp36m-macosx_10_15_x86_64.whl
  • Upload date:
  • Size: 4.5 MB
  • Tags: CPython 3.6m, macOS 10.15+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.6.13

File hashes

Hashes for sktime-0.7.0-cp36-cp36m-macosx_10_15_x86_64.whl
Algorithm Hash digest
SHA256 2dfd3ee0e80798fdfe50fc0eab0a743ffd5d87c1391ce5229d9dddc0dc28f426
MD5 6cc3d31ae4b02d4f207c7e1aa950130a
BLAKE2b-256 1bb3bd8d5a8039627b247f5c23116812fe713c18aeb935a856ab4feadb584f08

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page