Spaces:
Runtime error
Runtime error
fixed issue with one parsed result
Browse files
app.py
CHANGED
@@ -53,13 +53,20 @@ def parse_metrics_accuracy(meta):
|
|
53 |
|
54 |
# We keep the worst case episode
|
55 |
def parse_rewards(accuracy):
|
|
|
|
|
56 |
if accuracy != None:
|
57 |
-
parsed =
|
58 |
-
|
59 |
-
|
|
|
|
|
|
|
|
|
|
|
60 |
else:
|
61 |
-
mean_reward =
|
62 |
-
std_reward =
|
63 |
return mean_reward, std_reward
|
64 |
|
65 |
def get_data(rl_env):
|
|
|
53 |
|
54 |
# We keep the worst case episode
|
55 |
def parse_rewards(accuracy):
|
56 |
+
default_std = -1000
|
57 |
+
default_reward=-1000
|
58 |
if accuracy != None:
|
59 |
+
parsed = accuracy.split(' +/- ')
|
60 |
+
if len(parsed)>1:
|
61 |
+
mean_reward = float(parsed[0])
|
62 |
+
std_reward = float(parsed[1])
|
63 |
+
else:
|
64 |
+
mean_reward = default_std
|
65 |
+
std_reward = default_reward
|
66 |
+
|
67 |
else:
|
68 |
+
mean_reward = default_std
|
69 |
+
std_reward = default_reward
|
70 |
return mean_reward, std_reward
|
71 |
|
72 |
def get_data(rl_env):
|