Tests: look at worst case, not at mean relative difference
Currently all tests that check a simulated Datafield against a reference seem to use DiffUtil::checkRelativeDifference
, which looks at the mean relative difference.
Instead, we should look at the worst data bin. For two reasons:
- Fundamentally, we want each single computation to be correct.
- We then could make error reports more specific, which in turn might elp in debugging.
But there is also a good reason for the current solution, namely that we should not be overly concerned about relative differences in bins that have very low absolute intensity (relative to high-intensity bins of course). Therefore we first need to invent a reasonable measure for worst-case deviations.
Probably we should wait with this until #952 (closed) (discrepancies under various architectures) is resolved so that it does not become a work against a moving target.