Class ThreeViewEstimateMetricScene

java.lang.Object
boofcv.alg.structure.ThreeViewEstimateMetricScene
All Implemented Interfaces:
VerbosePrint

public class ThreeViewEstimateMetricScene extends Object implements VerbosePrint

Estimates the metric scene's structure given a set of sparse features associations from three views. This is intended to give the best possible solution from the sparse set of matching features. Its internal methods are updated as better strategies are found.

Assumptions:
  • Principle point is zero
  • Zero skew
  • fx = fy approximately

The zero principle point is enforced prior to calling process(java.util.List<boofcv.struct.geo.AssociatedTriple>) by subtracting the image center from each pixel observations.

Steps:
  1. Fit Trifocal tensor using RANSAC
  2. Get and refine camera matrices
  3. Compute dual absolute quadratic
  4. Estimate intrinsic parameters from DAC
  5. Estimate metric scene structure
  6. Sparse bundle adjustment
  7. Tweak parameters and sparse bundle adjustment again
  • Field Details

    • configSelfCalib

      public ConfigPixelsToMetric configSelfCalib
    • configRansac

      public ConfigRansac configRansac
    • configSBA

      public ConfigBundleAdjustment configSBA
    • convergeSBA

      public ConfigConverge convergeSBA
    • homogenous

      public boolean homogenous
      Optimize points in homogenous coordinates
    • viewToCamera

      public int[] viewToCamera
      Use to specify if multiple views share a camera. Values from 0 to 2, inclusive.
    • manualFocalLength

      public double manualFocalLength
      If a positive number the focal length will be assumed to be that
    • pruneFraction

      public double pruneFraction
      How many features it will keep when pruning. If it prunes features then you will long longer know which feature in structure corresponds to an inlier.
    • ransac

    • inliers

      public List<AssociatedTriple> inliers
    • listPinhole

      public final DogArray<CameraPinholeBrown> listPinhole
      Found intrinsics for each camera
    • listWorldToView

      public final DogArray<Se3_F64> listWorldToView
      Found extrinsics for each view. view 0 is always identity
    • bundleAdjustment

      public BundleAdjustment<SceneStructureMetric> bundleAdjustment
    • width

      protected int width
    • height

      protected int height
  • Constructor Details

    • ThreeViewEstimateMetricScene

      public ThreeViewEstimateMetricScene()
      Sets configurations to their default value
  • Method Details

    • declareAlgorithms

      public void declareAlgorithms()
      Use configurations to create new instances of algorithms.
    • initialize

      public void initialize(int width, int height)
      Initializes data structures and fixates configurations
      Parameters:
      width - width of all images
      height - height of all images
    • process

      public boolean process(List<AssociatedTriple> associated)
      Determines the metric scene. Pixel coordinates are assumed to already have been adjusted for the principle point being zero, e.g. minus (cx, cy).
      Parameters:
      associated - List of associated features from 3 views. pixels
      Returns:
      true if successful or false if it failed
    • setVerbose

      public void setVerbose(@Nullable @Nullable PrintStream out, @Nullable @Nullable Set<String> configuration)
      Specified by:
      setVerbose in interface VerbosePrint