Class RefineMetricWorkingGraph

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

public class RefineMetricWorkingGraph extends Object implements VerbosePrint
Uses SBA to refine the intrinsic parameters and camera locations inside of a SceneWorkingGraph. This is more complex than it sounds since SceneWorkingGraph does not store 3D features it just stores which observations that are part of inlier sets could create a 3D feature. The same observations will belong to different inlier sets and it is possible that they don't point to the same physical feature due to track drift.
  • Field Details

    • maxReprojectionErrorPixel

      public double maxReprojectionErrorPixel
      If the reprojection error is greater than this then the observation will not be assigned to the feature. Units are in pixels. WARNING: Based on test results it seems like this feature makes things worse and is turned off by default.
    • metricSba

      public final MetricBundleAdjustmentUtils metricSba
      Bundle Adjustment functions and configurations
    • listPixelToNorm

      protected final List<Point2Transform2_F64> listPixelToNorm
    • listNormToPixel

      protected final List<Point2Transform2_F64> listNormToPixel
    • verboseViewInfo

      public boolean verboseViewInfo
      If verbose, then it will print view specific information. This can get very verbose in large scenes
    • inlierFilter

      Used to provide custom logic when triangulating points. Useful when merging scenes
    • pixels

      protected final DogArray<Point2D_F64> pixels
    • pixelNormalized

      protected final DogArray<Point2D_F64> pixelNormalized
    • listPoses

      protected final DogArray<Se3_F64> listPoses
    • view0_to_world

      protected final Se3_F64 view0_to_world
  • Constructor Details

    • RefineMetricWorkingGraph

      public RefineMetricWorkingGraph(MetricBundleAdjustmentUtils metricSba)
    • RefineMetricWorkingGraph

      public RefineMetricWorkingGraph()
  • Method Details

    • process

      public boolean process(LookUpSimilarImages dbSimilar, SceneWorkingGraph graph)
      Use the `graph` to define a 3D scene which can be optimized.
      Parameters:
      dbSimilar - (Input) Used to lookup common features between views.
      graph - (Input, Output) Describes scene and provides initial estimate for parameters. Updated with refined parameters on output.
    • process

      public boolean process(LookUpSimilarImages dbSimilar, SceneWorkingGraph graph, RefineMetricWorkingGraph.CallBeforeRefine op)
      Use the `graph` to define a 3D scene which can be optimized.
      Parameters:
      dbSimilar - (Input) Used to lookup common features between views.
      graph - (Input, Output) Describes scene and provides initial estimate for parameters. Updated with refined parameters on output.
    • constructBundleScene

      public boolean constructBundleScene(LookUpSimilarImages dbSimilar, SceneWorkingGraph graph)
      Initializes the scene in bundle adjustment
    • refineViews

      protected boolean refineViews(SceneWorkingGraph graph)
      Refines the scene and updates the graph.
      Parameters:
      graph - (Output) where the updated scene parameters are written to.
      Returns:
      true is successful or false is SBA failed
    • setVerbose

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