`1.0 * x` == `x` and `log2(1.0 / len_upper)` == `-log2(len_upper)` so `... + 1.0 * log2(1.0 / len_upper) + ...` can be simplified to `... - log2(len_upper) + ...`