Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions rlgym/api/config/action_parser.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, Generic, List
from ..typing import AgentID, ActionType, EngineActionType, StateType, ActionSpaceType


class ActionParser(Generic[AgentID, ActionType, EngineActionType, StateType, ActionSpaceType]):
class ActionParser(ABC, Generic[AgentID, ActionType, EngineActionType, StateType, ActionSpaceType]):
"""
The action parser. This class is responsible for receiving actions from the agents and parsing them into a format
supported by the TransitionEngine.
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/done_condition.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, List, Generic
from ..typing import AgentID, StateType


class DoneCondition(Generic[AgentID, StateType]):
class DoneCondition(ABC, Generic[AgentID, StateType]):
"""
A termination/truncation condition. This class is responsible for determining when an episode should end for each agent.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/obs_builder.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, List, Generic
from ..typing import AgentID, ObsType, StateType, ObsSpaceType


class ObsBuilder(Generic[AgentID, ObsType, StateType, ObsSpaceType]):
class ObsBuilder(ABC, Generic[AgentID, ObsType, StateType, ObsSpaceType]):
"""
The observation builder. This class is responsible for building observations for each agent in the environment.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/renderer.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
"""
An RLGym renderer.
"""
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, Generic
from ..typing import StateType


class Renderer(Generic[StateType]):
class Renderer(ABC, Generic[StateType]):
"""
The renderer class. This class is responsible for rendering a state.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/reward_function.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, List, Generic
from ..typing import AgentID, RewardType, StateType


class RewardFunction(Generic[AgentID, StateType, RewardType]):
class RewardFunction(ABC, Generic[AgentID, StateType, RewardType]):
"""
The reward function. This class is responsible for computing the reward for each agent in the environment.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/shared_info_provider.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Generic, Dict, Any, List
from ..typing import AgentID, StateType


class SharedInfoProvider(Generic[AgentID, StateType]):
class SharedInfoProvider(ABC, Generic[AgentID, StateType]):
"""
The shared information provider. This class is responsible for managing shared information across all config objects.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/state_mutator.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, Generic
from ..typing import StateType


class StateMutator(Generic[StateType]):
class StateMutator(ABC, Generic[StateType]):
"""
The state mutator class. This class is responsible for modifying the state of the environment.
"""
Expand Down
4 changes: 2 additions & 2 deletions rlgym/api/config/transition_engine.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from abc import abstractmethod
from abc import abstractmethod, ABC
from typing import Any, Dict, List, Generic
from ..typing import AgentID, EngineActionType, StateType


class TransitionEngine(Generic[AgentID, StateType, EngineActionType]):
class TransitionEngine(ABC, Generic[AgentID, StateType, EngineActionType]):
"""
The Transition Engine class. This class is responsible for managing the state of the environment and stepping the
environment forward in time.
Expand Down