Commit 958604a6 authored by Alexander Alekhin's avatar Alexander Alekhin

perf test: update error message about relative error

parent e35bc115
......@@ -476,6 +476,9 @@ void Regression::verify(cv::FileNode node, cv::InputArray array, double eps, ERR
int violations = countViolations(expected, actual, diff, eps, &maxv, &maxa);
if (violations > 0)
{
if(expected.total() * expected.channels() < 12)
std::cout << " Expected: " << std::endl << expected << std::endl << " Actual:" << std::endl << actual << std::endl;
FAIL() << " Relative difference (" << maxv << " of " << maxa << " allowed) between argument \""
<< node.name() << "[" << idx << "]\" and expected value is greater than " << eps << " in " << violations << " points";
}
......@@ -530,6 +533,9 @@ void Regression::verify(cv::FileNode node, cv::InputArray array, double eps, ERR
int violations = countViolations(expected, actual, diff, eps, &maxv, &maxa);
if (violations > 0)
{
if(expected.total() * expected.channels() < 12)
std::cout << " Expected: " << std::endl << expected << std::endl << " Actual:" << std::endl << actual << std::endl;
FAIL() << " Relative difference (" << maxv << " of " << maxa << " allowed) between argument \"" << node.name()
<< "\" and expected value is greater than " << eps << " in " << violations << " points";
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment