BUG fixed: Bad check in histogram pre-computation