if __name__ == "__main__":
SCEN_FILE = argv[1]
- TRAJ_FILE = argv[2]
s = load_scenario(SCEN_FILE)
try:
+ TRAJ_FILE = argv[2]
t = load_trajectory(TRAJ_FILE) # fixed to trajectories
except:
- pass
+ t = {"elap": 0}
plt.rcParams["font.size"] = 24
plt.rcParams['hatch.linewidth'] = 1.0
except:
print("No slot")
- plt.plot(*car_frame(s["init"]), color="red", lw=2)
- plt.plot(*car_frame(t["goal"]), color="red", lw=2)
- plt.plot(*plot_nodes([s["init"]]), color="red", marker="+", ms=12)
- plt.plot(*plot_nodes([t["goal"]]), color="red", marker="+", ms=12)
+ try: # init
+ plt.plot(*car_frame(t["init"]), color="red", lw=2)
+ plt.plot(*plot_nodes([t["init"]]), color="red", marker="+", ms=12)
+ except:
+ plt.plot(*car_frame(s["init"]), color="red", lw=2)
+ plt.plot(*plot_nodes([s["init"]]), color="red", marker="+", ms=12)
+ try: # goal
+ plt.plot(*plot_nodes([t["goal"]]), color="red", marker="+", ms=12)
+ plt.plot(*car_frame(t["goal"]), color="red", lw=2)
+ except:
+ plt.plot(*plot_nodes([s["goal"]]), color="red", marker="+", ms=12)
+ plt.plot(*car_frame(s["goal"]), color="red", lw=2)
try: # middle
plt.plot(*car_frame(t["midd"]), color="red", lw=2)
plt.plot(*plot_nodes([t["midd"]]), color="red", marker="+", ms=12)