from json import loads
from math import copysign, cos, pi, sin
from matplotlib import pyplot as plt
-from sys import argv
+from sys import argv, exit
sign = lambda x: copysign(1, x)
################
## 1st subplot
- ax = fig.add_subplot(121)
+ if "edge" in t.keys():
+ ax = fig.add_subplot(121)
+ else:
+ ax = fig.add_subplot(111)
ax.set_aspect("equal")
ax.set_title("Final path")
ax.set_xlabel("x [m]")
handles, labels = ax.get_legend_handles_labels()
+ if not "edge" in t.keys():
+ plt.show()
+ plt.close(fig)
+ exit(0)
+
################
## 2nd subplot