Trainable Complementary Filter
- Trainable complementary filters are sensor fusion methods where parameters are learned from data, enabling adaptive frequency-domain weighting.
- They integrate classical low- and high-pass filter designs with modern learning techniques to optimize estimation error and reduce noise.
- Applications include adaptive attitude estimation, time-series prediction, and seismic isolation, showing significant improvements over traditional filters.
A trainable complementary filter is a system identification or sensor fusion methodology in which the filter parameters—rather than being fixed or manually tuned—are learned or synthesized from data, enabling adaptive fusion of multi-source signals to optimize a target metric such as estimation error or residual noise. The concept leverages the classical complementary filter structure, which decomposes the fusion into frequency bands, but augments it with modern learning approaches or optimal control synthesis for automated adaptation.
1. Classical Complementary Filter Structure
The complementary filter is a technique for fusing two or more signals/predictions, typically in the context of sensor fusion or model combination. For two sources, denote their signals by and . The filter applies a low-pass transfer function to one source and a high-pass transfer function to the other, such that for all (Laplace variable). The fused output is
This structure ensures complete coverage across the frequency domain and enables frequency-selective signal combination, optimizing the contribution from each source where it is most reliable. In practice, may be chosen as a rational low-pass and as its complement (Tsang et al., 2021).
2. Trainable Parameterizations and Learning Approaches
Traditionally, the filter parameters are selected via manual tuning or empirical analysis. Trainable complementary filters replace this heuristic selection with either (a) data-driven learning of filter coefficients or (b) optimal synthesis according to noise models:
- In adaptive attitude estimation, axis-dependent gains for the accelerometer update () are mapped from the instantaneous residual through a dedicated multilayer perceptron (MLP) per axis. The input to each MLP is a polynomial expansion of the residual component, and the output, after a smooth thresholding operation, is the axis gain (Vertzberger et al., 2022). This allows localized adaptation in response to the sensor context.
- In time-series and system identification, the complementary filter's frequency cutoff parameter is parameterized through a learnable transformation, such as (with a sigmoid), and optimized in conjunction with model weights (e.g., RNN parameters) to minimize fusion error (Ensinger et al., 2023).
- For sensor fusion addressing seismic isolation in gravitational-wave detectors, the design of and is reformulated as an synthesis problem, yielding filters that minimize the worst-case logarithmic difference between fused sensor noise and its theoretical lower bound over frequency (Tsang et al., 2021).
3. Hybrid and Fully-Learned Filter Architectures
Trainable complementary filters manifest in multiple architectural forms:
- Hybrid Model-Based and Data-Driven: In adaptive attitude estimation ("Deep Attitude Estimator"), the backbone filter is model-based, but axis gain selection is delegated to learned neural networks. The filter recursively fuses inertial sensor data, with gain adaptation as a learnable mapping (Vertzberger et al., 2022).
- Fully-Learned Dynamical Systems Fusion: The complementary filter is used to combine outputs from fast (high-frequency-responsive) and slow (long-horizon-stable) neural models, yielding improved short- and long-term prediction accuracy. Both sub-models and the cutoff are learned jointly (Ensinger et al., 2023).
- Hybrid Model-Simulator Fusion: The slow model is implemented as a non-trainable physics-based simulator, and only the fast (neural) sub-model and the filter cutoff are learned (Ensinger et al., 2023).
- Optimal Control Synthesis: For multi-sensor fusion, filter coefficients are synthesized via optimization (e.g., Riccati-based solvers) based on explicit spectral models of sensor noise (Tsang et al., 2021).
4. Mathematical Formulations and Training Procedures
Key mathematical structures underpin trainable complementary filters:
- Component-wise Adaptive Fusion (Attitude):
- Gyro step: with orthonormalization.
- Residual: .
- Axis gain via MLP: .
- Adaptive update: .
- Optimization on ground-truth gravity angle error (Vertzberger et al., 2022).
- Dynamical System Fusion:
- Discrete filter recurrences for fast/HP and slow/LP contributions:
- End-to-end loss on fused prediction output (Ensinger et al., 2023).
Sensor Fusion Optimization:
- Objective function: Minimize subject to .
- Solution via synthesis (generalized plant formulation, Riccati solution) (Tsang et al., 2021).
5. Quantitative Performance and Empirical Results
Empirical evaluation demonstrates that trainable complementary filters provide accuracy and robustness superior to conventional fixed-filter approaches:
- Adaptive Attitude Estimation: DAE (hybrid trainable filter) achieves a mean roll/pitch RMS error of compared to – for traditional filters (Madgwick, Mahony, ES-EKF, AEKF) and for a prior model-learning filter. Computational load is minimal ( MLP parameters evaluated thrice per step, Hz throughput on CPU) (Vertzberger et al., 2022).
- Dynamics Learning: Double-mass spring system: baseline GRU RMSE , split-GRU (with trainable filter) RMSE ; i.e., 80% reduction. Double-torsion pendulum: 2–3× improvement in long-term RMSE (Ensinger et al., 2023).
- Sensor Fusion for Seismic Isolation: -synthesized filters keep fused sensor noise within few hundredths of a decibel of the theoretical lower bound at all frequencies; manual designs are suboptimal and less reproducible. Suppression ratios up to at the microseismic peak vs. for manual filters (Tsang et al., 2021).
6. Applications, Extensions, and Practical Guidance
Trainable complementary filters are applicable wherever multiple data sources exhibit complementary frequency-domain characteristics and where adaptation to environmental or system changes is desirable. Concrete domains include:
- Attitude estimation from low-grade inertial sensors under pedestrian motion (Vertzberger et al., 2022).
- Learning predictive models for unknown dynamical systems combining fast (sequence model) and slow (simulator) predictors (Ensinger et al., 2023).
- Sensor fusion in gravitational-wave detector seismic isolation, especially under evolving noise profiles (Tsang et al., 2021).
Practical guidance entails:
- Initializing trainable parameters (e.g., cutoff ) via spectral analysis.
- Enforcing filter constraints ( or ) via parameterization or architectural choice.
- Adopting stable parameterizations (e.g., sigmoid mapping to ).
- Using modern optimization solutions (SGD for neural filters; Riccati solvers for rational filters).
- Embedding real-time adaptation loops where sensor noise profiles may shift due to environmental or equipment changes (Tsang et al., 2021).
Extensions include multi-sensor fusion (), supervisory control with automated mode switching, or filter synthesis in broader control and estimation systems.
7. Theoretical and Implementation Considerations
A defining property is that the sum of complementary filter transfer functions must identically equal unity across all frequencies, ensuring no information loss or frequency gap. Stability is maintained by constraining trainable parameters (e.g., , with care to avoid exactly; small can be appended to denominators if necessary).
Automated filter synthesis via optimization enables reproducibility and optimality unattainable by manual design, particularly relevant for precision applications such as gravitational-wave detection, where maximal noise suppression is critical.
A plausible implication is that embedding trainable complementary filters in real-time adaptive systems enables continuous optimization of signal fusion in dynamic environments or under non-stationary noise statistics. This paradigm generalizes beyond sensor fusion to include any task where trade-offs between frequency-selective reliability must be managed end-to-end.