Skip to content

Commit 2625dbc

Browse files
committed
fixes
1 parent d02ce3f commit 2625dbc

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

proj/environment/environment.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,10 @@ def plan(self, curr_x, g_traj, itern):
108108
if abs(start - end) != pred_len:
109109
g_traj = g_traj[start:end]
110110
len_diff = (end - start) - pred_len
111-
if len_diff <= 0:
112-
len_diff = 1
113-
return np.pad(g_traj, ((0, len_diff), (0, 0)), mode="edge")
111+
112+
if len_diff <= 0:
113+
len_diff = 1
114+
return np.pad(g_traj, ((0, len_diff), (0, 0)), mode="edge")
114115
else:
115116
return g_traj[start:end]
116117

proj/run/runner.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,11 @@ def run_experiment(
117117
logger.exception(
118118
f"Failed to take next step in simulation.\nError: {e}\n\n"
119119
)
120-
try:
121-
environment.conclude():
122-
except:
123-
environment.failed()
124-
return
120+
try:
121+
environment.conclude()
122+
except:
123+
environment.failed()
124+
return
125125

126126
logger.info(f"Terminated after {itern} iterations.")
127127

0 commit comments

Comments
 (0)