{"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/uncertainty-based-traffic-accident","title":"Uncertainty-based Traffic Accident Anticipation with Spatio-Temporal Relational Learning","arxiv_id":"2008.00334","date":"2020-08-01","proceeding":null,"authors":["Wentao Bao","Qi Yu","Yu Kong"],"abstract":"Traffic accident anticipation aims to predict accidents from dashcam videos as early as possible, which is critical to safety-guaranteed self-driving systems. With cluttered traffic scenes and limited visual cues, it is of great challenge to predict how long there will be an accident from early observed frames. Most existing approaches are developed to learn features of accident-relevant agents for accident anticipation, while ignoring the features of their spatial and temporal relations. Besides, current deterministic deep neural networks could be overconfident in false predictions, leading to high risk of traffic accidents caused by self-driving systems. In this paper, we propose an uncertainty-based accident anticipation model with spatio-temporal relational learning. It sequentially predicts the probability of traffic accident occurrence with dashcam videos. Specifically, we propose to take advantage of graph convolution and recurrent networks for relational feature learning, and leverage Bayesian neural networks to address the intrinsic variability of latent relational representations. The derived uncertainty-based ranking loss is found to significantly boost model performance by improving the quality of relational features. In addition, we collect a new Car Crash Dataset (CCD) for traffic accident anticipation which contains environmental attributes and accident reasons annotations. Experimental results on both public and the newly-compiled datasets show state-of-the-art performance of our model. Our code and CCD dataset are available at https://github.com/Cogito2012/UString.","url_abs":"https://arxiv.org/abs/2008.00334v1","url_pdf":"https://arxiv.org/pdf/2008.00334v1.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":"uncertainty-based-traffic-accident","repo_url":"https://github.com/Cogito2012/CarCrashDataset","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"none","reach":{"status":"ok","spdx":"MIT"}},{"paper_slug":"uncertainty-based-traffic-accident","repo_url":"https://github.com/Cogito2012/UString","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"accident-anticipation","task_name":"Accident Anticipation"},{"task_slug":"activity-prediction","task_name":"Activity Prediction"},{"task_slug":"future-prediction","task_name":"Future prediction"},{"task_slug":"relational-reasoning","task_name":"Relational Reasoning"},{"task_slug":"time-to-event-prediction","task_name":"Time-to-Event Prediction"},{"task_slug":"video-understanding","task_name":"Video Understanding"}],"methods":[{"method_slug":"convolution","method_name":"Convolution"}],"datasets_introduced":[{"slug":"ccd","name":"CCD","full_name":"Car Crash Dataset"}],"methods_introduced":[],"results":[{"leaderboard":"/sota/accident-anticipation-on-ccd","task":"Accident Anticipation","dataset":"CCD","model":"UString","rank_in_archive_order":2,"of":2,"metrics":{"AP":"99.5","TTA":"4.74"},"uses_additional_data":false}],"syntology":{"syntology_url":null,"atlas_url":"https://app.syntology.ai/?focus=2008.00334","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2008.00334"}},"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/Cogito2012/UString","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/Cogito2012/CarCrashDataset","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran_honours":1,"unverified":9},"by_repo_kind":{"official":{"samples":10,"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":0,"samples":[{"code_sha256_prefix":"cb2d801625fc35f2","entry":"tuple_to_array","repo":"Cogito2012/UString","repo_kind":"official","path":"src/utils.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/src/utils.py","link_basis":"harvester_set","language":"python","status":"ran_honours","verification_level":1,"contract_check":"HONOURS","metamorphic_tier":"well_formed","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"cb2d801625fc35f2"}},{"code_sha256_prefix":"2027d64ab218fc74","entry":"bbox_to_imroi","repo":"Cogito2012/UString","repo_kind":"official","path":"script/extract_res101_dad.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/script/extract_res101_dad.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":"2027d64ab218fc74"}},{"code_sha256_prefix":"1f2bee452d766f67","entry":"compute_graph_edge_weights","repo":"Cogito2012/UString","repo_kind":"official","path":"src/DataLoader.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/src/DataLoader.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":"1f2bee452d766f67"}},{"code_sha256_prefix":"491e614341f4f94d","entry":"evaluation","repo":"Cogito2012/UString","repo_kind":"official","path":"src/eval_tools.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/src/eval_tools.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":"491e614341f4f94d"}},{"code_sha256_prefix":"17771c96b9488ae3","entry":"generate_graph_from_list","repo":"Cogito2012/UString","repo_kind":"official","path":"src/DataLoader.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/src/DataLoader.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":"17771c96b9488ae3"}},{"code_sha256_prefix":"214b0b5552c42efd","entry":"generate_st_graph","repo":"Cogito2012/UString","repo_kind":"official","path":"src/DataLoader.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/src/DataLoader.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":"214b0b5552c42efd"}},{"code_sha256_prefix":"bdd64a977afd9b6c","entry":"get_boxes","repo":"Cogito2012/UString","repo_kind":"official","path":"script/extract_res101_dad.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/script/extract_res101_dad.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":"bdd64a977afd9b6c"}},{"code_sha256_prefix":"4c512b058c37afb2","entry":"get_video_frames","repo":"Cogito2012/UString","repo_kind":"official","path":"script/extract_res101_dad.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/script/extract_res101_dad.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":"4c512b058c37afb2"}},{"code_sha256_prefix":"8cf8cc5c870f5866","entry":"get_video_frames","repo":"Cogito2012/UString","repo_kind":"official","path":"script/vis_crash_det.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/script/vis_crash_det.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":"8cf8cc5c870f5866"}},{"code_sha256_prefix":"6242e10c800afddf","entry":"process","repo":"Cogito2012/UString","repo_kind":"official","path":"script/split_dad.py","file_url":"https://github.com/Cogito2012/UString/blob/HEAD/script/split_dad.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":"6242e10c800afddf"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}