Skip to content
Snippets Groups Projects
Commit 5c065da6 authored by Sergi Pujol's avatar Sergi Pujol
Browse files

corner_scene.h deleted and substituted by scene_falko and scene_base

parent 58109c7d
No related branches found
No related tags found
1 merge request!4Resolve "Implementation of Falko lib"
This commit is part of merge request !4. Comments created here will be created in the context of that merge request.
...@@ -69,7 +69,6 @@ SET(HDRS ...@@ -69,7 +69,6 @@ SET(HDRS
SET(HDRS ${HDRS} SET(HDRS ${HDRS}
corner_falko_2d.h corner_falko_2d.h
loop_closure_falko.h loop_closure_falko.h
corner_scene.h
scene_falko.h) scene_falko.h)
ENDIF(falkolib_FOUND) ENDIF(falkolib_FOUND)
......
/**
* \file corner_scene.h
*
* Created on: Feb 9, 2021
* \author: spujol
*/
#ifndef CORNER_SCENE_H_
#define CORNER_SCENE_H_
#include <iostream>
#include <fstream>
/**************************
* Falko includes *
**************************/
#include <falkolib/Feature/FALKO.h>
#include <falkolib/Feature/CGH.h>
#include <falkolib/Feature/BSC.h>
#include <falkolib/Feature/FALKOExtractor.h>
#include <falkolib/Feature/BSCExtractor.h>
#include <falkolib/Feature/CGHExtractor.h>
#include <falkolib/Matching/NNMatcher.h>
#include <falkolib/Matching/AHTMatcher.h>
namespace laserscanutils
{
template <typename D>
struct cornerScene{
std::vector<falkolib::FALKO> keypointsList;
std::vector<D> descriptorsList;
};
typedef std::shared_ptr<cornerScene<falkolib::BSC>> cornerSceneBSCPtr;
} /* namespace laserscanutils */
#endif /* CORNER_SCENE_H_ */
...@@ -16,7 +16,6 @@ ...@@ -16,7 +16,6 @@
* laser_scan_utils includes * * laser_scan_utils includes *
**************************/ **************************/
#include "laser_scan.h" #include "laser_scan.h"
#include "corner_scene.h"
#include "scene_base.h" #include "scene_base.h"
/************************** /**************************
......
...@@ -37,8 +37,8 @@ namespace laserscanutils{ ...@@ -37,8 +37,8 @@ namespace laserscanutils{
loopClosureFalko<D,Extr,M>::~loopClosureFalko(){} loopClosureFalko<D,Extr,M>::~loopClosureFalko(){}
template <typename D,typename Extr, typename M> template <typename D,typename Extr, typename M>
std::shared_ptr<cornerScene<D>> loopClosureFalko<D,Extr, M>::extractScene(LaserScan &scan,LaserScanParams &scanParams){ std::shared_ptr<sceneFalko<D>> loopClosureFalko<D,Extr, M>::extractScene(LaserScan &scan,LaserScanParams &scanParams){
auto newScene=std::make_shared<cornerScene<D>>(); auto newScene=std::make_shared<sceneFalko<D>>();
auto scanFALKO =loopClosureFalko<D,Extr,M>::convert2LaserScanFALKO(scan, scanParams); auto scanFALKO =loopClosureFalko<D,Extr,M>::convert2LaserScanFALKO(scan, scanParams);
// Extract keypoints // Extract keypoints
extract((*scanFALKO), (newScene->keypointsList)); extract((*scanFALKO), (newScene->keypointsList));
...@@ -49,7 +49,7 @@ namespace laserscanutils{ ...@@ -49,7 +49,7 @@ namespace laserscanutils{
} }
//void findLoopClosure(std::list<cornerScene>& scenes, const cornerScene newScene){} //void findLoopClosure(std::list<sceneFalko>& scenes, const cornerScene newScene){}
//Explicitly compile all the templates //Explicitly compile all the templates
template class loopClosureFalko <bsc, bscExtractor, NNMatcher>; template class loopClosureFalko <bsc, bscExtractor, NNMatcher>;
......
...@@ -16,7 +16,6 @@ ...@@ -16,7 +16,6 @@
* laser_scan_utils includes * * laser_scan_utils includes *
**************************/ **************************/
#include "laser_scan.h" #include "laser_scan.h"
#include "corner_scene.h"
#include "scene_falko.h" #include "scene_falko.h"
#include "loop_closure_base_2d.h" #include "loop_closure_base_2d.h"
...@@ -64,11 +63,11 @@ public: ...@@ -64,11 +63,11 @@ public:
/** \brief compare new scans against the trained set in order to find loop closures /** \brief compare new scans against the trained set in order to find loop closures
**/ **/
//void findLoopClosure(std::list<cornerScene>& scenes, const cornerScene newScene){} //void findLoopClosure(std::list<sceneFalko>& scenes, const cornerScene newScene){}
/** \brief update the scene struct with keypoints and descriptors /** \brief update the scene struct with keypoints and descriptors
**/ **/
std::shared_ptr<cornerScene<D>> extractScene(LaserScan &scan,LaserScanParams &scanParams); std::shared_ptr<sceneFalko<D>> extractScene(LaserScan &scan,LaserScanParams &scanParams);
}; };
......
...@@ -40,7 +40,7 @@ struct sceneFalko : sceneBase{ ...@@ -40,7 +40,7 @@ struct sceneFalko : sceneBase{
std::vector<D> descriptorsList; std::vector<D> descriptorsList;
}; };
typedef std::shared_ptr<cornerScene<falkolib::BSC>> sceneFalkoBSCPtr; typedef std::shared_ptr<sceneFalko<falkolib::BSC>> sceneFalkoBSCPtr;
} /* namespace laserscanutils */ } /* namespace laserscanutils */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment