{"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/learning-to-remember-patterns-pattern-1","title":"Learning to Remember Patterns: Pattern Matching Memory Networks for Traffic Forecasting","arxiv_id":"2110.10380","date":"2021-10-20","proceeding":"ICLR 2022 4","authors":["Hyunwook Lee","Seungmin Jin","Hyeshin Chu","Hongkyu Lim","Sungahn Ko"],"abstract":"Traffic forecasting is a challenging problem due to complex road networks and sudden speed changes caused by various events on roads. A number of models have been proposed to solve this challenging problem with a focus on learning spatio-temporal dependencies of roads. In this work, we propose a new perspective of converting the forecasting problem into a pattern matching task, assuming that large data can be represented by a set of patterns. To evaluate the validness of the new perspective, we design a novel traffic forecasting model, called Pattern-Matching Memory Networks (PM-MemNet), which learns to match input data to the representative patterns with a key-value memory structure. We first extract and cluster representative traffic patterns, which serve as keys in the memory. Then via matching the extracted keys and inputs, PM-MemNet acquires necessary information of existing traffic patterns from the memory and uses it for forecasting. To model spatio-temporal correlation of traffic, we proposed novel memory architecture GCMem, which integrates attention and graph convolution for memory enhancement. The experiment results indicate that PM-MemNet is more accurate than state-of-the-art models, such as Graph WaveNet with higher responsiveness. We also present a qualitative analysis result, describing how PM-MemNet works and achieves its higher accuracy when road speed rapidly changes.","url_abs":"https://arxiv.org/abs/2110.10380v2","url_pdf":"https://arxiv.org/pdf/2110.10380v2.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":"learning-to-remember-patterns-pattern-1","repo_url":"https://github.com/hyunwookl/pm-memnet","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"traffic-prediction","task_name":"Traffic Prediction"}],"methods":[{"method_slug":"convolution","method_name":"Convolution"},{"method_slug":"dilated-causal-convolution","method_name":"Dilated Causal Convolution"},{"method_slug":"mixture-of-logistic-distributions","method_name":"Mixture of Logistic Distributions"},{"method_slug":"speed","method_name":"SPEED"},{"method_slug":"wavenet","method_name":"WaveNet"}],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/traffic-prediction-on-expy-tky-1","task":"Traffic Prediction","dataset":"EXPY-TKY","model":"PM-MemNet","rank_in_archive_order":5,"of":8,"metrics":{"1 step MAE":"5.94","3 step MAE":"6.52","6 step MAE":"6.87"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2110.10380","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2110.10380"}},"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":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/hyunwookl/pm-memnet","reach":null}],"summary":{"ran_honours":2,"ran":2,"ran_draft_wrong":2,"ran_fixture":2,"unverified":2},"by_repo_kind":{"official":{"samples":9,"ran":7,"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":1,"samples":[{"code_sha256_prefix":"506a63e8992f7432","entry":"count_parameters","repo":"HyunWookL/PM-MemNet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/HyunWookL/PM-MemNet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran_honours","verification_level":2,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"506a63e8992f7432"}},{"code_sha256_prefix":"7a49d4abe5662ef3","entry":"Decoder","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"7a49d4abe5662ef3"}},{"code_sha256_prefix":"6e6df2f3f56776c5","entry":"Encoder","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"6e6df2f3f56776c5"}},{"code_sha256_prefix":"f6b944f50d3f15ae","entry":"count_parameters","repo":null,"repo_kind":null,"path":null,"file_url":null,"link_basis":"identical_code_first_harvested_elsewhere","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":null,"inline_ok":false,"mcp_get_code":{"code_sha256":"f6b944f50d3f15ae"}},{"code_sha256_prefix":"8014c8277fdd9f56","entry":"fourier","repo":"HyunWookL/PM-MemNet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/HyunWookL/PM-MemNet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"8014c8277fdd9f56"}},{"code_sha256_prefix":"75b069b2a552c0b6","entry":"fourier","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"MISDECLARED","metamorphic_tier":"invariant","behaviour_fingerprint":true,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"75b069b2a552c0b6"}},{"code_sha256_prefix":"da1777082c154632","entry":"get_nearest_key","repo":"HyunWookL/PM-MemNet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/HyunWookL/PM-MemNet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"da1777082c154632"}},{"code_sha256_prefix":"5f4e9bd8c7711392","entry":"get_nearest_key","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"ran_fixture","verification_level":1,"contract_check":"RAISES","metamorphic_tier":"invariant","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"5f4e9bd8c7711392"}},{"code_sha256_prefix":"bdc5b4d4d49862c9","entry":"PMMemNet","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"bdc5b4d4d49862c9"}},{"code_sha256_prefix":"a2aea6636f88e641","entry":"gconv","repo":"hyunwookl/pm-memnet","repo_kind":"official","path":"model/PMMemNet.py","file_url":"https://github.com/hyunwookl/pm-memnet/blob/HEAD/model/PMMemNet.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"a2aea6636f88e641"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}