Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse
Brand Logo

ModalAI Forum

  1. ModalAI Support Forum
  2. General Questions
  3. Get depth from dfs

Get depth from dfs

Scheduled Pinned Locked Moved Unsolved General Questions
3 Posts 3 Posters 862 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    planch98
    Contributor
    wrote on last edited by
    #1

    Hi, I'm currently working on an application that requires depth information. After configuring voxl-dfs-server I'm able to obtain a good disparity. I compute the depth information as so: depth = focal length*baseline/disparity. The result that I obtain seems wrong by a scaling factor. Focal length and baseline are taken from the calibration file obtained from voxl-calibrate-camera stereo.

    Can you share some information on how to perform this operation?

    dfs config file:

    "dfs_pair_1_input_pipe":	"stereo_rear",
    	"dfs_pair_1_skip_n_frames":	1,
    	"dfs_pair_1_blur_size":	9,
    	"dfs_pair_1_post_median_size":	15,
    	"dfs_pair_1_intrinsics_file":	"/data/modalai/opencv_stereo_rear_intrinsics.yml",
    	"dfs_pair_1_extrinsics_file":	"/data/modalai/opencv_stereo_rear_extrinsics.yml",
    	"dfs_pair_1_en_cvp_rectification":	1,
    	"dfs_pair_1_min_disparity":	4,
    	"dfs_pair_1_max_disparity":	64,
    	"dfs_pair_1_min_threshold":	10,
    	"dfs_pair_1_cost_threshold":	80,
    
    C 1 Reply Last reply
    0
    • P planch98

      Hi, I'm currently working on an application that requires depth information. After configuring voxl-dfs-server I'm able to obtain a good disparity. I compute the depth information as so: depth = focal length*baseline/disparity. The result that I obtain seems wrong by a scaling factor. Focal length and baseline are taken from the calibration file obtained from voxl-calibrate-camera stereo.

      Can you share some information on how to perform this operation?

      dfs config file:

      "dfs_pair_1_input_pipe":	"stereo_rear",
      	"dfs_pair_1_skip_n_frames":	1,
      	"dfs_pair_1_blur_size":	9,
      	"dfs_pair_1_post_median_size":	15,
      	"dfs_pair_1_intrinsics_file":	"/data/modalai/opencv_stereo_rear_intrinsics.yml",
      	"dfs_pair_1_extrinsics_file":	"/data/modalai/opencv_stereo_rear_extrinsics.yml",
      	"dfs_pair_1_en_cvp_rectification":	1,
      	"dfs_pair_1_min_disparity":	4,
      	"dfs_pair_1_max_disparity":	64,
      	"dfs_pair_1_min_threshold":	10,
      	"dfs_pair_1_cost_threshold":	80,
      
      C Offline
      C Offline
      cch
      wrote on last edited by
      #2

      @planch98 Have you ever tried to calibrate the camera again to see if the parameters have changed? After calibrating the stereo camera several times, I found that the wrong parameters could be obtained due to inputting the wrong width of the chessboard. By the way, could you please give some suggestions on this issue link text?

      ModeratorM 1 Reply Last reply
      0
      • C cch

        @planch98 Have you ever tried to calibrate the camera again to see if the parameters have changed? After calibrating the stereo camera several times, I found that the wrong parameters could be obtained due to inputting the wrong width of the chessboard. By the way, could you please give some suggestions on this issue link text?

        ModeratorM Offline
        ModeratorM Offline
        Moderator
        ModalAI Team
        wrote on last edited by
        #3

        @cch you can see the code where voxl-vision-hub takes the pointcloud topic from DFS and uses the information, this should be a good reference: https://gitlab.com/voxl-public/voxl-sdk/services/voxl-vision-hub/-/blob/master/src/voa_manager.c?ref_type=heads#L434

        1 Reply Last reply
        0

        Reading along? Create a free ModalAI Forum account to join in.

        With an account you can reply, ask your own question, get an email when a ModalAI engineer answers, and mark the reply that solved it. Your place in each thread is saved between visits.

        Questions about VOXL, Flight Core, ESCs and ModalAI drones are answered here by the engineers who build them.

        Register Login
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        ModalAI
        Categories Recent Tags ModalAI.com Docs
        © 2026 ModalAI® · Accelerating autonomy for smaller, smarter, safer drones · Powered by NodeBB
        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups