The function `cdf_invert` was not doing linear interpolation between the correct values. This fixes the issue and make sure that `x` is never perfectly 0 nor 1. Fixes #117755
The function `cdf_invert` was not doing linear interpolation between the correct values. This fixes the issue and make sure that `x` is never perfectly 0 nor 1. Fixes #117755