Skip to content

Creating soccer_rl_preprocessing file#79

Open
akshatgarg06 wants to merge 1 commit intomasterfrom
akshatgarg06-2
Open

Creating soccer_rl_preprocessing file#79
akshatgarg06 wants to merge 1 commit intomasterfrom
akshatgarg06-2

Conversation

@akshatgarg06
Copy link
Collaborator

It takes existing SAR output files (events.jsonl) and converts them into a clean, model-ready RL dataset that can be used by both DQN and QMIX.

What it does

  • Reads SAR sequences from one file or a folder of events.jsonl.
  • Creates deterministic train/val/test splits (seed-based, by game_id or sequence_id).
  • Uses 10 attacking outfield players in fixed order (player_id sorted) for consistent multi-agent tensors.
  • Converts action strings to action IDs (default mapping provided, customizable via JSON).
  • Infers onball_mask (from explicit on-ball action or nearest player-to-ball fallback).
  • Builds per-timestep observation vectors from player + ball position/velocity features.
  • Pads/truncates to fixed sequence length and creates mask and done.

Why this helps
Gives one shared, reproducible dataset format for fair DQN vs QMIX comparison.
Keeps RL tensorization logic separate from existing SAR processing code, so current pipelines are not affected.

@github-actions
Copy link

Init Test Results 📝

  • Status: success
  • OS: Linux
  • Python: 3.10

@github-actions
Copy link

Init Test Results 📝

  • Status: success
  • OS: Linux
  • Python: 3.8

@github-actions
Copy link

Init Test Results 📝

  • Status: success
  • OS: Linux
  • Python: 3.9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant