Skip to content

Commit fe4ce92

Browse files
authored
Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart (AtsushiSakai#516)
* Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart * Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart * Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart * Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart * Fix No module error in GridBasedSweepCPP and ClosedLoopRRTStart
1 parent a0db9d2 commit fe4ce92

File tree

4 files changed

+25
-18
lines changed

4 files changed

+25
-18
lines changed

PathPlanning/ClosedLoopRRTStar/__init__.py

Lines changed: 0 additions & 8 deletions
This file was deleted.

PathPlanning/ClosedLoopRRTStar/closed_loop_rrt_star_car.py

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,28 @@
55
author: AtsushiSakai(@Atsushi_twi)
66
77
"""
8+
import os
9+
import sys
810

911
import matplotlib.pyplot as plt
1012
import numpy as np
11-
import reeds_shepp_path_planning
12-
from rrt_star_reeds_shepp import RRTStarReedsShepp
13+
14+
sys.path.append(os.path.dirname(os.path.abspath(__file__)))
1315

1416
import pure_pursuit
1517
import unicycle_model
1618

19+
sys.path.append(os.path.dirname(
20+
os.path.abspath(__file__)) + "/../ReedsSheppPath/")
21+
sys.path.append(os.path.dirname(
22+
os.path.abspath(__file__)) + "/../RRTStarReedsShepp/")
23+
24+
try:
25+
import reeds_shepp_path_planning
26+
from rrt_star_reeds_shepp import RRTStarReedsShepp
27+
except ImportError:
28+
raise
29+
1730
show_animation = True
1831

1932

PathPlanning/GridBasedSweepCPP/__init__.py

Lines changed: 0 additions & 7 deletions
This file was deleted.

PathPlanning/GridBasedSweepCPP/grid_based_sweep_coverage_path_planner.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,22 @@
55
"""
66

77
import math
8+
import os
9+
import sys
810
from enum import IntEnum
911

1012
import numpy as np
1113
from scipy.spatial.transform import Rotation as Rot
12-
from Mapping.grid_map_lib.grid_map_lib import GridMap
1314
import matplotlib.pyplot as plt
1415

16+
sys.path.append(os.path.dirname(os.path.abspath(__file__)) +
17+
"/../../Mapping/")
18+
19+
try:
20+
from grid_map_lib.grid_map_lib import GridMap
21+
except ImportError:
22+
raise
23+
1524
do_animation = True
1625

1726

0 commit comments

Comments
 (0)