mirror of
https://github.com/gryf/coach.git
synced 2025-12-17 19:20:19 +01:00
raise value error if there is an invalid action space (#179)
This commit is contained in:
committed by
Gal Leibovich
parent
053adf0ca9
commit
0ccc333d77
@@ -379,6 +379,11 @@ class GymEnvironment(Environment):
|
||||
num_actions=self.env.action_space.n,
|
||||
descriptions=actions_description
|
||||
)
|
||||
else:
|
||||
raise screen.error((
|
||||
"Failed to instantiate gym environment class {} due to unsupported "
|
||||
"action space {}. Expected BoxActionSpace or DiscreteActionSpace."
|
||||
).format(env_class, self.env.action_space), crash=True)
|
||||
|
||||
if self.human_control:
|
||||
# TODO: add this to the action space
|
||||
|
||||
Reference in New Issue
Block a user