CoolFace
Datasetpublic

ybashir/CS2-HUD-OCR-Crops

CS2 HUD OCR Crops Per-region HUD crops sliced from three Counter-Strike 2 match recordings, labelled where possible from the demo file's parse_ticks state. Built to train a specialist CRNN that replaces the EasyOCR killfeed reader (currently ~6 s p95 on CPU) with a sub-30 ms specialist. Source Three matches by the same POV player (farouqqq), recorded in CS2's built-in DVR + the corresponding .dem files: sample map dem rounds resolution fps sample1… See the full description on the dataset page: https://huggingface.co/datasets/ybashir/CS2-HUD-OCR-Crops.

sourceHugging Facecc-by-4.0updated 4mo agoView on Hugging Face
0likes278downloads
Dataset Card

CS2 HUD OCR Crops

Per-region HUD crops sliced from three Counter-Strike 2 match recordings, labelled where possible from the demo file's parse_ticks state. Built to train a specialist CRNN that replaces the EasyOCR killfeed reader (currently ~6 s p95 on CPU) with a sub-30 ms specialist.

Source

Three matches by the same POV player (farouqqq), recorded in CS2's built-in DVR + the corresponding .dem files:

samplemapdemroundsresolutionfps
sample1Ancientancent.dem81280 × 102460
sample2Dust 2dust_2.dem101280 × 102460
sample3Overpassoverpass.dem91280 × 102460

Frames sampled at 5 fps. Per-region ROIs slice via the `hud_extractor` package's calibrated hud_template.json.

Signals + label sources

signallabel sourcegate
hpdem health (POV-filtered, alive only)v_mask brightness + phash dedupe
moneydem balancev_mask brightness + phash dedupe
ammodem m_iClip1 (alive only)v_mask brightness + phash dedupe
timertesserocr text (≥ 0.70 conf) — optionalv_mask brightness + phash dedupe
killcamtesserocr binary (≥ 0.50 conf) — optionalv_mask + phash + ±5 s POV death window
killfeedunlabeled in this v1 (use Colab GPU)v_mask brightness + phash dedupe; one crop per row slot
friendly_chatunlabeled in this v1 (use Colab GPU)v_mask brightness + phash dedupe; one crop per row slot

killfeed and friendly_chat are saved without text labels in this release because the EasyOCR teacher (~600 ms / row on CPU) made a single pass impractical. The crops are ready for a GPU-side labeling sweep (EasyOCR gpu=True is ~10× faster on a single T4).

File layout

dataset/cs2_ocr/
├── crops/                              # PNG, one per labeled crop
│   ├── hp_sample1_r07_f000048.png
│   ├── money_sample2_r03_f000132.png
│   ├── killfeed_sample3_r05_f000240_row2.png
│   ├── friendly_chat_sample1_r10_f000600_row3.png
│   └── ...
├── train.parquet
├── val.parquet
├── test.parquet
└── manifest.json

Split key = (sample, round), so no frame leak across splits.

splitcomposition
trainsample1 r07-r10 · sample2 r01-r07 · sample3 r01-r06
valsample1 r11 · sample2 r08 · sample3 r07
testsample1 r12-r14 · sample2 r09-r10 · sample3 r08-r09

Parquet schema

columntypenotes
crop_pathstrrelative to dataset root, e.g. crops/hp_sample1_r07_f000048.png
signalstrone of hp money ammo timer killcam killfeed friendly_chat
labelstrground-truth string; "" for unlabeled rows
teacher_enginestrdem / tesserocr / easyocr / unlabeled
teacher_conffloat0-1; 1.0 for dem, 0.0 for unlabeled
dem_verifiedboolTrue iff label came from the dem (the dem is ground truth)
clip_idstrsource clip, e.g. sample1_r07
frame_idxintoriginal frame ordinal inside the clip
width_pxintcrop width in pixels
height_pxintcrop height in pixels

How to load

python
from datasets import load_dataset
ds = load_dataset("ybashir/CS2-HUD-OCR-Crops")

To get an actual image rather than a path you'll need to join the crop_path column with the downloaded crops/ directory.

Build details

Known limitations

  • POV-only labels. The dem ground truth applies to farouqqq's state; other players' HUDs are not in scope.
  • sample3 round 1 begins before the dem started recording. Its dem_freeze_s is negative — the dem-truth labels begin partway into the clip.
  • parse_event is broken on these dem files (EntityNotFound across every version of demoparser2), so player_death correlations for killfeed verification are not available. EasyOCR remains the only signal source for killfeed/chat.
  • Re-encoded clips (-c libx264 -crf 20) lose a few decibels vs. the source DVR; not visible at HUD resolution but flagged for transparency.

License

CC-BY-4.0. The underlying gameplay footage is captured from a personal Counter-Strike 2 session (Valve Corp.) — the dataset is published for non-commercial research on HUD-region OCR distillation.