Abstract
WaveFormer is a highly efficient, 3.1-million-parameter Transformer model designed for real-time hand gesture recognition using surface electromyographic (sEMG) signals. By integrating a learnable wavelet transform with Rotary Positional Embeddings (RoPE), WaveFormer achieves state-of-the-art accuracy while maintaining a low latency of 6.75 ms, making it ideal for deployment in resource-constrained prosthetic and wearable devices.
Introduction
Surface electromyography (sEMG) captures the electrical activity of muscles, serving as a critical control signal for robotic prosthetics and gesture-based human-computer interfaces. However, decoding these signals is challenging due to high non-stationarity and sensitivity to electrode placement or skin impedance changes.
While large-scale "foundation models" for time-series data have shown promise, their massive parameter counts (often exceeding 100 million) and lack of domain-specific inductive biases make them unsuitable for low-power wearable technology. WaveFormer addresses these limitations by incorporating a micro-sized Transformer architecture that explicitly models both time and frequency domains.
Methodology: The WaveFormer Architecture
WaveFormer bridges the gap between efficiency and expressive power through two primary innovations: a learnable wavelet transform and a Transformer encoder utilizing Rotary Positional Embeddings (RoPE).
Learnable WaveletConv
Unlike traditional methods that use fixed wavelet bases, WaveFormer employs WaveletConv, a learnable Discrete Wavelet Transform (DWT). Using depthwise separable convolutions, the model decomposes the input signal into four frequency subbands (Low-Low, Low-High, High-Low, High-High). Initialized with standard wavelet filters, these parameters are optimized during training, allowing the model to adapt to subject-specific noise and amplify relevant frequency bands for gesture differentiation.
Transformer with RoPE
The wavelet-processed features are flattened and processed by a lightweight 6-layer Transformer. To capture the relative timing of rapid muscle contractions, WaveFormer utilizes Rotary Positional Embedding (RoPE). Unlike absolute positional encodings, RoPE uses rotation matrices to encode relative distances between tokens, which is crucial for decoding complex temporal sequences in biosignals.
Experimental Results
WaveFormer was evaluated on four major sEMG benchmarks: EPN-612, Ninapro DB5, Ninapro DB6, and UCI EMG.
Performance and Robustness
The model achieved top-tier accuracy across all datasets, notably reaching 95.21% on EPN-612 and 87.53% on the complex Ninapro DB5. Crucially, on the Ninapro DB6 dataset—which tests inter-session repeatability over multiple days—WaveFormer achieved 81.93% accuracy, significantly outperforming previous lightweight models. This demonstrates its robustness to the natural "drift" in signal quality common in real-world use.
Efficiency for Real-Time Deployment
Efficiency is a core strength of WaveFormer. When quantized to INT8, the model achieves an inference latency of just 6.75 ms on a standard CPU, well within the 200 ms threshold required for seamless prosthetic control. With only 3.1 million parameters, it outperforms foundation models like MOMENT (385M parameters) while being over 100x smaller.
Conclusion
WaveFormer demonstrates that domain-specific inductive bias is more effective than sheer model size for biosignal processing. By combining learnable frequency decomposition with advanced temporal encoding, it provides a robust, real-time solution for gesture recognition. Future work will explore cross-subject adaptation to eliminate the need for individual user recalibration and extend the architecture to other clinical signals like EEG and ECG.
Summary updated