|
24 | 24 | vmax = 1.5 |
25 | 25 | SAFETY_DIST = 2.0 |
26 | 26 | EPISODES = 100 |
27 | | -NUM_OBSTACLES = 0 |
| 27 | +NUM_OBSTACLES = 4 |
28 | 28 | NUM_STEPS = 100 |
29 | 29 | NUM_CHANNELS = 3 |
30 | 30 | GAMMA = 0.2 |
31 | | -USE_CBF = False |
| 31 | +USE_CBF = True |
32 | 32 |
|
33 | 33 | resolution = 2 * ROBOT_RANGE / GRID_STEPS |
34 | 34 |
|
@@ -120,9 +120,9 @@ def safety_constraint(u, A, b): |
120 | 120 | Zmax = np.max(Z) |
121 | 121 | Z = Z / Zmax |
122 | 122 |
|
123 | | - fig, [ax, ax2] = plt.subplots(1, 2, figsize=(12,6)) |
124 | | - plot_occgrid(Xg, Yg, Z, ax=ax) |
125 | | - plot_occgrid(Xg, Yg, Z, ax=ax2) |
| 123 | + # fig, [ax, ax2] = plt.subplots(1, 2, figsize=(12,6)) |
| 124 | + # plot_occgrid(Xg, Yg, Z, ax=ax) |
| 125 | + # plot_occgrid(Xg, Yg, Z, ax=ax2) |
126 | 126 |
|
127 | 127 |
|
128 | 128 |
|
@@ -310,8 +310,8 @@ def safety_constraint(u, A, b): |
310 | 310 |
|
311 | 311 | path = Path().resolve() |
312 | 312 | res_path = path / "results" |
313 | | - np.save(res_path/"eta12_conv.npy", eval_data) |
314 | | - np.save(res_path/"collisions12_conv.npy", collision_counter) |
| 313 | + np.save(res_path/"eta12.npy", eval_data) |
| 314 | + np.save(res_path/"collisions12.npy", collision_counter) |
315 | 315 |
|
316 | 316 | ''' |
317 | 317 | for i in range(ROBOTS_NUM): |
|
0 commit comments