Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Supporting multirollout for the simapp released as of reInvent 2019 (#…
…983)
- Loading branch information
1 parent
9e38c5c
commit 1cef53b
Showing
79 changed files
with
8,565 additions
and
1,557 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
reinforcement_learning/rl_deepracer_robomaker_coach_gazebo/src/markov/actions/default.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"action_space": [ | ||
{ | ||
"steering_angle": -30, | ||
"speed": 0.6 | ||
}, | ||
{ | ||
"steering_angle": -15, | ||
"speed": 0.6 | ||
}, | ||
{ | ||
"steering_angle": 0, | ||
"speed": 0.6 | ||
}, | ||
{ | ||
"steering_angle": 15, | ||
"speed": 0.6 | ||
}, | ||
{ | ||
"steering_angle": 30, | ||
"speed": 0.6 | ||
} | ||
], | ||
"sensor": ["FRONT_FACING_CAMERA"], | ||
"neural_network": "DEEP_CONVOLUTIONAL_NETWORK_SHALLOW" | ||
} |
Empty file.
46 changes: 46 additions & 0 deletions
46
...earning/rl_deepracer_robomaker_coach_gazebo/src/markov/agent_ctrl/agent_ctrl_interface.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
'''This class this defines an interface for how agents need to interact with the | ||
environment, all concrete classes should abstract away the communication of the | ||
agent with gazebo | ||
''' | ||
import abc | ||
|
||
class AgentCtrlInterface(object, metaclass=abc.ABCMeta): | ||
@property | ||
@abc.abstractmethod | ||
def action_space(self): | ||
'''Returns a read onlu version of the action space so that is can be passed to coach''' | ||
raise NotImplementedError('Agent control must be able retrieve action space') | ||
|
||
@abc.abstractmethod | ||
def reset_agent(self): | ||
'''Reset the agent to a desired start postion | ||
''' | ||
raise NotImplementedError('Agent control must be able to reset agent') | ||
|
||
@abc.abstractmethod | ||
def send_action(self, action): | ||
'''Send the desired action to the agent | ||
action - Integer with the desired action to take | ||
''' | ||
raise NotImplementedError('Agent control must be able to send action') | ||
|
||
@abc.abstractmethod | ||
def judge_action(self, action): | ||
'''Returns the reward and done flag after and agent takes the action prescribed by a given | ||
policy | ||
action - Integer with the desired action to take | ||
''' | ||
raise NotImplementedError('Agent control must be able to judge action') | ||
|
||
@abc.abstractmethod | ||
def finish_episode(self): | ||
'''Runs all behavior required at the end of the episode, such as uploading | ||
debug data to S3. | ||
''' | ||
raise NotImplementedError('Agent control must be able to properly handle the end of \ | ||
an episode') | ||
|
||
@abc.abstractmethod | ||
def clear_data(self): | ||
'''Clears the agent data''' | ||
raise NotImplementedError('Agent control must be able to clear data') |
Oops, something went wrong.