@@ -461,9 +461,6 @@ TYPED_TEST (SHOTShapeTest, Estimation)
461461 for (std::size_t i = 0 ; i < cloud.size (); i+=3 )
462462 test_indices->push_back (static_cast <int > (i));
463463
464- // testSHOTIndicesAndSearchSurface<SHOTEstimation<PointXYZ, Normal, SHOT>, PointXYZ, Normal, SHOT> (cloud.makeShared (), normals, test_indices);
465- // testSHOTLocalReferenceFrame<SHOTEstimation<PointXYZ, Normal, SHOT>, PointXYZ, Normal, SHOT> (cloud.makeShared (), normals, test_indices);
466-
467464 testSHOTIndicesAndSearchSurface<TypeParam, PointXYZ, Normal, SHOT352 > (cloud.makeShared (), normals, test_indices);
468465 testSHOTLocalReferenceFrame<TypeParam, PointXYZ, Normal, SHOT352 > (cloud.makeShared (), normals, test_indices);
469466}
@@ -670,9 +667,6 @@ TYPED_TEST (SHOTShapeAndColorTest, Estimation)
670667 for (std::size_t i = 0 ; i < cloud.size (); i+=3 )
671668 test_indices->push_back (static_cast <int > (i));
672669
673- // testSHOTIndicesAndSearchSurface<SHOTEstimation<PointXYZRGBA, Normal, SHOT>, PointXYZRGBA, Normal, SHOT> (cloudWithColors.makeShared (), normals, test_indices);
674- // testSHOTLocalReferenceFrame<SHOTEstimation<PointXYZRGBA, Normal, SHOT>, PointXYZRGBA, Normal, SHOT> (cloudWithColors.makeShared (), normals, test_indices);
675-
676670 testSHOTIndicesAndSearchSurface<TypeParam, PointXYZRGBA, Normal, SHOT1344 > (cloudWithColors.makeShared (), normals, test_indices);
677671 testSHOTLocalReferenceFrame<TypeParam, PointXYZRGBA, Normal, SHOT1344 > (cloudWithColors.makeShared (), normals, test_indices);
678672}
@@ -681,9 +675,6 @@ TYPED_TEST (SHOTShapeAndColorTest, Estimation)
681675TEST (PCL ,3DSCEstimation)
682676{
683677 float meshRes = 0 .002f ;
684- // size_t nBinsL = 4;
685- // size_t nBinsK = 4;
686- // size_t nBinsJ = 4;
687678 float radius = 20 .0f * meshRes;
688679 float rmin = radius / 10 .0f ;
689680 float ptDensityRad = radius / 5 .0f ;
@@ -705,9 +696,6 @@ TEST (PCL,3DSCEstimation)
705696 sc3d.setInputNormals (normals);
706697 sc3d.setSearchMethod (tree);
707698 sc3d.setRadiusSearch (radius);
708- // sc3d.setAzimuthBins (nBinsL);
709- // sc3d.setElevationBins (nBinsK);
710- // sc3d.setRadiusBins (nBinsJ);
711699 sc3d.setMinimalRadius (rmin);
712700 sc3d.setPointDensityRadius (ptDensityRad);
713701 // Compute the features
@@ -716,39 +704,37 @@ TEST (PCL,3DSCEstimation)
716704 EXPECT_EQ (sc3ds->size (), cloud.size ());
717705
718706 // 3DSC does not define a repeatable local RF, we set it to zero to signal it to the user
719- // EXPECT_NEAR ((*sc3ds)[0].rf[0], 0.2902f, 1e-4f);
720- // EXPECT_NEAR ((*sc3ds)[0].rf[1], 0.7334f, 1e-4f);
721- // EXPECT_NEAR ((*sc3ds)[0].rf[2], -0.6146f, 1e-4f);
722- // EXPECT_NEAR ((*sc3ds)[0].rf[3], 0.9486f, 1e-4f);
723- // EXPECT_NEAR ((*sc3ds)[0].rf[4], -0.3051f, 1e-4f);
724- // EXPECT_NEAR ((*sc3ds)[0].rf[5], 0.0838f, 1e-4f);
725- // EXPECT_NEAR ((*sc3ds)[0].rf[6], -0.1261f, 1e-4f);
726- // EXPECT_NEAR ((*sc3ds)[0].rf[7], -0.6074f, 1e-4f);
727- // EXPECT_NEAR ((*sc3ds)[0].rf[8], -0.7843f, 1e-4f);
728-
729- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [0 ], 0 .0f );
730- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [1 ], 0 .0f );
731- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [2 ], 0 .0f );
732- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [3 ], 0 .0f );
733- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [4 ], 0 .0f );
734- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [5 ], 0 .0f );
735- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [6 ], 0 .0f );
736- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [7 ], 0 .0f );
737- EXPECT_FLOAT_EQ ((*sc3ds)[0 ].rf [8 ], 0 .0f );
738-
739- // EXPECT_EQ ((*sc3ds)[0].descriptor.size (), 64);
740-
741- EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [88 ], 55 .271168f );
742- EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [584 ], 71 .108765f );
743- EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [1106 ], 79 .5896f );
707+ EXPECT_NEAR ((*sc3ds)[0 ].rf [0 ], -0 .932515f , 1e-4f );
708+ EXPECT_NEAR ((*sc3ds)[0 ].rf [1 ], 0 .342274f , 1e-4f );
709+ EXPECT_NEAR ((*sc3ds)[0 ].rf [2 ], -0 .115173f , 1e-4f );
710+ EXPECT_NEAR ((*sc3ds)[0 ].rf [3 ], 0 .33841f , 1e-4f );
711+ EXPECT_NEAR ((*sc3ds)[0 ].rf [4 ], 0 .716871f , 1e-4f );
712+ EXPECT_NEAR ((*sc3ds)[0 ].rf [5 ], -0 .60957f , 1e-4f );
713+ EXPECT_NEAR ((*sc3ds)[0 ].rf [6 ], -0 .126076f , 1e-4f );
714+ EXPECT_NEAR ((*sc3ds)[0 ].rf [7 ], -0 .607408f , 1e-4f );
715+ EXPECT_NEAR ((*sc3ds)[0 ].rf [8 ], -0 .784321f , 1e-4f );
716+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [54 ], 54 .0953f , 1e-4f );
717+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [71 ], 76 .176f , 1e-4f );
718+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [87 ], 64 .4415f , 1e-4f );
719+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [88 ], 110 .54235f , 1e-4f );
720+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [89 ], 55 .3068f , 1e-4f );
721+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [218 ], 126 .141f , 1e-4f );
722+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [235 ], 88 .8147f , 1e-4f );
723+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [237 ], 43 .5572f , 1e-4f );
724+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [238 ], 56 .0383f , 1e-4f );
725+ EXPECT_NEAR ((*sc3ds)[108 ].descriptor [253 ], 36 .8475f , 1e-4f );
726+
727+ EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [88 ], 27 .635588f );
728+ EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [584 ], 47 .405849f );
729+ EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [1106 ], 39 .794807f );
744730 EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [1560 ], 0 .f );
745731 EXPECT_FLOAT_EQ ((*sc3ds)[94 ].descriptor [1929 ], 36 .063553f );
746732
747- EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [67 ], 0 .f );
748- EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [548 ], 126 . 14106f );
749- EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1091 ], 30 . 470392f );
750- EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1421 ], 38 . 08799f );
751- EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1900 ], 43 . 799442f );
733+ EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [67 ], 0 .f );
734+ EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [548 ], 0 . f );
735+ EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1091 ], 0 . f );
736+ EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1421 ], 0 . f );
737+ EXPECT_FLOAT_EQ ((*sc3ds)[108 ].descriptor [1900 ], 0 . f );
752738
753739 // Test results when setIndices and/or setSearchSurface are used
754740 pcl::IndicesPtr test_indices (new pcl::Indices (0 ));
@@ -789,8 +775,6 @@ TEST (PCL, USCEstimation)
789775 EXPECT_NEAR ((*uscds)[160 ].rf [7 ], 0 .105428f , 1e-4f );
790776 EXPECT_NEAR ((*uscds)[160 ].rf [8 ], -0 .972049f , 1e-4f );
791777
792- // EXPECT_EQ ((*uscds)[0].descriptor.size (), 64);
793-
794778 EXPECT_NEAR ((*uscds)[160 ].descriptor [355 ], 123 .0733f , 1e-4f );
795779 EXPECT_NEAR ((*uscds)[160 ].descriptor [494 ], 154 .9401f , 1e-4f );
796780 EXPECT_NEAR ((*uscds)[160 ].descriptor [897 ], 0 .f , 1e-4f );
@@ -839,4 +823,4 @@ main (int argc, char** argv)
839823 testing::InitGoogleTest (&argc, argv);
840824 return (RUN_ALL_TESTS ());
841825}
842- /* ]--- */
826+ /* ]--- */
0 commit comments