3DOM-FBK / COLMAP_SLAM

Visual-SLAM based on COLMAP API
MIT License
245 stars 23 forks source link

Supports equirectangular camera model #1

Open zwl995 opened 1 year ago

zwl995 commented 1 year ago

Hello, would you consider adding the equirectangular camera model?

lcmrl commented 1 year ago

Hi, this is a feature that would be nice to add. COLMAP_SLAM calls the COLMAP API, but currently in the official COLMAP the equirectangular camera model is not implemented yet. I think this would help https://github.com/colmap/colmap/issues/6. Have you seen if this https://github.com/daleydeng/colmap/tree/cvai works for a regular SfM with equirectangular model work? If yes, it should be quick to include it in COLMAP_SLAM

zwl995 commented 11 months ago

Yes, I have to see , the effect is better is not so good, https://github.com/stella-cv/stella_vslam code offer equirectangular camera model SLAM system, but it use the ORB, the outdoor scene will be lost, the cumulative error is bigger

lcmrl commented 11 months ago

Hi, I've not tried yet, but If you have the binaries from https://github.com/daleydeng/colmap/tree/cvai you should able to run it with colmap-slam. In config.ini :

  1. change COLMAP_EXE_DIR = C:\...\COLMAP\COLMAP-3.8-windows-cuda to point to the binaries
  2. change camera calibration
    [CALIBRATION]
    # OPENCV camera model (see COLMAP doc)
    # {
    #    "0": "(SIMPLE_PINHOLE, 3)",
    #    "1": "(PINHOLE, 4)",
    #    "2": "(SIMPLE_RADIAL, 4)",
    #    "3": "(RADIAL, 5)",
    #    "4": "(OPENCV, 8)",
    #    "5": "(OPENCV_FISHEYE, 8)",
    #    "6": "(SIMPLE_RAFULL_OPENCVDIAL, 12)",
    #    "7": "(FOV, 5)",
    #    "8": "(SIMPLE_RADIAL_FISHEYE, 4)",
    #    "9": "(RADIAL_FISHEYE, 5)",
    #    "10": "(THIN_PRISM_FISHEYE, 12)"
    # }
    N_CAMERAS = 1
    CAM0 = 9,2448,2048,774.076,1273.05,1011.24,-0.06044,0.0025

    The first number is the camera model, you have to check the right number from the repository