Skip to content
Snippets Groups Projects

Resolve "New ProcessorLoopClosure"

Merged Joan Vallvé Navarro requested to merge 398-new-processorloopclosure into devel
3 files
+ 35
17
Compare changes
  • Side-by-side
  • Inline
Files
3
@@ -16,6 +16,20 @@ struct ParamsProcessorLoopClosure : public ParamsProcessorBase
// add neccesery parameters for loop closure initialisation here and initialize
// them in constructor
};
WOLF_STRUCT_PTR_TYPEDEFS(MatchLoopClosure);
/** \brief Match between a capture and a capture
*
* Match between a capture and a capture (capture-capture correspondence)
*
*/
struct MatchLoopClosure
{
CaptureBasePtr capture_reference_ptr_; ///< Capture reference
CaptureBasePtr capture_target_ptr_; ///< Capture target
double normalized_score_; ///< normalized similarity score (0 is bad, 1 is good)
};
/** \brief General loop closure processor
*
@@ -29,7 +43,6 @@ struct ParamsProcessorLoopClosure : public ParamsProcessorBase
* + You can override the following classes :
* - process(CaptureBasePtr)
*/
class ProcessorLoopClosure : public ProcessorBase
{
protected:
@@ -61,15 +74,15 @@ protected:
/** \brief Find captures that correspond to loop closures with the given capture
*/
virtual CaptureBasePtrList findLoopClosures(CaptureBasePtr _capture) = 0;
virtual std::list<MatchLoopClosurePtr> findLoopClosures(CaptureBasePtr _capture) = 0;
/** \brief validates a loop closure
*/
virtual bool validateLoopClosure(CaptureBasePtr _capture_1, CaptureBasePtr _capture_2) = 0;
virtual bool validateLoopClosure(MatchLoopClosurePtr) = 0;
/** \brief emplaces the factor(s) corresponding to a Loop Closure between two captures
*/
virtual void emplaceFactors(CaptureBasePtr _capture_1, CaptureBasePtr _capture_2) = 0;
virtual void emplaceFactors(MatchLoopClosurePtr) = 0;
void processCapture(CaptureBasePtr) override;
void processKeyFrame(FrameBasePtr, const double&) override;
Loading