{"id":18561482,"url":"https://github.com/ddz16/preformer","last_synced_at":"2025-07-17T16:04:49.817Z","repository":{"id":169673651,"uuid":"557805221","full_name":"ddz16/Preformer","owner":"ddz16","description":"This repository contains the pytorch code for the 2023 ICASSP paper \"Preformer: Predictive Transformer with Multi-Scale Segment-wise Correlations for Long-Term Time Series Forecasting”","archived":false,"fork":false,"pushed_at":"2023-02-17T05:51:24.000Z","size":535,"stargazers_count":45,"open_issues_count":0,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-10T18:16:37.501Z","etag":null,"topics":["artificial-intelligence","correlation-analysis","deep-learning","deep-neural-networks","predictive-modeling","time-series","time-series-analysis","time-series-forecasting","time-series-prediction","transformer"],"latest_commit_sha":null,"homepage":"https://arxiv.org/abs/2202.11356","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ddz16.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-10-26T10:40:01.000Z","updated_at":"2025-04-02T02:55:16.000Z","dependencies_parsed_at":"2023-06-09T09:30:28.333Z","dependency_job_id":null,"html_url":"https://github.com/ddz16/Preformer","commit_stats":null,"previous_names":["ddz16/preformer"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ddz16/Preformer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddz16%2FPreformer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddz16%2FPreformer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddz16%2FPreformer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddz16%2FPreformer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ddz16","download_url":"https://codeload.github.com/ddz16/Preformer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ddz16%2FPreformer/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265625587,"owners_count":23800625,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["artificial-intelligence","correlation-analysis","deep-learning","deep-neural-networks","predictive-modeling","time-series","time-series-analysis","time-series-forecasting","time-series-prediction","transformer"],"created_at":"2024-11-06T22:07:02.482Z","updated_at":"2025-07-17T16:04:49.812Z","avatar_url":"https://github.com/ddz16.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Preformer\n\nThis repository contains the pytorch code for the 2023 ICASSP paper \"[Preformer: Predictive Transformer with Multi-Scale Segment-wise Correlations for Long-Term Time Series Forecasting](https://arxiv.org/pdf/2202.11356.pdf)”.\n\n# Model\nThe core MSSC module:\n\n![Main Results](figs/mssc.png)\n\n# Acknowledgment\n\nThis repository uses some code from [Autoformer](https://github.com/thuml/Autoformer) and [Informer](https://github.com/zhouhaoyi/Informer2020). Thanks to the authors for their work!\n\n# Get Started\n## Environment\n\nInstall Python 3.6, PyTorch 1.9.0.\n\n## Data\n\nWe use all the datasets provided by [Autoformer](https://github.com/thuml/Autoformer) directly, so you can download them from [Google drive](https://drive.google.com/drive/folders/1ZOYpTUa82_jCcxIdTmyr0LXQfvaM9vIy) provided in [Autoformer](https://github.com/thuml/Autoformer). All the datasets are well pre-processed and can be used easily. After downloading, put these dataset files (such as ETTh1.csv) in the `./data/` folder.\n\n\n# Train\n\n```\npython run.py --is_training 1 --root_path ./data/ --data_path ETTh1.csv --model_id ETTh1_96_48 --model Preformer --data ETTh1 --features M --seq_len 96 --label_len 48 --pred_len 48 --e_layers 2 --d_layers 1 --factor 4 --enc_in 7 --dec_in 7 --c_out 7 --des 'Exp' --itr 1 --n_heads 4 --d_model 32 --d_ff 128\n```\n\n# Test\n\n```\npython run.py --is_training 0 --root_path ./data/ --data_path ETTh1.csv --model_id ETTh1_96_48 --model Preformer --data ETTh1 --features M --seq_len 96 --label_len 48 --pred_len 48 --e_layers 2 --d_layers 1 --factor 4 --enc_in 7 --dec_in 7 --c_out 7 --des 'Exp' --itr 1 --n_heads 4 --d_model 32 --d_ff 128\n```\n\n# Main Results\n\n![Main Results](figs/result.png)\n\n# Citation\n\n```\n@inproceedings{du2022preformer,\n  title={Preformer: Predictive Transformer with Multi-Scale Segment-wise Correlations for Long-Term Time Series Forecasting},\n  author={Du, Dazhao and Su, Bing and Wei, Zhewei},\n  booktitle={ICASSP 2023-2023 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP)},\n  year={2023},\n  organization={IEEE}\n}\n```\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fddz16%2Fpreformer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fddz16%2Fpreformer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fddz16%2Fpreformer/lists"}