Skip to main content

Temporian is a Python package for feature engineering of temporal data, focusing on preventing common modeling errors and providing a simple and powerful API, a first-class iterative development experience, and efficient and well-tested implementations of common and not-so-common temporal data preprocessing functions.

Project description

Temporian logo

pypi docs tests formatting publish

Temporian is a Python library for feature engineering 🛠 and data augmentation ⚡ of temporal data 📈 (e.g. time-series, transactions) in machine learning applications 🤖.

Warning Temporian development is in alpha.

Key features

  • Temporian operates natively on multivariate and multi-index time-series and time-sequences data. With Temporian, all temporal data processing is unified.

  • Temporian favors iterative and interactive development in Colab, where users can easily visualize intermediate results 📊 each step of the way.

  • Temporian introduces a novel mechanism to prevent unwanted future leakage and training/serving skew 😰. Temporian programs always return the same result in batch and in streaming mode.

  • Temporian programs can run seamlessly in-process in Python, on large datasets using Apache Beam ☁️, and in streaming for continuous data ingestion.

  • Temporian's core is implemented in C++ and highly optimized 🔥, so large amounts of data can be handled in-process. In some cases, Temporian can provide a speed-up in the order of 1000x compared to other libraries.

Installation

Temporian is available on PyPI. To install it, run:

pip install temporian

Minimal example

Consider the following dataset.

$ head sales.csv
timestamp,store,price,count
2022-01-01 00:00:00+00:00,CA,27.42,61.9
2022-01-01 00:00:00+00:00,TX,98.55,18.02
2022-01-02 00:00:00+00:00,CA,32.74,14.93
2022-01-02 00:00:00+00:00,TX,48.69,83.99
...

We compute the weekly sales per store as follows.

import temporian as tp

input_data = tp.from_csv("sales.csv")

# Define a Temporian program
input_node = input_data.node()
per_store = tp.set_index(input_node, "store")
weekly_sum = tp.moving_sum(per_store["price"], window_length=tp.duration.days(7))

# Execute Temporian program
output_data = weekly_sum.run({input_node: input_data})

# Plot the result
output_data.plot()

Check the Getting Started tutorial to try it out!

Documentation

The documentation 📚 is available at temporian.readthedocs.io. The 3 minutes to Temporian ⏰️ is the best way to start.

Contributing

Contributions to Temporian are welcome! Check out the contributing guide to get started.

Credits

Temporian is developed in collaboration between Google and Tryolabs.

Download files

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

Source Distribution

temporian-0.1.2.tar.gz (165.6 kB view details)

Uploaded Source

Built Distributions

