Package boofcv.alg.structure
Class GenerateStereoPairGraphFromScene
java.lang.Object
boofcv.alg.structure.GenerateStereoPairGraphFromScene
- All Implemented Interfaces:
VerbosePrint
Given the
sparse reconstruction, create a StereoPairGraph that
describes which views are compatible for computing dense stereo disparity from.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classPoints visible in the view -
Field Summary
FieldsModifier and TypeFieldDescriptiondoubleIntended to stop small number of observations causing large swings in score.doubleMinimum fraction for common features between the two framesdoubleIf the predicted disparity is above this value the score will not improve. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcomputePointingVector(Se3_F64 world_to_view, SceneStructureCommon.Point p, boolean homogenous, Vector3D_F64 pointing) Computes the pointing vector between the view and point in world frame.protected voidconnect(int viewIdxA, int viewIdxB) Connects two views together and makes sure it isn't done twiceprotected voidcreateStereoGraph(gnu.trove.map.TIntObjectMap<String> viewToId) Creates the output graph.protected voidfindCommonFeatureAngles(GenerateStereoPairGraphFromScene.View viewA, GenerateStereoPairGraphFromScene.View viewB) Finds common features between the two views and computes the acute angles between themprotected voidCreates a lookup table from view to points and find the vector going from view to pointvoidprocess(gnu.trove.map.TIntObjectMap<String> viewIdx_to_imageId, SceneStructureMetric scene) Computes aStereoPairGraphfrom the sparse scene graphvoidsetVerbose(@Nullable PrintStream out, @Nullable Set<String> set)
-
Field Details
-
countSmootherParam
public double countSmootherParamIntended to stop small number of observations causing large swings in score. Larger means more smoothing. -
minimumCommonFeaturesFrac
public double minimumCommonFeaturesFracMinimum fraction for common features between the two frames -
targetDisparity
public double targetDisparityIf the predicted disparity is above this value the score will not improve.
-
-
Constructor Details
-
GenerateStereoPairGraphFromScene
public GenerateStereoPairGraphFromScene()
-
-
Method Details
-
process
public void process(gnu.trove.map.TIntObjectMap<String> viewIdx_to_imageId, SceneStructureMetric scene) Computes aStereoPairGraphfrom the sparse scene graph- Parameters:
viewIdx_to_imageId- (Input) Look up table from view index in scene to the image ID/namescene- (Input) Sparse 3D scene
-
matchPointsToViews
Creates a lookup table from view to points and find the vector going from view to point -
computePointingVector
protected void computePointingVector(Se3_F64 world_to_view, SceneStructureCommon.Point p, boolean homogenous, Vector3D_F64 pointing) Computes the pointing vector between the view and point in world frame.- Parameters:
pointing- (Output) Cartesian vector pointing from the view to the point.
-
connect
protected void connect(int viewIdxA, int viewIdxB) Connects two views together and makes sure it isn't done twice -
createStereoGraph
Creates the output graph. A vertex is created for each view in the scene. The quality between connected views is found by looking at the angle between points and the number of common points -
findCommonFeatureAngles
protected void findCommonFeatureAngles(GenerateStereoPairGraphFromScene.View viewA, GenerateStereoPairGraphFromScene.View viewB) Finds common features between the two views and computes the acute angles between them -
setVerbose
- Specified by:
setVerbosein interfaceVerbosePrint
-