{"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/deep-two-view-structure-from-motion-revisited","title":"Deep Two-View Structure-from-Motion Revisited","arxiv_id":"2104.00556","date":"2021-04-01","proceeding":"CVPR 2021 1","authors":["Jianyuan Wang","Yiran Zhong","Yuchao Dai","Stan Birchfield","Kaihao Zhang","Nikolai Smolyanskiy","Hongdong Li"],"abstract":"Two-view structure-from-motion (SfM) is the cornerstone of 3D reconstruction and visual SLAM. Existing deep learning-based approaches formulate the problem by either recovering absolute pose scales from two consecutive frames or predicting a depth map from a single image, both of which are ill-posed problems. In contrast, we propose to revisit the problem of deep two-view SfM by leveraging the well-posedness of the classic pipeline. Our method consists of 1) an optical flow estimation network that predicts dense correspondences between two frames; 2) a normalized pose estimation module that computes relative camera poses from the 2D optical flow correspondences, and 3) a scale-invariant depth estimation network that leverages epipolar geometry to reduce the search space, refine the dense correspondences, and estimate relative depth maps. Extensive experiments show that our method outperforms all state-of-the-art two-view SfM methods by a clear margin on KITTI depth, KITTI VO, MVS, Scenes11, and SUN3D datasets in both relative pose and depth estimation.","url_abs":"https://arxiv.org/abs/2104.00556v1","url_pdf":"https://arxiv.org/pdf/2104.00556v1.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":"deep-two-view-structure-from-motion-revisited","repo_url":"https://github.com/jytime/Deep-SfM-Revisited","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"3d-reconstruction","task_name":"3D Reconstruction"},{"task_slug":"depth-estimation","task_name":"Depth Estimation"},{"task_slug":"monocular-depth-estimation","task_name":"Monocular Depth Estimation"},{"task_slug":"optical-flow-estimation","task_name":"Optical Flow Estimation"},{"task_slug":"pose-estimation","task_name":"Pose Estimation"},{"task_slug":"two","task_name":"Vocal Bursts Valence Prediction"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/monocular-depth-estimation-on-kitti-eigen","task":"Monocular Depth Estimation","dataset":"KITTI Eigen split","model":"SfM-Revisited","rank_in_archive_order":30,"of":79,"metrics":{"RMSE":"2.273","Sq Rel":"0.224","absolute relative error":"0.055"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2104.00556","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2104.00556"}},"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/jytime/Deep-SfM-Revisited","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"ran":4,"ran_draft_wrong":1,"unverified":16},"by_repo_kind":{"official":{"samples":21,"ran":5,"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":"abcbf43ad9fe6129","entry":"compute_color","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"flow_viz.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/flow_viz.py","link_basis":"harvester_set","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":"abcbf43ad9fe6129"}},{"code_sha256_prefix":"8bfc895e86bfc7bc","entry":"load_velodyne_points","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"kitti_utils.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/kitti_utils.py","link_basis":"harvester_set","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":"8bfc895e86bfc7bc"}},{"code_sha256_prefix":"c3f23a008d953af5","entry":"predict_flow","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"models/DICL_shallow.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/models/DICL_shallow.py","link_basis":"harvester_set","language":"python","status":"ran_draft_wrong","verification_level":1,"contract_check":"OUTPUT_MISDECLARED","metamorphic_tier":"deterministic","behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"c3f23a008d953af5"}},{"code_sha256_prefix":"ff833c099a80a327","entry":"read_calib_file","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"kitti_utils.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/kitti_utils.py","link_basis":"harvester_set","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":"ff833c099a80a327"}},{"code_sha256_prefix":"04e9b96b63844176","entry":"sub2ind","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"kitti_utils.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/kitti_utils.py","link_basis":"harvester_set","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":"04e9b96b63844176"}},{"code_sha256_prefix":"c904f0e9da049f2a","entry":"MSE_loss","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"models/CVPMVS.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/models/CVPMVS.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":"c904f0e9da049f2a"}},{"code_sha256_prefix":"0d38c54288d1ecd2","entry":"compute_valid_depth_mask","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"demon_metrics.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/demon_metrics.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":"0d38c54288d1ecd2"}},{"code_sha256_prefix":"cd9d415e756ddad5","entry":"convbn","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"models/DICL_shallow.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/models/DICL_shallow.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":"cd9d415e756ddad5"}},{"code_sha256_prefix":"5053cba75a330c97","entry":"coord2flow","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"epipolar_utils.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/epipolar_utils.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":"5053cba75a330c97"}},{"code_sha256_prefix":"1abf6f49a505fcbe","entry":"disparity_loader_png","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"KITTI_loader.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/KITTI_loader.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":"1abf6f49a505fcbe"}},{"code_sha256_prefix":"a99f9e38ae607fd8","entry":"flow2coord","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"epipolar_utils.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/epipolar_utils.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":"a99f9e38ae607fd8"}},{"code_sha256_prefix":"215f62561b03c262","entry":"flow_compute_color","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"flow_viz.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/flow_viz.py","link_basis":"harvester_set","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":"215f62561b03c262"}},{"code_sha256_prefix":"d59fe7ab39463182","entry":"flow_to_color","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"flow_viz.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/flow_viz.py","link_basis":"harvester_set","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":"d59fe7ab39463182"}},{"code_sha256_prefix":"94676aa789a890f5","entry":"l1","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"demon_metrics.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/demon_metrics.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":"94676aa789a890f5"}},{"code_sha256_prefix":"8d573359b9ccf5f6","entry":"l1_inverse","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"demon_metrics.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/demon_metrics.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":"8d573359b9ccf5f6"}},{"code_sha256_prefix":"914690083c05e41c","entry":"load_flow_from_png","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"KITTI_loader.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/KITTI_loader.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":"914690083c05e41c"}},{"code_sha256_prefix":"3eee763265fa66e7","entry":"mask_loader_png","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"KITTI_loader.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/KITTI_loader.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":"3eee763265fa66e7"}},{"code_sha256_prefix":"48b6598aa92d35a5","entry":"photometric_reconstruction_loss_Charbonnier","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"loss_functions.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/loss_functions.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":"48b6598aa92d35a5"}},{"code_sha256_prefix":"bfabd42bc420f7f0","entry":"resize_sparse_map","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"flow_transforms.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/flow_transforms.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":"bfabd42bc420f7f0"}},{"code_sha256_prefix":"646d6725b699091e","entry":"sL1_loss","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"models/CVPMVS.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/models/CVPMVS.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":"646d6725b699091e"}},{"code_sha256_prefix":"dff279c368fc0d20","entry":"weighted_smooth_depth_loss","repo":"jytime/Deep-SfM-Revisited","repo_kind":"official","path":"loss_functions.py","file_url":"https://github.com/jytime/Deep-SfM-Revisited/blob/HEAD/loss_functions.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":"dff279c368fc0d20"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}