The issue was that the end point would be extrapolated and it would lead to very high values if the curve had a near inf slope. Now we use the actual end point value and only extrapolate values that are outside of the start and endpoint range. Differential Revision: https://developer.blender.org/D5151