{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/peri-midformer-periodic-pyramid-transformer","title":"Peri-midFormer: Periodic Pyramid Transformer for Time Series Analysis","arxiv_id":"2411.04554","date":"2024-11-07","proceeding":null,"authors":["Qiang Wu","Gechang Yao","Zhixi Feng","Shuyuan Yang"],"abstract":"Time series analysis finds wide applications in fields such as weather forecasting, anomaly detection, and behavior recognition. Previous methods attempted to model temporal variations directly using 1D time series. However, this has been quite challenging due to the discrete nature of data points in time series and the complexity of periodic variation. In terms of periodicity, taking weather and traffic data as an example, there are multi-periodic variations such as yearly, monthly, weekly, and daily, etc. In order to break through the limitations of the previous methods, we decouple the implied complex periodic variations into inclusion and overlap relationships among different level periodic components based on the observation of the multi-periodicity therein and its inclusion relationships. This explicitly represents the naturally occurring pyramid-like properties in time series, where the top level is the original time series and lower levels consist of periodic components with gradually shorter periods, which we call the periodic pyramid. To further extract complex temporal variations, we introduce self-attention mechanism into the periodic pyramid, capturing complex periodic relationships by computing attention between periodic components based on their inclusion, overlap, and adjacency relationships. Our proposed Peri-midFormer demonstrates outstanding performance in five mainstream time series analysis tasks, including short- and long-term forecasting, imputation, classification, and anomaly detection.","url_abs":"https://arxiv.org/abs/2411.04554v1","url_pdf":"https://arxiv.org/pdf/2411.04554v1.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"peri-midformer-periodic-pyramid-transformer","repo_url":"https://github.com/WuQiangXDU/Peri-midFormer","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"anomaly-detection","task_name":"Anomaly Detection"},{"task_slug":"classification-1","task_name":"Classification"},{"task_slug":"imputation","task_name":"Imputation"},{"task_slug":"time-series-1","task_name":"Time Series"},{"task_slug":"time-series","task_name":"Time Series Analysis"},{"task_slug":"time-series-forecasting","task_name":"Time Series Forecasting"},{"task_slug":"weather-forecasting","task_name":"Weather Forecasting"}],"methods":[{"method_slug":"attention","method_name":"Attention"},{"method_slug":"softmax","method_name":"Softmax"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2411.04554","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2411.04554"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"deterministic:regex_extraction","url":"https://github.com/WuQiangXDU/Peri-midFormer","reach":null}],"summary":{"ran":9,"ran_fixture":1,"unverified":4},"by_repo_kind":{"official":{"samples":14,"ran":10,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":14,"samples":[{"code_sha256_prefix":"4ea975de7e597438","entry":"AttentionLayer","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"4ea975de7e597438"}},{"code_sha256_prefix":"a90351833106365d","entry":"FullAttention","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"a90351833106365d"}},{"code_sha256_prefix":"c53295ac2d63b9e4","entry":"Peri_mid_const","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c53295ac2d63b9e4"}},{"code_sha256_prefix":"ba529f3f8ab574da","entry":"PositionEmbedding","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"ba529f3f8ab574da"}},{"code_sha256_prefix":"280791f6a2fcc047","entry":"PositionalEmbedding","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"280791f6a2fcc047"}},{"code_sha256_prefix":"e988889f2e24b89d","entry":"PositionwiseFeedForward","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":true,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"e988889f2e24b89d"}},{"code_sha256_prefix":"1f9aad235a982189","entry":"RegularMask","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1f9aad235a982189"}},{"code_sha256_prefix":"c6747bad4be93f8f","entry":"TemporalEmbedding","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"c6747bad4be93f8f"}},{"code_sha256_prefix":"83480ecce1d93d50","entry":"Temporal_Embedding","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"83480ecce1d93d50"}},{"code_sha256_prefix":"cb5f35a9d4653c22","entry":"mask_and_indexes","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"cb5f35a9d4653c22"}},{"code_sha256_prefix":"950c3b8c238b3f8c","entry":"Encoder","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"950c3b8c238b3f8c"}},{"code_sha256_prefix":"e48b2afd7479b4f9","entry":"EncoderLayer","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"e48b2afd7479b4f9"}},{"code_sha256_prefix":"5a9238c04a8fe7ad","entry":"FFT_for_Period","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"5a9238c04a8fe7ad"}},{"code_sha256_prefix":"1177d2be24962e5c","entry":"Model","repo":"WuQiangXDU/Peri-midFormer","repo_kind":"official","path":"model/PerimidFormer.py","file_url":"https://github.com/WuQiangXDU/Peri-midFormer/blob/HEAD/model/PerimidFormer.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NONE","inline_ok":false,"mcp_get_code":{"code_sha256":"1177d2be24962e5c"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}