Skip to content

Commit

Permalink
[MINOR] Error from testUtils do not write more than the first 10 errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
Baunsgaard committed Apr 24, 2023
1 parent e11d20a commit 06886ec
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/test/java/org/apache/sysds/test/TestUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -1569,10 +1569,12 @@ public static boolean compareMatrices(HashMap<CellIndex, Double> m1, HashMap<Cel
if (!compareCellValue(v1, v2, 0, ignoreNaN)) {
if (!compareCellValue(v1, v2, tolerance, ignoreNaN)) {
countErrorWithinTolerance++;
if(!flag)
LOG.error(e.getKey() + ": " + v1 + " <--> " + v2);
else
LOG.error(e.getKey() + ": " + v2 + " <--> " + v1);
if(countErrorWithinTolerance < 10){
if(!flag)
LOG.error(e.getKey() + ": " + v1 + " <--> " + v2);
else
LOG.error(e.getKey() + ": " + v2 + " <--> " + v1);
}

}
} else {
Expand Down

0 comments on commit 06886ec

Please sign in to comment.