From 695fbd65c397ba6f9eedda03bc51379f506e7e5d Mon Sep 17 00:00:00 2001 From: Ian Chen Date: Sat, 13 Mar 2021 01:09:27 -0800 Subject: [PATCH 1/2] fixing test Signed-off-by: Ian Chen --- test/integration/render_pass.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/test/integration/render_pass.cc b/test/integration/render_pass.cc index 17659a3e3..cb7d36dc2 100644 --- a/test/integration/render_pass.cc +++ b/test/integration/render_pass.cc @@ -310,8 +310,8 @@ void RenderPassTest::DepthGaussianNoise(const std::string &_renderEngine) float maxVal = ignition::math::INF_D; - // values should be well within 4-sigma - float noiseTol = 4.0*noiseStdDev; + // values should be well within 3-sigma + float noiseTol = 3.0*noiseStdDev; unsigned int colorNoiseTol = static_cast(255.0*noiseTol); // Verify Point Cloud XYZ values @@ -339,8 +339,9 @@ void RenderPassTest::DepthGaussianNoise(const std::string &_renderEngine) float mz = pointCloudData[pcMid + 2]; float midLeftZ = pointCloudData[pcMid + 2 - pointCloudChannelCount]; float midRightZ = pointCloudData[pcMid + 2 + pointCloudChannelCount]; - EXPECT_NEAR(mz, midLeftZ, noiseTol); - EXPECT_NEAR(mz, midRightZ, noiseTol); + // 2 noisy values should be within 2 * 3 sigma + EXPECT_NEAR(mz, midLeftZ, 2*noiseTol); + EXPECT_NEAR(mz, midRightZ, 2*noiseTol); // Verify Point Cloud RGB values // The mid point should be blue From 897f31122f8251c4b0e616d78b020caf22018d3f Mon Sep 17 00:00:00 2001 From: Ian Chen Date: Mon, 15 Mar 2021 21:17:36 -0700 Subject: [PATCH 2/2] relax check Signed-off-by: Ian Chen --- test/integration/render_pass.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/integration/render_pass.cc b/test/integration/render_pass.cc index cb7d36dc2..a5cc16dd8 100644 --- a/test/integration/render_pass.cc +++ b/test/integration/render_pass.cc @@ -310,8 +310,8 @@ void RenderPassTest::DepthGaussianNoise(const std::string &_renderEngine) float maxVal = ignition::math::INF_D; - // values should be well within 3-sigma - float noiseTol = 3.0*noiseStdDev; + // values should be well within 4-sigma + float noiseTol = 4.0*noiseStdDev; unsigned int colorNoiseTol = static_cast(255.0*noiseTol); // Verify Point Cloud XYZ values @@ -339,7 +339,7 @@ void RenderPassTest::DepthGaussianNoise(const std::string &_renderEngine) float mz = pointCloudData[pcMid + 2]; float midLeftZ = pointCloudData[pcMid + 2 - pointCloudChannelCount]; float midRightZ = pointCloudData[pcMid + 2 + pointCloudChannelCount]; - // 2 noisy values should be within 2 * 3 sigma + // 2 noisy values should be within 2 * 4 sigma EXPECT_NEAR(mz, midLeftZ, 2*noiseTol); EXPECT_NEAR(mz, midRightZ, 2*noiseTol);