Skip to content

Raid

Raid

Three raiders on a 12×12 grid with a barn, a house and a bank. Richer targets need more raiders at once and are more likely to be trapped, and a trap costs the whole team. Each building can be raided once per episode.

import gridhunt
env = gridhunt.make("GridHunt-Raid-v0")

What it tests

Taking shared risks. Richer targets need more raiders and are more often trapped, a trap costs the whole team, and each target can be raided once.

  • Removing one agent costs the scripted team: any one: 46% (interdependence ablation; capture only, not information)
  • Vary it with: trap probabilities and penalties, rewards

Overview

Environment ID GridHunt-Raid-v0
Grid 12 × 12
Agents 3
Episode length 1000 steps
Actions Discrete(5): stay, up, down, left, right
Observations one_hot, 870 values per agent
Global state 18 values (env.state())
Prey motion static

Agents

Agent Capture power Speed Vision Terrain Notes
raider_0 1 1 whole board - -
raider_1 1 1 whole board - -
raider_2 1 1 whole board - -

Prey

Prey Type Reward Capture power needed Reappears after capture Notes
barn_0 building 2 1 no -
house_0 building 5 2 no trapped with probability 0.25 (team penalty -4)
bank_0 building 20 3 no trapped with probability 0.5 (team penalty -25)

A capture happens when the hunters on a prey's cell have at least the capture power it needs. With more power than needed, the prey's overcrowding penalty is subtracted from its reward.

Benchmark

The benchmark plays it with team reward, 200-step episodes and a budget of 7M environment steps, with flat_coords observations. Scores are team returns: IQM over 20 seeds with 95% bootstrap intervals (details).

Configuration Algorithm IQM [95% CI] Normalized Random Scripted
raid IPPO 5.9 [5.9, 5.9] 0.45 1.8 10.9
raid MAPPO 5.8 [5.7, 5.9] 0.44 1.8 10.9
raid HAPPO 5.9 [5.8, 5.9] 0.45 1.8 10.9

Version history

  • v0 (GridHunt 1.0.0): first release.