{"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/real-time-motion-prediction-via-heterogeneous-1","title":"Real-Time Motion Prediction via Heterogeneous Polyline Transformer with Relative Pose Encoding","arxiv_id":"2310.12970","date":"2023-10-19","proceeding":"NeurIPS 2023 11","authors":["Zhejun Zhang","Alexander Liniger","Christos Sakaridis","Fisher Yu","Luc van Gool"],"abstract":"The real-world deployment of an autonomous driving system requires its components to run on-board and in real-time, including the motion prediction module that predicts the future trajectories of surrounding traffic participants. Existing agent-centric methods have demonstrated outstanding performance on public benchmarks. However, they suffer from high computational overhead and poor scalability as the number of agents to be predicted increases. To address this problem, we introduce the K-nearest neighbor attention with relative pose encoding (KNARPE), a novel attention mechanism allowing the pairwise-relative representation to be used by Transformers. Then, based on KNARPE we present the Heterogeneous Polyline Transformer with Relative pose encoding (HPTR), a hierarchical framework enabling asynchronous token update during the online inference. By sharing contexts among agents and reusing the unchanged contexts, our approach is as efficient as scene-centric methods, while performing on par with state-of-the-art agent-centric methods. Experiments on Waymo and Argoverse-2 datasets show that HPTR achieves superior performance among end-to-end methods that do not apply expensive post-processing or model ensembling. The code is available at https://github.com/zhejz/HPTR.","url_abs":"https://arxiv.org/abs/2310.12970v1","url_pdf":"https://arxiv.org/pdf/2310.12970v1.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":"real-time-motion-prediction-via-heterogeneous-1","repo_url":"https://github.com/zhejz/hptr","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"NOASSERTION"}},{"paper_slug":"real-time-motion-prediction-via-heterogeneous-1","repo_url":"https://github.com/zhejz/trafficbotsv1.5","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"autonomous-driving","task_name":"Autonomous Driving"},{"task_slug":"motion-prediction","task_name":"motion prediction"}],"methods":[{"method_slug":"absolute-position-encodings","method_name":"Absolute Position Encodings"},{"method_slug":"adam","method_name":"Adam"},{"method_slug":"attention","method_name":"Attention"},{"method_slug":"bpe","method_name":"BPE"},{"method_slug":"dense-connections","method_name":"Dense Connections"},{"method_slug":"dropout","method_name":"Dropout"},{"method_slug":"label-smoothing","method_name":"Label Smoothing"},{"method_slug":"layer-normalization","method_name":"Layer Normalization"},{"method_slug":"linear-layer","method_name":"Linear Layer"},{"method_slug":"multi-head-attention","method_name":"Multi-Head Attention"},{"method_slug":"position-wise-feed-forward-layer","method_name":"Position-Wise Feed-Forward Layer"},{"method_slug":"residual-connection","method_name":"Residual Connection"},{"method_slug":"softmax","method_name":"Softmax"},{"method_slug":"transformer","method_name":"Transformer"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":"https://syntology.ai/paper/2310.12970","atlas_url":"https://app.syntology.ai/?focus=2310.12970","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2310.12970"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-25T09:33:49+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/zhejz/HPTR","reach":{"status":"ok","spdx":"NOASSERTION"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/zhejz/trafficbotsv1.5","reach":null},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/zhejz/hptr","reach":{"status":"ok","spdx":"NOASSERTION"}}],"summary":{"ran":3,"unverified":2},"by_repo_kind":{"official":{"samples":2,"ran":2,"repositories":1},"listed":{"samples":3,"ran":1,"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":5,"samples":[{"code_sha256_prefix":"e1cc0690f1bccc2d","entry":"TransformerBlockRPE","repo":"zhejz/trafficbotsv1.5","repo_kind":"listed","path":"src/models/modules/transformer_rpe.py","file_url":"https://github.com/zhejz/trafficbotsv1.5/blob/HEAD/src/models/modules/transformer_rpe.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"e1cc0690f1bccc2d"}},{"code_sha256_prefix":"baedd5d1cbfc24cb","entry":"collate_agent_features","repo":"zhejz/HPTR","repo_kind":"official","path":"src/pack_h5_womd.py","file_url":"https://github.com/zhejz/HPTR/blob/HEAD/src/pack_h5_womd.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"baedd5d1cbfc24cb"}},{"code_sha256_prefix":"5ee76f66285e35cd","entry":"collate_tl_features","repo":"zhejz/HPTR","repo_kind":"official","path":"src/pack_h5_womd.py","file_url":"https://github.com/zhejz/HPTR/blob/HEAD/src/pack_h5_womd.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"5ee76f66285e35cd"}},{"code_sha256_prefix":"84d8d477bdc71229","entry":"AttentionRPE","repo":"zhejz/trafficbotsv1.5","repo_kind":"listed","path":"src/models/modules/transformer_rpe.py","file_url":"https://github.com/zhejz/trafficbotsv1.5/blob/HEAD/src/models/modules/transformer_rpe.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"84d8d477bdc71229"}},{"code_sha256_prefix":"2f966f70c0b7df04","entry":"TransformerRPE","repo":"zhejz/trafficbotsv1.5","repo_kind":"listed","path":"src/models/modules/transformer_rpe.py","file_url":"https://github.com/zhejz/trafficbotsv1.5/blob/HEAD/src/models/modules/transformer_rpe.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"NOASSERTION","inline_ok":false,"mcp_get_code":{"code_sha256":"2f966f70c0b7df04"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}