Skip to main content

Composable timeseries feature extraction for paired signals.

Project description

duots

duots is a lightweight Python package for calculating features from paired time series signals — like those collected from symmetrical body parts (e.g., left and right wrists). It provides a composable, lazy, and efficient pipeline to build complex signal analysis routines.


Features

  • Composable feature pipelines using functional programming
  • Modular primitives: segmentation, transformation, timeseries ops, value aggregation
  • Efficient via functools.lru_cache (minimizes redundant computation)
  • Minimal dependencies: uses only scipy (and optionally sampen-gpu)
  • Designed for paired signals (e.g., (left, right) or (x, y))
  • Easy to extend, debug, and test

Design Philosophy

  • Composable: Build powerful feature extractors from simple, small functions.
  • Efficient: Shared operations are cached; performance scales with reuse.
  • Minimal: Only scipy is used for FFT, skew, and kurtosis; avoids heavy dependencies.

📦 Installation

From PyPI -- duots

pip install duots

From Source

git clone https://github.com/4d30/duots.git
cd duots
pip install .

Example Usage

from duots import generate, compose

# Create a pair of signals, e.g., (left, right)
# They must be tuples, of the same length, without NaNs
sig_a = tuple(range(1, 100))
sig_b = tuple(range(1, 100))
signal_pair = (sig_a, sig_b,)

# Calculate values for each process
for proc in generate.processes():
    names, funcs = zip(*proc)
    name = compose.descriptors(names)
    composed_function = compose.functions(funcs)
    value = composed_function(signal_pair)
    print(f"{name}: {value}")

Project details


Download files

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

Source Distribution

duots-0.1.2.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

duots-0.1.2-py3-none-any.whl (9.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: duots-0.1.2.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.0

File hashes

Hashes for duots-0.1.2.tar.gz
Algorithm Hash digest
SHA256 fd9ada76d53eda6f4f776614a752fe22a1ab6dc8c31d8016be080a68e8b39f3e
MD5 038dceed73fa40c2c9c0701c741c261b
BLAKE2b-256 bda5c24ed7da07a87ae4c77178e0ce1a94e56652207103eb424604306abd3608

See more details on using hashes here.

File details

Details for the file duots-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: duots-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 9.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.0

File hashes

Hashes for duots-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a0ce1f692465cb5d40e5c798889c6e35b454dcdcc2c3a684ee6864aea30c895d
MD5 1c5307d767989d8a8558041c74c467eb
BLAKE2b-256 e44d458fffcafec44ecb23b77b4b3ba5620bc4062edc5b7b20d7e266f7b1118a

See more details on using hashes here.

Supported by

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