get_smooth_path.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:Mobile_Robotics_Platform 作者: Ridhwanluthra 项目源码 文件源码
def interpolate_path(list_of_xys):
    x = list_of_xys[0]
    y = list_of_xys[1]
    #print x, y

    #x = np.array([0,1,2,3,4,5,6,7,6,5,4,3,2,1,0])
    #y = np.array([0,1,2,3,4,4,5,6,7,8,7,8,9,9,9])

    tck, u = interpolate.splprep([x, y], s = 0.03)
    unew = np.arange(0,9,0.03)
    #print unew
    interpolated_path = interpolate.splev(unew, tck, ext = 1)
    return interpolated_path

#a = interpolate_path(array)
#plot_path(array, a)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号