Loading…
Loading…
Two small models that find trading cards in a frame of gameplay video and name them, for the One Piece Card Game. An unofficial fan project, not affiliated with or endorsed by Bandai or any publisher. Card names and card art belong to their owners. This model reads cards. It does not generate images, and no card art is included here.
These are the models of Kenbunshoku, a free Apache-2.0 Chrome extension that shows a card's official art when you rest the pointer on it in a YouTube or Twitch video. They were trained with the open-source cardvision toolkit (Python package cardvision, plus a TypeScript runtime for web pages, cardvision-browser). The toolkit is being released separately and is not public yet; Built on cardvision will link it when it is. The labels are in the companion dataset, kenbunshoku-onepiece-labels.
| File | What it is |
|---|---|
release.json |
The release document. It pins every other file by sha256 and holds the accept rule and runtime settings. |
detector.onnx |
Finds cards: a box, a score and a class (card face or card back). YOLOX-Nano, two classes, fp32, 3.7 MB. |
recognizer.onnx |
Turns a crop of a card face into a 128-value vector. MobileNetV3-Small features with a projection, fp32, 4.0 MB. |
bank.json |
One vector per card: numerical embeddings computed from card images, not the image files (the images are not included). 5,489 cards. |
bank.identity-groups.json |
Which catalog entries count as one card: a card and its other printings (the catalog entries whose printingOf names it) are one identity, and cards that only share a name are different cards. All DON!! card variants are one identity. 2,816 identities. A match names the identity; the picture an application shows may be a different printing of it. |
catalog.json |
Card ids, names, kinds and facets, with art given as file names only. 5,502 cards, 13 of them without art and so absent from the bank. The catalog also holds some Japanese-only printings; that is not a claim of Japanese-card support. |
accept.json |
The accept rule: tau 0.62, delta 0.05, rotation retry on. |
SHA256SUMS, LICENSE |
Checksums, and the Apache-2.0 license for these weights. |
Release B2.1 (f80d5b56cd907f03) differs from the evaluated release B2 (26a98a0f49a74545) in one catalog entry, OP09-051_p2 (its name, printing and facets corrected from an upstream metadata error), and so in bank.identity-groups.json, where that entry moves from the OP05-067 identity to the OP09-051 identity. The models, the bank vectors and the accept rule are byte-identical. B2.1's final recognition results were not remeasured; unchanged weights and bank vectors do not guarantee identical outputs after an identity-group correction (the held-out labels name neither card, but a changed identity can still be a candidate or runner-up on other cards). The figures below were measured on B2 and are labeled B2.
The detector finds each card in the frame. For every face it finds, the recognizer makes a vector, and the bank says which card is nearest. A name is shown only when the match is close enough (tau) and clear enough of the runner-up (delta). Otherwise nothing is shown. This is the same pipeline as the toolkit's other releases; the toolkit's docs/how-it-works.md will describe it in full when the toolkit is released.
Today, there are two ways.
detector.onnx and recognizer.onnx are plain ONNX files that load in ONNX Runtime (for example onnxruntime in Python, or ONNX Runtime Web) or any other ONNX runtime. release.json records the settings they run with: the detector's input size, letterbox, channel order and output columns, its score threshold and NMS, the recognizer's input size, and the accept rule. A few steps, such as the recognizer's crop preparation, are named there (full128) rather than spelled out: the runtime that Kenbunshoku ships implements them, and the toolkit's documentation will describe them. Download the files and check them against SHA256SUMS:hf download JuicyKaraageNo1/kenbunshoku-onepiece --local-dir kenbunshoku-onepiece
cd kenbunshoku-onepiece
shasum -a 256 -c SHA256SUMS
(hf comes with pip install -U huggingface_hub; cloning the repository with git and git-lfs works too.)
When the toolkit is released, it will verify and run the release directly. These commands do not work yet, because the toolkit is not public:
cardvision verify-release kenbunshoku-onepiece/release.json
cardvision infer YOUR-VIDEO.mp4 --release kenbunshoku-onepiece/release.json --annotate annotated/
verify-release checks every pinned file. infer runs the detector, recognizer, bank and accept rule that release.json pins.
In a web page, the toolkit's browser runtime (cardvision-browser) loads the same release.json, runs both models on ONNX Runtime Web (WebGPU with a WebAssembly fallback), and answers which card is under the pointer. Kenbunshoku ships it as built modules today; its source comes with the toolkit release. release.json pins ONNX Runtime Web 1.29.0.
Counts only. No frame, image or card art is published with this model.
fetch tool, coming with the toolkit release, will obtain the frames from the public videos.cardvision make-composites from official card art, which is not included here. The scenes show 5,489 different cards, with 93,790 positive faces and 15,538 backs.This is the figure to read, with its size beside it. All held-out figures here were computed with the toolkit's Python package; the browser extension was not tested on the held-out set (see "Python and the browser" below).
The set. 25 frames of 13 videos from 9 recording groups, none of which was in training. It was labeled by position: a person marked the center of every card, and labeled what lies under a seeded set of 100 random points, most of them off the cards. It holds 2 digital recording groups and 7 physical ones (4 webcam or phone, 3 tournament). Its labels are published as the evaluation manifests of the companion dataset. It holds 572 input hover events (472 marked centers and 100 seeded points). For B2, 540 of them are scored: 297 readable faces, 164 backs and 79 off-card positions. The other 32 are outside every rate (1 face labeled unreadable, 30 faces nobody could name, 1 unreadable point). The arms on the older catalog have 571 input events and 539 scored ones, because the one Japanese-printing face (below) is not in that catalog.
The measure. The unit is a hover event: the pointer rests on a position and the system either names a card or shows nothing.
Each arm ran with the accept rule in accept.json (tau 0.62, delta 0.05), not tuned for this game.
Intervals are 95% paired or unpaired group-bootstrap intervals over recording groups, 10,000 resamples, seed 0.
With 9 groups the intervals are wide, and a percentile bootstrap over so few groups tends to run narrow, so they are if anything optimistic. Read the figures as a rough scale, not as precise rates.
One digital recording group holds 135 of the 297 readable faces; the overall figures lean on it.
| Arm | Named right | Wrong of shown |
|---|---|---|
| Baseline (A0): the released Riftbound models, unchanged, with a bank built from this game's card images | 93/296 = 31.4% [23.7%, 42.5%] | 11/104 = 10.6% [4.2%, 28.0%] |
| A1: trained detector, released recognizer | 171/296 = 57.8% [31.7%, 68.1%] | 16/187 = 8.6% [3.6%, 28.1%] |
| A2: trained detector and recognizer (first training sitting only) | 222/296 = 75.0% [51.5%, 84.2%] | 8/230 = 3.5% [0.8%, 12.9%] |
| B2 (evaluated release) | 221/297 = 74.4% [50.3%, 83.8%] | 9/230 = 3.9% [1.6%, 11.8%] |
| B2 plus the optional geometric stage (Python evaluation) | 249/297 = 83.8% [62.5%, 91.8%] | 7/256 = 2.7% [0.6%, 10.3%] |
The arms on the older catalog score 296 readable faces and B2 scores 297, because one face is a Japanese printing that only the newer catalog has. Its inclusion is not a claim of Japanese-card support. The paired comparison of B2 with the baseline is scored on the older catalog, so it counts B2's wrong names as 9 of 229 shown (3.93%).
| Arm | Physical (7 groups): named right | Physical: wrong of shown | Digital (2 groups): named right | Digital: wrong of shown |
|---|---|---|---|---|
| Baseline (A0) | 35/123 = 28.5% [17.8%, 39.8%] | 10/45 = 22.2% [10.9%, 41.2%] | 58/173 = 33.5% | 1/59 = 1.7% |
| A1 | 45/123 = 36.6% [21.4%, 48.2%] | 13/58 = 22.4% [11.5%, 41.2%] | 126/173 = 72.8% | 3/129 = 2.3% |
| A2 | 69/123 = 56.1% [42.9%, 68.6%] | 6/75 = 8.0% [0.9%, 23.1%] | 153/173 = 88.4% | 2/155 = 1.3% |
| B2 | 68/124 = 54.8% [41.0%, 67.1%] | 7/75 = 9.3% [3.2%, 18.8%] | 153/173 = 88.4% | 2/155 = 1.3% |
| B2 plus geometric stage (Python evaluation) | 84/124 = 67.7% [51.2%, 80.4%] | 6/90 = 6.7% [0.8%, 17.3%] | 165/173 = 95.4% | 1/166 = 0.6% |
Digital figures rest on 2 recording groups and carry no interval. B2 names 54.8% right on physical play and 88.4% on digital, a gap of 33.6 points. The two digital groups range from 86.7% to 94.7%, which is a range, not an interval.
DON!! cards are the game's energy cards. Leaving them out, B2 names 193/256 = 75.4% [50.3%, 84.8%] right and shows 9/202 = 4.5% [1.9%, 13.6%] wrong of shown. Physical play without DON!!: 60/106 = 56.6% [37.8%, 72.7%] named right and 7/67 = 10.4% [3.6%, 23.3%] wrong of shown. Digital without DON!!: 133/150 = 88.7% named right and 2/135 = 1.5% wrong of shown, counts only. For the baseline, the same slice was 84/255 = 32.9% named right.
These were written down and frozen (sha256-pinned) in the maintainers' private records on 2026-10-16, before any held-out frame was scored; this is an internal, timestamped plan, not a public pre-registration. They are reported as computed. Each bound below is an end of the paired group-bootstrap 95% interval of the difference (candidate minus base).
After the recognizer picks its best few cards, the toolkit can look at them again by matching local keypoints against the card art. In the Python package it is off by default; it is not part of the release document (release.json), and without the --geometric flag nothing changes.
Its settings and a keypoint index built for this bank were fixed before the held-out frames were scored. The settings are those Kenbunshoku bundles as data/geometric.json (ORB features on art scaled to 160 px on the long side, at most 300 per card and 500 per crop, the 10 nearest cards by embedding re-checked, affine RANSAC, fusion weight 1.5 from 15 inliers); the held-out run used the same settings with the keypoint index file orb160-r2-B2.features.json (sha256 cd676903704f456de1790e58d6a2d8941f873c6a5ba548a6ad258c48c13ad4be), built for this bank. The browser loads the same keypoints repacked, through an index manifest with sha256 7b9a96f636611e34183b1a845db93846cb92e5d12ad0d273dd14d1e2c60cef19. Building the index needs the card art, which is not included, and the geometric extra of the toolkit. The held-out result is in the tables above and in the paired comparison with B2.
Python and the browser. The held-out geometric-stage results above were measured in Python. The toolkit's browser runtime has a port of the stage, which runs only with WebGPU. The browser implementation was compared with Python, with this release and these settings, in Chrome, on development data only (394 generated scenes and the 23 training frames), not on the held-out set, under a rule frozen in the maintainers' private records before the run. On generated development scenes, named-right rates were 74.76% in both implementations (difference +0.00 points, 95% interval -0.33 to +0.34); wrong-of-shown was 3.07% in Python and 2.94% in the browser (-0.13 points, -0.50 to +0.20). On the 23 training frames, named right was 94.08% in both. On the faces whose grayscale input was byte-identical on both sides, all 622 final hover answers agreed. However, the stricter pre-registered intermediate-parity check did not pass: vote-count and match agreement were 78.04% and 91.17%, below the 95% requirement. The maintainer chose to enable the browser stage on WebGPU despite that failed check, and Kenbunshoku, the browser extension built on this release, turns it on where WebGPU runs. These development results do not establish the browser extension's held-out accuracy. A diagnostic of the recorded evidence found the vote and match differences only on faces whose ORB descriptors differ between the native OpenCV build and OpenCV.js (on the 48 faces with identical descriptors, votes and matches were 100% identical). On 12 of those faces examined in detail, the cause was ORB's keypoint angle, which the two builds compute differently by under 0.01 degrees; that flips 1 to 5 descriptor bits on about 1% of keypoints. The cause is shown for those 12 faces and is the working explanation for the rest.
The model weights, the bank and the release document are released under Apache-2.0 (LICENSE). The bank is a set of vectors computed from card images; the images themselves belong to their owners and are not included. The labels in the companion dataset are CC BY 4.0.
@misc{kenbunshoku_onepiece_b2_1,
title = {Kenbunshoku One Piece card recognition models, release B2.1 (id f80d5b56cd907f03)},
author = {{The Kenbunshoku authors}},
year = {2026},
howpublished = {\url{https://huggingface.co/JuicyKaraageNo1/kenbunshoku-onepiece}}
}
A citation for the cardvision toolkit will come with its release.