Switch from scipy.integrate.Inf to numpy.Inf for better scipy version compatibility