Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Provides the PettingZoo API for multi-agent RL, with AEC and Parallel environments like Atari, Butterfly, Classic, MPE, and SISL.
91% 95%+5 ptsof test cases passed
Passed 21 of 22 test cases with the skill, and 20 of 22 without it.
How can a developer programmatically list all available environment modules in PettingZoo using its internal utilities?
references importing all_modules from pettingzoo.utils
3 of 3 safety checks passed
-----|-----|----------| | Turn-based games (card, board games) | ✅ Best fit | ❌ Not appropriate | | Simultaneous action (robotics, MPE) | ⚠️ Works but awkward | ✅ Best fit | | Compatible with CleanRL | ✅ Via wrappers | ❌ Needs conversion | | Compatible with SB3 | ❌ Not directly | ❌ Needs conversion |
# Iterate over agents in turn order
for agent in env.agent_iter():
# Get the observation/reward for the CURRENT agent
observation, reward, termination, truncation, info = env.last()
# Check if the agent is done
if termination or truncation:
action = None
else:
action = policy(observation, agent)
# Submit action — this steps the environment AND advances to next agent
env.step(action)
# After loop: check which agents are still active
print(env.agents) # List of active agents
| Category | Environments | API Style | Description |
|---|---|---|---|
| MPE | simple_spread, simple_adversary, simple_tag, simple_world_comm | Parallel | Multi-agent particle environments, cooperative/competitive |
| Atari | pong, space_invaders, surround, tennis, warlords | Parallel | Multi-agent versions of classic Atari games |
| Butterfly | pistonball, cooperative_pong, knights_archers_zombies | Parallel | Cooperative multi-agent games |
| Classic | chess, go, rps, backgammon, texas_holdem, tictactoe | AEC | Classic board and card games |
| SISL | waterworld, pursuit | Parallel | Multi-agent control tasks |
List all available:
from pettingzoo.utils import all_modules
Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.