raymondyang.dev
← map

How a card gets named

  1. 01DetectYOLOX-Nano finds card faces and backs in a 640×384 frame. 3.7 MB.
  2. 02CropEach face is cut out and pooled to 128×128.
  3. 03EmbedMobileNetV3-Small turns the crop into 128 numbers. 4.0 MB.
  4. 04MatchThe nearest row in a bank of one vector per card, built from card images.
  5. 05AcceptA name is shown only when the match clears two thresholds. Otherwise, nothing.

Measured on what shipped

98.0%of readable faces named right on Rift Atlas
0.57–2.72%of names shown were wrong, across all three sources
30 daysfrom starting the vision work to recognition on for every RiftSight user
SourceNamed rightWrong of shown
Rift Atlas (digital)98.0%1.43%
TCG Arena (digital)96.7%0.57%
Physical play, camera near overhead84.3%2.72%

The final test of the models in RiftSight 0.12.0, scored once on 88 frames from 63 recording groups, none used in training or development. Steeper physical camera angles are harder and were measured apart. The released models were trained on 50 labeled real frames (about 1,900 boxes from 25 videos) and 8,000 generated scenes, and the shipped bank holds 1,492 cards. Retraining from the public recipe takes about 5 hours on one rented RTX 4090, about $4.47.

Built to move to other games

A step-by-step guide takes the recipe to a new card game. On the One Piece Card Game, the Riftbound weights as they stood named 31.4% of readable faces. Fine-tuned on 23 labeled frames and generated scenes, they named 74.4%. That became Kenbunshoku.

What's in the repository

  • A labeling tool, and a generator of synthetic table scenes with exact labels
  • Evaluation that resamples whole recordings, so intervals aren't flattered by near-duplicate frames
  • Calibration of the accept rule against a wrong-name limit you set
  • A browser runtime checked against the Python pipeline