Skateboard trick classification

Video classification · PyTorch

I used skateboard trick recognition to investigate a simple question: how much does a video classifier actually need to understand motion? Starting from the SkateboardAI paper, I reproduced its attention-and-BiLSTM approach, expanded the dataset, and compared it with simpler ways of combining frame features.

From clips to predictions

The dataset contains 873 clips across 15 trick categories, including 123 additional clips to improve coverage of frequently confused classes. Each clip is represented by 45 uniformly sampled frames. A frozen, ImageNet-pretrained ResNet50 converts every frame into a 2,048-dimensional feature vector, which I cache so that different classification heads can be compared efficiently.

I evaluated recurrent, attention-based, and logistic-regression heads with five-fold stratified cross-validation. Splits are made at the clip level, keeping all frames from a video together. Class weighting addresses the unequal number of examples per trick.

What worked

The best configuration uses a small self-attention head: a 64-dimensional projection, one attention layer, a feed-forward block, and mean pooling. It has approximately 174,000 trainable parameters and no positional encoding. Light frame dropout removes some frame features during training, encouraging the model to work with incomplete observations.

Reported five-fold accuracy: reproduced BiLSTM 80.1 percent, logistic regression 84.1 percent, and best searched self-attention head 88.8 percent.
Comparison on the expanded dataset. The 80.1% baseline is my reproduction under this protocol, not the original paper's differently evaluated result. The best attention configuration scored 88.8 ± 1.9% across folds.

The best reported score improved on the reproduced BiLSTM by 8.7 percentage points. A logistic-regression baseline already reached 84.1% by averaging frame-level class probabilities. Positional-encoding experiments showed no clear benefit, suggesting that frame appearance and aggregation explain much of the performance on this dataset.

What the result means

This does not establish that motion is unimportant for recognising tricks. Similar-looking flatground tricks remained difficult, and scenery or video-source differences may offer shortcuts. The same folds informed early stopping and hyperparameter selection, so 88.8% is a model-selection result rather than an independent test estimate. A source-separated test set and matched aggregation ablations would be useful next steps for measuring how well the model recognises the trick itself.

← All projects