From 7e8176a71873bb5012fec3c8c9c2b8d0a59ecfe4 Mon Sep 17 00:00:00 2001 From: ychen837 <55328878+ychen837@users.noreply.github.com> Date: Thu, 26 Mar 2020 22:10:32 -0700 Subject: [PATCH] Updated importing spline from scipy.interpolate import spline wasn't working properly in my case, from scipy.interpolate import make_interp_spline was suggested online. --- autonomous_vehicle.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/autonomous_vehicle.py b/autonomous_vehicle.py index a40f933..9178b08 100755 --- a/autonomous_vehicle.py +++ b/autonomous_vehicle.py @@ -7,7 +7,8 @@ from loss_functions import LossFunctions from scipy import optimize import pygame as pg -from scipy.interpolate import spline +#from scipy.interpolate import spline +from scipy.interpolate import make_interp_spline #updated by Yi from scipy import stats import time import matplotlib.pyplot as plt @@ -1062,4 +1063,4 @@ def dynamic(self, action_self): # Dynamic of cubic polynomial on velocity A[np.tril_indices(N, 0)] = 1 predict_result_traj = np.matmul(A, predict_result_vel) + state_0 - return predict_result_traj \ No newline at end of file + return predict_result_traj