Live on movie trailers
Real time, in your browser: the tag in the corner comes from v6, a MobileNetV3-L distilled from v5, running on your CPU in WebAssembly at about 50 ms a frame (about 20 frames a second); the speed on your machine is shown under the timeline. The models learned from live-action film stills: the animated trailers and the two game trailers (Halo 3, Gears of War 2) are far from that, and The Matrix Reloaded is one of the films in the training data.
Disclaimer: the trailers are shown for educational and research purposes only, to demonstrate the classifier. I do not own them: all rights belong to their studios and publishers. If you hold the rights to one and want it removed, open a discussion on this Space and it will be taken down.
Inside a prediction
The model sees the centre 224 × 224 crop. Bright areas are the patches its CLS token attends to most in the last layer, averaged over six heads.
How the versions compare
Scores for v4 to v6 are on the 643 test frames none of them trained on: 216 of the 859 human-labelled frames also turned up, as identical stills, in the scraped training rows v4 and v5 learned from (v6 left them out). * v2 and v3 trained on about 80% of the human-labelled frames, so their scores, on all 859, are inflated and not comparable.
Data and training
Film stills
The test set is 863 frames labelled by people (859 with one of the seven sizes). Training uses 53,449 labelled rows, about 48,000 distinct stills from roughly 1,000 films: labelled by an earlier model, with low-confidence labels reviewed again. All of it is in types-of-film-shots.
Five tries
How it reads a frame
The frame is resized so its short side is 256 px, centre-cropped to 224 and normalised. A small vision transformer splits it into 16-pixel patches (14 for v2), and a linear layer on its CLS token scores the seven sizes. Every version here is quantised to int8, about 21 MB, and runs on ONNX Runtime Web.