diff --git a/test/gtest_processor_landmark_external.cpp b/test/gtest_processor_landmark_external.cpp index 3fe0eeef4e0ce85bbae13105bf55fe11cb324482..c160058101ad934f5c977a2b214d82a57ce7b01e 100644 --- a/test/gtest_processor_landmark_external.cpp +++ b/test/gtest_processor_landmark_external.cpp @@ -94,9 +94,9 @@ void ProcessorLandmarkExternalTest::initProblem(int _dim, bool _init_landmarks) { // INCOMPATIBLE OPTIONS - if (_init_landmarks and mode == 2) + if (_init_landmarks and _mode == 2) throw std::runtime_error("Landmarks initialized with mode 2 (no id no type), impossible to close loops"); - if (_init_landmarks and mode == 4) + if (_init_landmarks and _mode == 4) throw std::runtime_error("Landmarks initialized with mode 4 (changing), impossible to close loops"); dim = _dim; @@ -178,13 +178,13 @@ void ProcessorLandmarkExternalTest::initProblem(int _dim, // Emplace 3 random landmarks for (auto i = 0; i < 3; i++) { - bool init_landmark = _init_landmarks and mode != 3 and i % 3 != 2; + bool init_landmark = _init_landmarks and mode != 3 and i % 3 != 2; LandmarkExternalPtr lmk; if (dim == 2) lmk = LandmarkBase::emplace<LandmarkExternal>( init_landmark ? problem->getMap() : nullptr, i + 1, - 3*i + 10, + 3 * i + 10, std::make_shared<StatePoint2d>(Vector2d::Random() * 10), (orientation ? std::make_shared<StateAngle>(Vector1d::Random() * M_PI) : nullptr)); @@ -192,7 +192,7 @@ void ProcessorLandmarkExternalTest::initProblem(int _dim, lmk = LandmarkBase::emplace<LandmarkExternal>( init_landmark ? problem->getMap() : nullptr, i + 1, - 3*i + 10, + 3 * i + 10, std::make_shared<StatePoint3d>(Vector3d::Random() * 10), (orientation ? std::make_shared<StateQuaternion>(Vector4d::Random().normalized()) : nullptr)); landmarks.push_back(lmk); @@ -385,8 +385,12 @@ void ProcessorLandmarkExternalTest::testConfiguration(int _dim, for (auto lmk_map : landmarks_map) { auto lmk_ext = std::static_pointer_cast<LandmarkExternal>(lmk_map); - ASSERT_EQ(lmk_ext->getExternalId(), landmarks.at(lmk_ext->getExternalId() - 1)->getExternalId()); - assertVectorComposite(lmk_map->getState(), state_landmarks.at(lmk_ext->getExternalId() - 1)); + if (lmk_ext->getExternalId() != -1) + { + ASSERT_EQ(lmk_ext->getExternalId(), + landmarks.at(lmk_ext->getExternalId() - 1)->getExternalId()); + assertVectorComposite(lmk_map->getState(), state_landmarks.at(lmk_ext->getExternalId() - 1)); + } } } } @@ -449,14 +453,16 @@ void ProcessorLandmarkExternalTest::assertVectorComposite(const VectorComposite& throw std::runtime_error("wrong vector composite"); } -// / TESTS ////////////////////////////////////////// +/// TESTS ////////////////////////////////////////// + +//-------------------- Position in 2D -------------------- TEST_F(ProcessorLandmarkExternalTest, P_2d_loop_closure_id) { testConfiguration(2, // int dim false, // bool orientation 0, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 6, // int track_length 4.5 * dt, // double time_span true); // bool init_landmarks & loop closure @@ -468,7 +474,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_loop_closure_type) false, // bool orientation 1, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 6, // int track_length 4.5 * dt, // double time_span true); // bool init_landmarks & loop closure @@ -480,7 +486,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_loop_closure_mixed) false, // bool orientation 3, // int mode 0, // double quality_th - 1e-2, // double dist_th + 1e-2, // double dist_th 6, // int track_length 4.5 * dt, // double time_span true); // bool init_landmarks & loop closure @@ -492,7 +498,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_id) false, // bool orientation 0, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 2, // int track_length 4.5 * dt, // double time_span false); // bool init_landmarks & loop closure @@ -504,7 +510,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_type) false, // bool orientation 1, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 2, // int track_length 4.5 * dt, // double time_span false); // bool init_landmarks & loop closure @@ -516,7 +522,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_nothing) false, // bool orientation 2, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 2, // int track_length 4.5 * dt, // double time_span false); // bool init_landmarks & loop closure @@ -528,7 +534,7 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_mixed) false, // bool orientation 3, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 2, // int track_length 4.5 * dt, // double time_span false); // bool init_landmarks & loop closure @@ -540,455 +546,542 @@ TEST_F(ProcessorLandmarkExternalTest, P_2d_changing) false, // bool orientation 4, // int mode 0, // double quality_th - 1e6, // double dist_th + 1e-2, // double dist_th 2, // int track_length 4.5 * dt, // double time_span false); // bool init_landmarks & loop closure } -// TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_id) -// { -// testConfiguration(2, // int dim -// false, // bool orientation -// 0, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 6, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_type) -// { -// testConfiguration(2, // int dim -// false, // bool orientation -// 1, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 6, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_nothing) -// { -// testConfiguration(2, // int dim -// false, // bool orientation -// 2, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 6, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_mixed) -// { -// testConfiguration(2, // int dim -// false, // bool orientation -// 3, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 6, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_id) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 3, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_type) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 3, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_mixed) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 3, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_id) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_type) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_nothing) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 2, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_mixed) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_id) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 0, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 0, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_type) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 1, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 0, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_nothing) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 2, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 0, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_mixed) -// { -// testConfiguration(2, // int dim -// true, // bool orientation -// 3, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 0, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_id) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 7, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_type) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 7, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_mixed) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 7, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_id) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 53, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_type) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 53, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_nothing) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 2, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 53, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_mixed) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 53, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_id) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 0, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 2, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_type) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 1, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 2, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_nothing) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 2, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 2, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_mixed) -// { -// testConfiguration(3, // int dim -// false, // bool orientation -// 3, // int mode -// 0.3, // double quality_th -// 1e6, // double dist_th -// 2, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_id) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_type) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_mixed) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 1, // int track_length -// 4.5 * dt, // double time_span -// true); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_id) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 0, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 4, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_type) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 1, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 4, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_nothing) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 2, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 4, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_mixed) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 3, // int mode -// 0, // double quality_th -// 1e6, // double dist_th -// 4, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_id) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 0, // int mode -// 0.2, // double quality_th -// 1e6, // double dist_th -// 5, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_type) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 1, // int mode -// 0.2, // double quality_th -// 1e6, // double dist_th -// 5, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_nothing) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 2, // int mode -// 0.2, // double quality_th -// 1e6, // double dist_th -// 5, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } - -// TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_mixed) -// { -// testConfiguration(3, // int dim -// true, // bool orientation -// 3, // int mode -// 0.2, // double quality_th -// 1e6, // double dist_th -// 5, // int track_length -// 4.5 * dt, // double time_span -// false); // bool init_landmarks & loop closure -// } +TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_id) +{ + testConfiguration(2, // int dim + false, // bool orientation + 0, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_type) +{ + testConfiguration(2, // int dim + false, // bool orientation + 1, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_nothing) +{ + testConfiguration(2, // int dim + false, // bool orientation + 2, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_mixed) +{ + testConfiguration(2, // int dim + false, // bool orientation + 3, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_2d_quality_changing) +{ + testConfiguration(2, // int dim + false, // bool orientation + 4, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +//-------------------- Position & Orientation in 2D -------------------- +TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_id) +{ + testConfiguration(2, // int dim + true, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_type) +{ + testConfiguration(2, // int dim + true, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_loop_closure_mixed) +{ + testConfiguration(2, // int dim + true, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_id) +{ + testConfiguration(2, // int dim + true, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_type) +{ + testConfiguration(2, // int dim + true, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_nothing) +{ + testConfiguration(2, // int dim + true, // bool orientation + 2, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_mixed) +{ + testConfiguration(2, // int dim + true, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_changing) +{ + testConfiguration(2, // int dim + true, // bool orientation + 4, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_id) +{ + testConfiguration(2, // int dim + true, // bool orientation + 0, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_type) +{ + testConfiguration(2, // int dim + true, // bool orientation + 1, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_nothing) +{ + testConfiguration(2, // int dim + true, // bool orientation + 2, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_mixed) +{ + testConfiguration(2, // int dim + true, // bool orientation + 3, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_2d_quality_changing) +{ + testConfiguration(2, // int dim + true, // bool orientation + 4, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +//-------------------- Position in 3D -------------------- +TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_id) +{ + testConfiguration(3, // int dim + false, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_type) +{ + testConfiguration(3, // int dim + false, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_loop_closure_mixed) +{ + testConfiguration(3, // int dim + false, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_id) +{ + testConfiguration(3, // int dim + false, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_type) +{ + testConfiguration(3, // int dim + false, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_nothing) +{ + testConfiguration(3, // int dim + false, // bool orientation + 2, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_mixed) +{ + testConfiguration(3, // int dim + false, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_changing) +{ + testConfiguration(3, // int dim + false, // bool orientation + 4, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_id) +{ + testConfiguration(3, // int dim + false, // bool orientation + 0, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_type) +{ + testConfiguration(3, // int dim + false, // bool orientation + 1, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_nothing) +{ + testConfiguration(3, // int dim + false, // bool orientation + 2, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_mixed) +{ + testConfiguration(3, // int dim + false, // bool orientation + 3, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, P_3d_quality_changing) +{ + testConfiguration(3, // int dim + false, // bool orientation + 4, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +//-------------------- Position & Orientation in 3D -------------------- +TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_id) +{ + testConfiguration(3, // int dim + true, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_type) +{ + testConfiguration(3, // int dim + true, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_loop_closure_mixed) +{ + testConfiguration(3, // int dim + true, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + true); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_id) +{ + testConfiguration(3, // int dim + true, // bool orientation + 0, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_type) +{ + testConfiguration(3, // int dim + true, // bool orientation + 1, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_nothing) +{ + testConfiguration(3, // int dim + true, // bool orientation + 2, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_mixed) +{ + testConfiguration(3, // int dim + true, // bool orientation + 3, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_changing) +{ + testConfiguration(3, // int dim + true, // bool orientation + 4, // int mode + 0, // double quality_th + 1e-2, // double dist_th + 2, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_id) +{ + testConfiguration(3, // int dim + true, // bool orientation + 0, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_type) +{ + testConfiguration(3, // int dim + true, // bool orientation + 1, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_nothing) +{ + testConfiguration(3, // int dim + true, // bool orientation + 2, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_mixed) +{ + testConfiguration(3, // int dim + true, // bool orientation + 3, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} + +TEST_F(ProcessorLandmarkExternalTest, PO_3d_quality_changing) +{ + testConfiguration(3, // int dim + true, // bool orientation + 4, // int mode + 0.3, // double quality_th + 1e-2, // double dist_th + 6, // int track_length + 4.5 * dt, // double time_span + false); // bool init_landmarks & loop closure +} int main(int argc, char** argv) {