Giter Site home page Giter Site logo

Comments (6)

mihaidusmanu avatar mihaidusmanu commented on July 21, 2024

I do not really understand why you want to use the generalized absolute pose estimation. In general, this is used for localizing a rig with known calibration (intrinsics and relative poses between the cameras of the rig) inside of a 3D world map. In your case, you already have these world transforms (from ARKit) and you only have a single iPhone / iPad camera not a rig (unless you treat the whole trajectory as a rigid rig, but that will have problems with drift).

If you, for instance, want to register your iPhone trajectory with respect to another 3D map, that is where the 3D points for generalized absolute pose estimation will come from - you will have to establish correspondences between the images in the current trajectory and the images in the reference model and the lift the keypoints from the reference model to 3D using e.g. a sparse SfM model or a lidar scan / mesh.

from pycolmap.

theponpon avatar theponpon commented on July 21, 2024

Hi Mihal,

Thanks for the quick answer.
I should have explained what I am trying to achieve:

  • I have a recorded AR session composed of a set of synchronised images, extrinsics and intrinsics
  • I can extract visual features from images and pair features across images

My purpose is to use the bundle adjustment features of Colmap to refine the ARKit extrinsics that can sometime drift, especially in the scenario of closing loops.
I want to use the extrinsics from ARKit as initialisation for the bundle adjustment.
I would like to avoid having to deal with the colmap dataset

How would you recommend to use pycolmap to achieve this?

Thanks in advance,

Pierre

from pycolmap.

mihaidusmanu avatar mihaidusmanu commented on July 21, 2024

PyCOLMAP currently has very limited functionality - we only have bindings for localization purposes: single image pose estimation, rig pose estimation, and relative pose (E / F). There are people working on integrating mapping as well (#20), but it might take a while until it is available.

However, for your task, you can simply run from the command line colmap point_triangulator to triangulate a 3D model from the ARKit poses and intrinsics followed by colmap bundle_adjuster to refine the poses and intrinsics . Please refer to https://colmap.github.io/faq.html#reconstruct-sparse-dense-model-from-known-camera-poses for more details regarding the point triangulator.

from pycolmap.

torkos avatar torkos commented on July 21, 2024

I wish you answered the original question, since I'm also confused regarding the inputs of rig_absolute_pose_estimation.
There's a list of lists of 3d points. And a list of lists of 2d points. If I had 2 cameras, left and right would the first 2d list be left keypoints, and 3d would be the corresponding original 3d, and second list the right 2d points with corresponding 3d in the original?

Or do all the keypoints have to be related somehow (left and right match up)?

from pycolmap.

mihaidusmanu avatar mihaidusmanu commented on July 21, 2024

The parameters are lists of lists of 2D/3D points, each inner list corresponding to a camera. There is no consistency needed between cameras. In your case points2D = [points2D_left, points2D_right] and points3D = [corr_points3D_left, corr_points3D_right].

You can check out the implementation for more details https://github.com/colmap/pycolmap/blob/master/estimators/generalized_absolute_pose.cc#L298-L310

from pycolmap.

torkos avatar torkos commented on July 21, 2024

This is perfect, thank you.

from pycolmap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.