7.50000000e+00, 9.37999977e-01, -7.66584515e-03],
[ 1.00000000e+01, -5.44021111e-01, -4.24650123e-02]])
如果我想使用scipy.interpolate.interp1d...我想避免这种重复的方法:
In [7]: import scipy.interpolate as interpolate
In [8]: new_x = np.linspace(0,10,20)
In...02]])
我没有弄清楚使用np.vstack或np.hstack将new_x和内插数据合并在一行中的语法,但是这个post让我停止尝试,因为似乎更快地预分配了数组(例如,使用np.zeros)然后用新值填充它...标签:scipy,python,numpy,interpolation
来源: https://codeday.me/bug/20191120/2044846.html
发布者:全栈程序员栈长,转载请注明出处