Class InitializeCommonMetric

All Implemented Interfaces:

public class InitializeCommonMetric extends Object implements VerbosePrint
Given a set of views and a set of features which are visible in all views, estimate their metric structure.
  1. Select the three best 3 views
  2. Association between all 3 views
  3. Robust self calibration
TODO handle 2-view case TODO specify camera shape individually. One camera is used for all views right now TODO Need to provide some way to external adjust RANSAC parameters here TODO Handle planar scenes.
  • Field Details

    • utils

      public PairwiseGraphUtils utils
      Common algorithms for reconstructing the projective scene
    • pixelToMetric3

      protected final ThreeViewEstimateMetricScene pixelToMetric3
      Used to convert observations from 3-views into a metric scene
    • inlierIndexes

      protected final DogArray<DogArray_I32> inlierIndexes
      List of feature indexes for each view that are part of the inlier set. The seed view is at index 0. The other indexes are in order of 'seedConnIdx'.
    • viewsByStructureIndex

      protected final FastArray<PairwiseImageGraph.View> viewsByStructureIndex
    • seedToStructure

      protected final DogArray_I32 seedToStructure
      lookup table from feature ID in seed view to structure index. There will only be 3D features for members of the inlier set.
  • Constructor Details

    • InitializeCommonMetric

      public InitializeCommonMetric(ConfigProjectiveReconstruction configProjective)
    • InitializeCommonMetric

      public InitializeCommonMetric()
  • Method Details

    • metricScene

      public boolean metricScene(LookUpSimilarImages dbSimilar, LookUpCameraInfo dbCams, PairwiseImageGraph.View seed, DogArray_I32 seedConnIdx, MetricCameras results)
      Computes a metric reconstruction. Reconstruction will be relative the 'seed' and only use features listed in 'common'. The list of views is taken from seed and is specified in 'motions'.
      dbSimilar - (Input) Data based used to look up information on each image
      seed - (Input) The seed view that will act as the origin
      seedConnIdx - (Input) Indexes of motions in the seed view to use when initializing
      results - (Output) Found metric reconstruction for seed and selected connected views
      true is successful or false if it failed
    • estimateMetricCamerasRobustly

      public boolean estimateMetricCamerasRobustly()
      Robustly estimates metric views with extrinsics known up to a scale factor
    • getPairwiseGraphViewByStructureIndex

      public PairwiseImageGraph.View getPairwiseGraphViewByStructureIndex(int index)
      Returns the PairwiseImageGraph.View given the index of the view in structure
    • setVerbose

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

      public SceneStructureMetric getStructure()