Module deepcomp.agent.base
Abstract base classes for central vs distributed/multi agents
Expand source code
"""Abstract base classes for central vs distributed/multi agents"""
class CentralAgent:
"""Single central agent that observes and controls all UEs at once."""
def __init__(self):
self.central_agent = True
def compute_action(self, observation):
raise NotImplementedError("This needs to be implemented in the child class")
class MultiAgent:
def __init__(self):
self.central_agent = False
def compute_action(self, observation, policy_id):
raise NotImplementedError("This needs to be implemented in the child class")
Classes
class CentralAgent
-
Single central agent that observes and controls all UEs at once.
Expand source code
class CentralAgent: """Single central agent that observes and controls all UEs at once.""" def __init__(self): self.central_agent = True def compute_action(self, observation): raise NotImplementedError("This needs to be implemented in the child class")
Subclasses
Methods
def compute_action(self, observation)
-
Expand source code
def compute_action(self, observation): raise NotImplementedError("This needs to be implemented in the child class")
class MultiAgent
-
Expand source code
class MultiAgent: def __init__(self): self.central_agent = False def compute_action(self, observation, policy_id): raise NotImplementedError("This needs to be implemented in the child class")
Subclasses
Methods
def compute_action(self, observation, policy_id)
-
Expand source code
def compute_action(self, observation, policy_id): raise NotImplementedError("This needs to be implemented in the child class")