# yuqinie98/PatchTST

An offical implementation of PatchTST: "A Time Series is Worth 64 Words: Long-term Forecasting with Transformers." (ICLR 2023) https://arxiv.org/abs/2211.14730

Repository: https://github.com/yuqinie98/PatchTST
Canonical: https://ross.abutalabs.com/products/patchtst
Language: Python
License: Apache-2.0
License Family: permissive
Last push: 2024-08-12T13:12:51+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 1408, "days_push": 751, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2685, forks 450 (observed 2026-08-28T04:07:10.234451+00:00)

## What it is
Official PyTorch implementation of PatchTST, an ICLR 2023 Transformer model for long-term time series forecasting based on patching and channel-independence. It includes code for both supervised and self-supervised (pre-training/transfer) learning experiments.

## Use cases
- forecast long-term time series with transformers
- reproduce PatchTST ICLR 2023 paper results
- train a self-supervised pretrained model for time series and transfer it to downstream tasks
- benchmark forecasting models like DLinear against PatchTST on datasets like ETT and weather
- experiment with patching and channel-independence designs for multivariate forecasting

## When to choose
- you need state-of-the-art long-term time series forecasting in Python
- you want a research reference implementation of PatchTST
- you want to pretrain on time series and fine-tune for downstream forecasting

## When to avoid
- you need a production-ready forecasting library with maintained APIs - use GluonTS, NeuralForecast, or tsai which integrate PatchTST
- you need short-horizon or non-neural forecasting methods
- you need real-time streaming forecasting

## Facets
- artifact type: library
- maturity: stable
- function: machine-learning, deep-learning
- domain: time-series, machine-learning, deep-learning, data-science
- platform: python
- tags: time-series-forecasting, transformer, patchtst, research-code, self-supervised-learning, long-term-forecasting

## Member repositories
- yuqinie98/PatchTST (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:10.234451+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:17:50.959219+00:00, confidence not recorded.
  - readme: https://github.com/yuqinie98/PatchTST (fetched 2026-08-28T04:07:10.234451+00:00, sha 4f99bb730cb6)
- Data as of 2026-08-30T08:39:29.467469+00:00.
