remove all dependency

This commit is contained in:
Atsushi Sakai
2018-02-11 10:41:31 -08:00
parent 0a42ae7b9d
commit 4a8be2705e
6 changed files with 22 additions and 23 deletions

12
.gitmodules vendored
View File

@@ -1,12 +0,0 @@
[submodule "PathTracking/rear_wheel_feedback/pycubicspline"]
path = PathTracking/rear_wheel_feedback/pycubicspline
url = https://github.com/AtsushiSakai/pycubicspline.git
[submodule "PathTracking/stanley_controller/pycubicspline"]
path = PathTracking/stanley_controller/pycubicspline
url = https://github.com/AtsushiSakai/pycubicspline
[submodule "PathTracking/lqr_speed_steer_control/pycubicspline"]
path = PathTracking/lqr_speed_steer_control/pycubicspline
url = https://github.com/AtsushiSakai/pycubicspline
[submodule "PathTracking/model_predictive_speed_and_steer_control/pycubicspline"]
path = PathTracking/model_predictive_speed_and_steer_control/pycubicspline
url = https://github.com/AtsushiSakai/pycubicspline

View File

@@ -5,12 +5,14 @@ Path tracking simulation with iterative linear model predictive control for spee
author: Atsushi Sakai (@Atsushi_twi)
"""
import sys
sys.path.append("../../PathPlanning/CubicSpline/")
import numpy as np
import math
import cvxpy
import matplotlib.pyplot as plt
from pycubicspline import pycubicspline
import cubic_spline_planner
NX = 4 # x = x, y, v, yaw
NU = 2 # a = [accel, steer]
@@ -482,7 +484,8 @@ def smooth_yaw(yaw):
def get_forward_course(dl):
ax = [0.0, 60.0, 125.0, 50.0, 75.0, 30.0, -10.0]
ay = [0.0, 0.0, 50.0, 65.0, 30.0, 50.0, -20.0]
cx, cy, cyaw, ck, s = pycubicspline.calc_spline_course(ax, ay, ds=dl)
cx, cy, cyaw, ck, s = cubic_spline_planner.calc_spline_course(
ax, ay, ds=dl)
return cx, cy, cyaw, ck
@@ -490,10 +493,12 @@ def get_forward_course(dl):
def get_switch_back_course(dl):
ax = [0.0, 30.0, 6.0, 20.0, 35.0]
ay = [0.0, 0.0, 20.0, 35.0, 20.0]
cx, cy, cyaw, ck, s = pycubicspline.calc_spline_course(ax, ay, ds=dl)
cx, cy, cyaw, ck, s = cubic_spline_planner.calc_spline_course(
ax, ay, ds=dl)
ax = [35.0, 10.0, 0.0, 0.0]
ay = [20.0, 30.0, 5.0, 0.0]
cx2, cy2, cyaw2, ck2, s2 = pycubicspline.calc_spline_course(ax, ay, ds=dl)
cx2, cy2, cyaw2, ck2, s2 = cubic_spline_planner.calc_spline_course(
ax, ay, ds=dl)
cyaw2 = [i - math.pi for i in cyaw2]
cx.extend(cx2)
cy.extend(cy2)

View File

@@ -5,9 +5,13 @@ Path tracking simulation with rear wheel feedback steering control and PID speed
author: Atsushi Sakai(@Atsushi_twi)
"""
import sys
sys.path.append("../../PathPlanning/CubicSpline/")
import math
import matplotlib.pyplot as plt
from pycubicspline import pycubicspline
import cubic_spline_planner
Kp = 1.0 # speed propotional gain
# steering control parameter
@@ -188,7 +192,8 @@ def main():
ay = [0.0, 0.0, 5.0, 6.5, 3.0, 5.0, -2.0]
goal = [ax[-1], ay[-1]]
cx, cy, cyaw, ck, s = pycubicspline.calc_spline_course(ax, ay, ds=0.1)
cx, cy, cyaw, ck, s = cubic_spline_planner.calc_spline_course(
ax, ay, ds=0.1)
target_speed = 10.0 / 3.6
sp = calc_speed_profile(cx, cy, cyaw, target_speed)

View File

@@ -5,10 +5,12 @@ Path tracking simulation with Stanley steering control and PID speed control.
author: Atsushi Sakai (@Atsushi_twi)
"""
import sys
sys.path.append("../../PathPlanning/CubicSpline/")
import math
import matplotlib.pyplot as plt
from pycubicspline import pycubicspline
import cubic_spline_planner
k = 0.5 # control gain
@@ -100,7 +102,8 @@ def main():
ax = [0.0, 100.0, 100.0, 50.0, 60.0]
ay = [0.0, 0.0, -30.0, -20.0, 0.0]
cx, cy, cyaw, ck, s = pycubicspline.calc_spline_course(ax, ay, ds=0.1)
cx, cy, cyaw, ck, s = cubic_spline_planner.calc_spline_course(
ax, ay, ds=0.1)
target_speed = 30.0 / 3.6 # [m/s]