Fix NaN that appears in RunningStatistics::meanlogs
Fix NaN that appears in RunningStatistics::meanlogs

When value == 0, std::log(std::abs(value)) = -inf. It is ok. Hovewer, when the second 0 is added we end up with (-inf) - (-inf) which is NaN. A histogram that is build in such way will fail to be uploaded, since the dashboard can't handle NaN in json (since it uses ijson library).

In Python code it is handled properly (the condition there is "value <= 0").

Bug: chromium:1153044
Change-Id: If4463c2f3543a65c4aa2e2770734ca6c8b556496
Reviewed-on: https://chromium-review.googlesource.com/c/catapult/+/2560724
Commit-Queue: Andrey Logvin <d1a9cba877864cffb2bba2f18040e3a770e73eed@google.com>
Reviewed-by: Dean Berris <34a37f59e4ade3cf49221306f04217acf3e86255@chromium.org>
Reviewed-by: Mirko Bonadei <d2c43c210eae6feef04f53bae50885e8152edcca@chromium.org>
Auto-Submit: Andrey Logvin <d1a9cba877864cffb2bba2f18040e3a770e73eed@google.com>

catapult-project/catapult,catapult-project/catapult,catapult-project/catapult,catapult-project/catapult,catapult-project/catapult,catapult-project/catapult,catapult-project/catapult