Merge branch 'main' into 'unit_testing'

# Conflicts:
#   marl_factory_grid/algorithms/static/TSP_dirt_agent.py
#   marl_factory_grid/utils/config_parser.py
This commit is contained in:
Friedrich, Joel
2024-03-18 16:23:44 +01:00
98 changed files with 2608 additions and 554 deletions

View File

@@ -10,7 +10,7 @@ class DestAction(Action):
def __init__(self):
"""
Attempts to wait at destination.
The agent performing this action attempts to wait at the destination in order to receive a reward.
"""
super().__init__(d.DESTINATION, d.REWARD_WAIT_VALID, d.REWARD_WAIT_FAIL)

View File

@@ -38,7 +38,11 @@ class Destination(Entity):
def has_just_been_reached(self, state):
"""
Checks if the destination has just been reached based on the current state.
Checks if the destination has been reached in the last environment step.
:return: the agent that has just reached the destination or whether any agent in the environment has
performed actions equal to or exceeding the specified limit
:rtype: Union[Agent, bool]
"""
if self.was_reached():
return False

View File

@@ -12,7 +12,7 @@ from marl_factory_grid.modules.destinations.entitites import Destination
ANY = 'any'
ALL = 'all'
SIMULTANEOUS = 'simultanious'
SIMULTANEOUS = 'simultaneous'
CONDITIONS = [ALL, ANY, SIMULTANEOUS]