Multimodal extension for time series foundation models
Project description
TSFMx
TSFMx (TSFMx Standardizes Fusion of Multimodal exogenous features) is a framework for extending TSFMs (including TimesFM and Chronos) with multimodal inputs such as text.
Installation
pip install tsfmx[all]
Quick Start
1. Setup
Clone the Time-MMD dataset:
./scripts/clone_time_mmd.sh
Split the dataset into train / val / test:
PYTHONPATH=. uv run python scripts/split_time_mmd_datasets.py \
--train-ratio 0.6 \
--val-ratio 0.2
2. Pre-compute Text Embeddings
TimesFM:
PYTHONPATH=. uv run python scripts/cache_time_mmd_datasets.py \
--model-config examples/time_mmd/configs/models/timesfm.yml \
--text-encoder-type english
PYTHONPATH=. uv run python scripts/cache_time_mmd_datasets.py \
--model-config examples/time_mmd/configs/models/timesfm.yml \
--text-encoder-type english --augment
Chronos:
PYTHONPATH=. uv run python scripts/cache_time_mmd_datasets.py \
--model-config examples/time_mmd/configs/models/chronos.yml \
--text-encoder-type english
PYTHONPATH=. uv run python scripts/cache_time_mmd_datasets.py \
--model-config examples/time_mmd/configs/models/chronos.yml \
--text-encoder-type english --augment
3. Hyperparameter Tuning
Run a W&B Sweeps search for the multimodal model:
TimesFM:
PYTHONPATH=. uv run python scripts/tune_time_mmd_sweep.py \
--model-config examples/time_mmd/configs/models/timesfm.yml \
--sweep-config examples/time_mmd/configs/sweeps/multimodal_1layer.yml
Chronos:
PYTHONPATH=. uv run python scripts/tune_time_mmd_sweep.py \
--model-config examples/time_mmd/configs/models/chronos.yml \
--sweep-config examples/time_mmd/configs/sweeps/multimodal_1layer.yml
To compare against a fine-tuned baseline:
TimesFM:
PYTHONPATH=. uv run python scripts/tune_baseline_sweep.py \
--model-config examples/time_mmd/configs/models/timesfm.yml \
--sweep-config examples/time_mmd/configs/sweeps/baseline.yml
Chronos:
PYTHONPATH=. uv run python scripts/tune_baseline_sweep.py \
--model-config examples/time_mmd/configs/models/chronos.yml \
--sweep-config examples/time_mmd/configs/sweeps/baseline.yml
Acknowledgments
We thank the Time-MMD team for providing the multimodal time series dataset used in our examples and experiments.
License
MIT
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tsfmx-1.0.1.tar.gz.
File metadata
- Download URL: tsfmx-1.0.1.tar.gz
- Upload date:
- Size: 19.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af276875267c02645af966b9ee55c36a4f7f9e66c878c94fa00e69d5c6a81555
|
|
| MD5 |
d1c9280f2cb339575d288cf63e55cf87
|
|
| BLAKE2b-256 |
d35247c9e04c967b91e2713bd13fb5601ece7a55c46b624d4ef9e628a8ae6d8e
|
Provenance
The following attestation bundles were made for tsfmx-1.0.1.tar.gz:
Publisher:
publish-to-pypi.yml on himura467/tsfmx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tsfmx-1.0.1.tar.gz -
Subject digest:
af276875267c02645af966b9ee55c36a4f7f9e66c878c94fa00e69d5c6a81555 - Sigstore transparency entry: 1185122364
- Sigstore integration time:
-
Permalink:
himura467/tsfmx@e14e235f571138c3dfd7f1e703b8f144806b1500 -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/himura467
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@e14e235f571138c3dfd7f1e703b8f144806b1500 -
Trigger Event:
release
-
Statement type:
File details
Details for the file tsfmx-1.0.1-py3-none-any.whl.
File metadata
- Download URL: tsfmx-1.0.1-py3-none-any.whl
- Upload date:
- Size: 26.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a431f57b0cac2cc88896cf72218f4e488b6d62255c037c910c25e5bf3e7f7163
|
|
| MD5 |
5b04bca97dff2503f095e885849db8dd
|
|
| BLAKE2b-256 |
45c044d3119b490f041375658cfa2e7d249c18215d1db116fdab7de08c9ab9c1
|
Provenance
The following attestation bundles were made for tsfmx-1.0.1-py3-none-any.whl:
Publisher:
publish-to-pypi.yml on himura467/tsfmx
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tsfmx-1.0.1-py3-none-any.whl -
Subject digest:
a431f57b0cac2cc88896cf72218f4e488b6d62255c037c910c25e5bf3e7f7163 - Sigstore transparency entry: 1185122380
- Sigstore integration time:
-
Permalink:
himura467/tsfmx@e14e235f571138c3dfd7f1e703b8f144806b1500 -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/himura467
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@e14e235f571138c3dfd7f1e703b8f144806b1500 -
Trigger Event:
release
-
Statement type: