Downloads · 30 days
0
LorenzoLamberti94/spiking-patches
spiking-patches is a machine learning model from LorenzoLamberti94. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for pytorch.
Weights for a replication of Spiking Patches: Asynchronous, Sparse, and Efficient Tokens for Event Cameras (Øhrstrøm, Güldenring, Nalpantidis, 2025). Code: DTU-PAS/spiking-patches.
Downloads · 30 days
0
Access
Public
Updated Aug 4, 2026
Repo size
2.1 GB
Likes
0
Public
Click a slice to open those files.
.ckpt2.1 GB · 100%
From the Hugging Face model README
Weights for a replication of Spiking Patches: Asynchronous, Sparse, and Efficient Tokens for Event Cameras (Øhrstrøm, Güldenring, Nalpantidis, 2025). Code: DTU-PAS/spiking-patches.
These are the Transformer (ViT-B, 89 M params) classifiers on the two gesture-recognition datasets, one checkpoint per input representation: Spiking Patches (SP), Voxel (V), and Frames (F).
⚠️ Coverage: DvsGesture and SL-Animals-DVS only. The paper's third dataset, GEN1 (object detection), is not included here. Checkpoints are weights-only (
state_dict, fp32, no optimizer state) — for evaluation/inference, not resuming training.
| File | Dataset | Representation | This checkpoint | Paper |
|---|---|---|---|---|
DG-T-SP.ckpt | DvsGesture | Spiking Patches | 97.73 | 98.1 |
DG-T-V.ckpt | DvsGesture | Voxel | 97.73 | 97.7 |
DG-T-F.ckpt | DvsGesture | Frames | 96.21 | 97.0 |
SL-T-SP.ckpt | SL-Animals-DVS | Spiking Patches | 89.47 | 91.7 |
SL-T-V.ckpt | SL-Animals-DVS | Voxel | 85.34 | 90.2 |
SL-T-F.ckpt | SL-Animals-DVS | Frames | 92.48 | 88.0 |
DvsGesture reproduces the paper closely (single run each). SL-Animals-DVS is small and high-variance; the checkpoint shipped here is the best of 5 seeds per config. 5-seed mean ± std (test acc): SP 88.3 ± 1.0, Voxel 82.0 ± 3.6, Frames 90.7 ± 0.8.
Each file maps to a config name in the upstream repo's train.DEFAULT_CONFIGS (filename == config name):
import torch
from huggingface_hub import hf_hub_download
from sp.configs import Config, Dataset
from sp.loaders import load_model
name = "DG-T-SP" # e.g. DG-T-SP, SL-T-V, ...
ckpt = hf_hub_download("LorenzoLamberti94/spiking-patches", f"{name}.ckpt")
# rebuild the exact config used for training
from train import DEFAULT_CONFIGS
_, config = DEFAULT_CONFIGS[name]
model = load_model(config)
model.load_state_dict(torch.load(ckpt, map_location="cpu")["state_dict"])
model.eval()
Datasets must be preprocessed as described in the upstream README before running evaluation.