{"action":"created","issue":{"url":"https://api.github.com/repos/hengli/camodocal/issues/42","labels_url":"https://api.github.com/repos/hengli/camodocal/issues/42/labels{/name}","comments_url":"https://api.github.com/repos/hengli/camodocal/issues/42/comments","events_url":"https://api.github.com/repos/hengli/camodocal/issues/42/events","html_url":"https://github.com/hengli/camodocal/issues/42","id":113339547,"number":42,"title":"Question regarding coordinate systems and determining the yaw angle from bearing","user":{"login":"stanathong","id":8308557,"avatar_url":"https://avatars.githubusercontent.com/u/8308557?v=3","gravatar_id":"","url":"https://api.github.com/users/stanathong","html_url":"https://github.com/stanathong","followers_url":"https://api.github.com/users/stanathong/followers","following_url":"https://api.github.com/users/stanathong/following{/other_user}","gists_url":"https://api.github.com/users/stanathong/gists{/gist_id}","starred_url":"https://api.github.com/users/stanathong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stanathong/subscriptions","organizations_url":"https://api.github.com/users/stanathong/orgs","repos_url":"https://api.github.com/users/stanathong/repos","events_url":"https://api.github.com/users/stanathong/events{/privacy}","received_events_url":"https://api.github.com/users/stanathong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-10-26T11:54:37Z","updated_at":"2015-12-12T07:14:27Z","closed_at":null,"body":"Hi, I would really appreciate your help in answering my questions below. I have been struggling with this for over three weeks now. \r\n\r\n(1) I have a 5-camera mounted on a van with a GPS receiver (only 3 is used in the testing with CamOdoCal). I obtained position (Lat/Lon) and bearing angle from GPS. As I don't have an IMU, I computed the yaw angle which tells the orientation around the Z axis. \r\n\r\n       double yaw_degree = -(bearing_degree_from_GPS - 90.0);\r\n\r\nHere, I assume the coordinate system used in CamOdoCal is ENU, and the vehicle's positive x-axis points toward the direction of movement, positive y-axis on the the vehicle left. I wonder if my assumption is right, please help confirm. \r\n\r\nIn the testing to perform extrinsic calibration for multi-camera, we only made the yaw motion, ensuring that the ground is flat (making no pitch and roll).\r\n\r\n(2) Using those yaw angles converted to rotation matrix then quaternion, and input into CamOdoCal in the form of \r\n        [timestamp] CAM [camera_id] [image filename]\r\n\t[timestamp] IMU [quaternion x] [quaternion y] [quaternion z] [quaternion w]\r\n\t[timestamp] GPS [latitude] [longitude] [alt]\r\nand, despite changing some setting such as detector and descriptor, I still couldn't have CamOdoCal run past stage 3 of CamaeraRigBA::Run.\r\n\r\n[PASSED] stage 1 - triangulate 3D points with feature correspondences from mono VO and run BA\r\n[PASSED ] stage 2 - run robust pose graph SLAM and find inlier 2D-3D correspondences from loop closures\r\n[PROGRAM STOPPED HERE] stage 3 - find local inter-camera 3D-3D correspondences\r\nwith the following log messages: (no crashed)\r\n\r\nPlease can you suggest what should I do to make it work with my system. Your help is really much appreciated. Thank you very much.\r\n.......\r\n\r\nCeres Solver Report: Iterations: 31, Initial cost: 2.702882e+01, Final cost: 1.206417e+01, Termination: FUNCTION_TOLERANCE.\r\n.#  INFO: After refinement:\r\nH_cam_odo = \r\n  0.693116   0.168301   0.700903  -0.100646\r\n -0.144071   0.985086 -0.0940688   0.325688\r\n -0.706282 -0.0357792   0.707026          0\r\n         0          0          0          1\r\nscales = \r\n-0.0966268 \r\n.#.  INFO: Calibrating odometry - camera 2...\r\nRotation: \r\n  0.693116   0.168301   0.700903\r\n -0.144071   0.985086 -0.0940688\r\n -0.706282 -0.0357792   0.707026\r\nTranslation: \r\n-0.100646 0.325688        0\r\nCeres Solver Report: Iterations: 25, Initial cost: 1.799722e+01, Final cost: 1.064531e+01, Termination: FUNCTION_TOLERANCE.\r\n.#  INFO: After refinement:\r\nH_cam_odo = \r\n 0.713364 -0.280516 -0.642202 -0.113423\r\n0.0840694  0.944029  -0.31897  0.294703\r\n 0.695733  0.173552  0.697019         0\r\n        0         0         0         1\r\nscales = \r\n0.0699959 \r\n.#  INFO: Calibrating odometry - camera 1...\r\nRotation: \r\n 0.713364 -0.280516 -0.642202\r\n0.0840694  0.944029  -0.31897\r\n 0.695733  0.173552  0.697019\r\nTranslation: \r\n-0.113423 0.294703        0\r\nCeres Solver Report: Iterations: 75, Initial cost: 2.484698e+01, Final cost: 1.217647e+01, Termination: FUNCTION_TOLERANCE.\r\n.#  INFO: After refinement:\r\nH_cam_odo = \r\n 0.0996435   -0.98357   0.150533  -0.111327\r\n  0.710327 -0.0356262  -0.702969   0.349939\r\n  0.696783   0.176974   0.695107          0\r\n         0          0          0          1\r\nscales = \r\n0.0813187 \r\n.#  INFO: Calibrating odometry - camera 0...\r\nRotation: \r\n 0.0996435   -0.98357   0.150533\r\n  0.710327 -0.0356262  -0.702969\r\n  0.696783   0.176974   0.695107\r\nTranslation: \r\n-0.111327 0.349939        0\r\n.#  INFO: Reprojection error for camera 2: avg = 0.516288 px | max = 801.914 px\r\n.#  INFO: Reprojection error for camera 0: avg = 0.565628 px | max = 469.029 px\r\n.#  INFO: Reprojection error for camera 1: avg = 0.304846 px | max = 84.1896 px\r\n.#  INFO: Completed camera-odometry calibration for all cameras.\r\n.#  INFO: Saving intermediate data... \r\nDone. Took 24.46s.\r\n.#  INFO: Running camera rig calibration.\r\n.#  INFO: # segments = 1\r\n.#  INFO:   Segment 0: # frame sets = 59\r\n.#  INFO: Reprojection error: avg = 0.45 px | max = 493.62 px | # obs = 389194\r\n.#  INFO: Triangulating feature correspondences... \r\n.#  INFO: Reprojection error after triangulation: avg = 9400363031163346944.00 px | max = 1178337959001900481249280.00 px | # obs = 269012\r\n.#  INFO: # 3D scene points: 101400\r\n.#  INFO: Checking the validity of the graph...\r\n.#  INFO: Finished checking the validity of the graph.\r\n.#  INFO: Reprojection error after pruning: avg = 632419244318232832.00 px | max = 146216321810127040544768.00 px | # obs = 245574\r\n.#  INFO: # 3D scene points: 97063\r\n.#  INFO: Running BA on odometry data... \r\n.#  INFO: Done.\r\n.#  INFO: Reprojection error after BA (odometry): avg = 45.00 px | max = 10016.56 px | # obs = 233509\r\n.#  INFO: # 3D scene points: 92924\r\n.#  INFO: Running robust pose graph optimization... \r\n.#  INFO: Building odometry edges...\r\n.#  INFO: Built 58 odometry edges.\r\n.#  INFO: Building loop closure edges...\r\n.#  INFO: Built 0 loop closure edges.\r\nCeres Solver Report: Iterations: 0, Initial cost: 2.572128e-31, Final cost: 2.572128e-31, Termination: PARAMETER_TOLERANCE.\r\n.#  INFO: # inlier 2D-3D correspondences: 0\r\n.#  INFO: Merged 0 3D scene points.\r\n.#  INFO: Running BA on odometry data... \r\n.#  INFO: Reprojection error after robust pose-graph optimization: avg = 43.25 px | max = 4145.38 px | # obs = 229033\r\n.#  INFO: # 3D scene points: 90947\r\n.#  INFO: Finding inter-map 3D-3D correspondences... \r\n.#  INFO: Entering frame set node 0-0 [ 1 0 1 ]\r\n"},"comment":{"url":"https://api.github.com/repos/hengli/camodocal/issues/comments/164116851","html_url":"https://github.com/hengli/camodocal/issues/42#issuecomment-164116851","issue_url":"https://api.github.com/repos/hengli/camodocal/issues/42","id":164116851,"user":{"login":"Hu20130201","id":8944335,"avatar_url":"https://avatars.githubusercontent.com/u/8944335?v=3","gravatar_id":"","url":"https://api.github.com/users/Hu20130201","html_url":"https://github.com/Hu20130201","followers_url":"https://api.github.com/users/Hu20130201/followers","following_url":"https://api.github.com/users/Hu20130201/following{/other_user}","gists_url":"https://api.github.com/users/Hu20130201/gists{/gist_id}","starred_url":"https://api.github.com/users/Hu20130201/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Hu20130201/subscriptions","organizations_url":"https://api.github.com/users/Hu20130201/orgs","repos_url":"https://api.github.com/users/Hu20130201/repos","events_url":"https://api.github.com/users/Hu20130201/events{/privacy}","received_events_url":"https://api.github.com/users/Hu20130201/received_events","type":"User","site_admin":false},"created_at":"2015-12-12T07:14:27Z","updated_at":"2015-12-12T07:14:27Z","body":"@stanathong  Is it the picture data continous frame picture, not keyfame picture?\r\nthank you"}}