MCPcopy Create free account
hub / github.com/AutonomousFieldRoboticsLab/SVIn / setup

Method setup

pose_graph/src/pose_graph/LoopClosure.cpp:32–55  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30}
31
32void LoopClosure::setup() {
33 pose_graph_ = std::unique_ptr<PoseGraph>(new PoseGraph());
34
35 pose_graph_->set_fast_relocalization(params_.fast_relocalization_);
36
37 if (params_.global_mapping_params_.enabled) {
38 global_map_ = std::unique_ptr<GlobalMap>(new GlobalMap());
39 pose_graph_->setLoopClosureOptimizationCallback(
40 std::bind(&GlobalMap::loopClosureOptimizationFinishCallback, global_map_.get(), std::placeholders::_1));
41 }
42
43 if (params_.health_params_.enabled) {
44 switching_estimator_ = std::unique_ptr<SwitchingEstimator>(new SwitchingEstimator(params_));
45 }
46
47 pose_graph_->startOptimizationThread();
48
49 // Loading vocabulary
50 voc_ = new BriefVocabulary(params_.vocabulary_file_);
51 BriefDatabase db;
52 db.setVocabulary(*voc_, false, 0);
53 LOG(INFO) << "Vocabulary loaded!";
54 pose_graph_->setBriefVocAndDB(voc_, db);
55}
56
57void LoopClosure::run() {
58 while (!shutdown_) {

Callers

nothing calls this directly

Calls 6

getMethod · 0.80
setVocabularyMethod · 0.80
setBriefVocAndDBMethod · 0.80

Tested by

no test coverage detected