temporian-0.1.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (496.8 kB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

temporian-0.1.2-cp311-cp311-macosx_13_0_arm64.whl (436.9 kB view details)

Uploaded CPython 3.11 macOS 13.0+ ARM64

temporian-0.1.2-cp311-cp311-macosx_12_0_x86_64.whl (450.7 kB view details)

Uploaded CPython 3.11 macOS 12.0+ x86-64

temporian-0.1.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (496.3 kB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

temporian-0.1.2-cp310-cp310-macosx_13_0_arm64.whl (447.8 kB view details)

Uploaded CPython 3.10 macOS 13.0+ ARM64

temporian-0.1.2-cp310-cp310-macosx_12_0_x86_64.whl (449.2 kB view details)

Uploaded CPython 3.10 macOS 12.0+ x86-64

temporian-0.1.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (497.2 kB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

temporian-0.1.2-cp39-cp39-macosx_13_0_arm64.whl (435.7 kB view details)

Uploaded CPython 3.9 macOS 13.0+ ARM64

temporian-0.1.2-cp39-cp39-macosx_12_0_x86_64.whl (449.3 kB view details)

Uploaded CPython 3.9 macOS 12.0+ x86-64

temporian-0.1.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (495.5 kB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

temporian-0.1.2-cp38-cp38-macosx_13_0_arm64.whl (432.4 kB view details)

Uploaded CPython 3.8 macOS 13.0+ ARM64

temporian-0.1.2-cp38-cp38-macosx_12_0_x86_64.whl (449.2 kB view details)

Uploaded CPython 3.8 macOS 12.0+ x86-64

File details

Details for the file temporian-0.1.2.tar.gz.

File metadata

  • Download URL: temporian-0.1.2.tar.gz
  • Upload date:
  • Size: 165.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.10.6 Linux/5.15.0-1041-azure

File hashes

Hashes for temporian-0.1.2.tar.gz
Algorithm Hash digest
SHA256 077cbe3040e04425c13be72ddb36b9ac7b5cb5be2de97dcc720dbde5dac0bbd0
MD5 e26dccecf23d3f5c636c16ebd73c9395
BLAKE2b-256 b2d3c6b5fdcab6748b59c510c3a0dc40534c3e25abe6c76c0e03db75070a9c59

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a18d27f534eed9084d6b508e706602ed187e5c89ec7d98c09448463848ed2b79
MD5 286b6243d5cb59afa090a4d4dad0bf09
BLAKE2b-256 4303317c8214298b90f3683695c53b6ffbde62eeeb1935998628dbc8b31937ae

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp311-cp311-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp311-cp311-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 a69ff2a52cbb48d634c27aaeabb25944cda67d4fd6400a589eadc0bae72e7943
MD5 d11ee4d08dafa0ff7e991c8688b16e10
BLAKE2b-256 a7e0e080414c024936293a2c002fc381d9fc268311eec07dbe7d6cfb146fd660

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp311-cp311-macosx_12_0_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp311-cp311-macosx_12_0_x86_64.whl
Algorithm Hash digest
SHA256 d143e6a5729d65ca88cc9e1777a1cfe27bf7157c32912fb545f8af24b891a9ef
MD5 0d21d532068cb974e6a989cd1189c1b6
BLAKE2b-256 110c1f414ec18798b615c952a465bae5a53deadb572340118ade81f0a794f1e6

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1cef222359c5b79d1fdcdbf9d7c77bae7554c193420542b90a7948c1ad554815
MD5 4066060025a02e0744ce3c397fa70521
BLAKE2b-256 aa720d179885f06d18146c43f0a83e13d4c4fb348b57ab9bed9471a567c41dbc

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp310-cp310-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp310-cp310-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 49373db45fc0f78fba60aa5a4eb24483113c71d3260440d0fe811e9796ec94df
MD5 e3dee32677514d17518751626ed2dc1d
BLAKE2b-256 bd52d1d1c8391780c37c68cb0991a0d0e491eee9b28cc121ef6c00ae1901284d

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp310-cp310-macosx_12_0_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp310-cp310-macosx_12_0_x86_64.whl
Algorithm Hash digest
SHA256 1019846ec1f301cdfb9daa7cc2a91edc9b1294608e0fe0cb32392e85a60c6819
MD5 6394017a4122948655c3c5f977a9fd21
BLAKE2b-256 84f88b6edfd601a0e3b438a52c7082a0741ef7a67da1c4b309061ffe494959f5

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 fc86ba52be2ac20fb1dd27707ab8d53abba8ac23550d91793bddada85c448d34
MD5 27d97feb207c5efb62cb146eb7004d07
BLAKE2b-256 570b1d59ae95f9c9d2b42962e6ab8ea7443b03f10414974cc56e5b20b7e089d9

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp39-cp39-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp39-cp39-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 20e2433eba158063c7cd60b4bc9a71c5ca83af3a406cb53c9bd802b49db95bc4
MD5 703978b46d3008266e6191afc8b0aa6b
BLAKE2b-256 c4eb730fdd1ae1ae7b748834613676ecf3e4898e4f65a2a73a6f07b914f757e2

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp39-cp39-macosx_12_0_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp39-cp39-macosx_12_0_x86_64.whl
Algorithm Hash digest
SHA256 fcfe3aabe3fba4911e64202ca088e1491b8897434d5d824ea3a4542764a7be54
MD5 585971c8bac0069845caa69cf1d8169b
BLAKE2b-256 b1d71e7459846f9df99c8adb04564649de40fd25d1ce01c2cdd125d6de472ca9

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 cac005e345ed104951a869734590e4f78d5dcffc2e837ea216e7ea172df5bb04
MD5 a3290d2ffd812551522d491aab7d58cf
BLAKE2b-256 d108162b90e04943816bde52927111ae923deaa3c3f84af8d686d021cb8b6652

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp38-cp38-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp38-cp38-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 fe53b2601fdfacce4cb8e78bfec16f070e5069a3e5d84850006b2a65cf146019
MD5 5493e8663d101e809a7430d64aeaf3a1
BLAKE2b-256 1704ec98fe9dc48b1c3d691a526a115e3a18b469ce798aae0e66c894b5722a37

See more details on using hashes here.

File details

Details for the file temporian-0.1.2-cp38-cp38-macosx_12_0_x86_64.whl.

File metadata

File hashes

Hashes for temporian-0.1.2-cp38-cp38-macosx_12_0_x86_64.whl
Algorithm Hash digest
SHA256 9e6bf2c95a5e2770405efb9e2e2a10a476ce501e5b5f12ced20fd68080a018e9
MD5 e849d6734396d69f1bd7502db54155cf
BLAKE2b-256 6715bd4e7abafac5c0fd3f15dde4620b6f5b89ad71ea8a5f644dfdaad297b0ee

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