Skip to content
Snippets Groups Projects
Commit 9464e58c authored by Erik Nygren's avatar Erik Nygren :bullettrain_front:
Browse files

removed all action_dict changes to avoid confusion while training

parent ea0d33a2
No related branches found
No related tags found
No related merge requests found
......@@ -199,7 +199,7 @@ class RailEnv(Environment):
if iAgent not in action_dict: # no action has been supplied for this agent
if agent.moving:
# Keep moving
# CHange MOVE_FORWARD to DO_NOTHING
# Change MOVE_FORWARD to DO_NOTHING
action_dict[iAgent] = RailEnvActions.DO_NOTHING
else:
action_dict[iAgent] = RailEnvActions.DO_NOTHING
......@@ -216,13 +216,13 @@ class RailEnv(Environment):
if action == RailEnvActions.DO_NOTHING and agent.moving:
# Keep moving
# Changed MOVE_FORWARD to DO_NOTHING
action_dict[iAgent] = RailEnvActions.DO_NOTHING
#action_dict[iAgent] = RailEnvActions.DO_NOTHING
action = RailEnvActions.MOVE_FORWARD
if action == RailEnvActions.STOP_MOVING and agent.moving:
#action_dict[iAgent] = RailEnvActions.DO_NOTHING
# CHanged DO_NOTHING to STOP_MOVING
action = RailEnvActions.STOP_MOVING
# action = RailEnvActions.STOP_MOVING
agent.moving = False
self.rewards_dict[iAgent] += stop_penalty
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment