Liquid Resistance Liquid Capacitance Networks

Mónika Farsang, Radu Grosu, Grosu, Radu · DOI

Abstract

We introduce liquid-resistance liquid-capacitance neural networks (LRCs), a neural-ODE model which considerably improve the generalization, accuracy, and biological plausibility of electrical equivalent circuits (EECs), liquid time-constant networks (LTCs), and saturated liquid time-constant networks (STCs), respectively. We also introduce LRC units (LRCUs), as a very efficient and accurate gated RNN-model, which results from solving LRCs with an explicit Euler scheme using just one unfolding. We empirically show and formally prove that the liquid capacitance of LRCs considerably dampens the oscillations of LTCs and STCs, while at the same time dramatically increasing accuracy even for cheap solvers. We experimentally demonstrate that LRCs are a highly competitive alternative to popular neural ODEs and gated RNNs in terms of accuracy, efficiency, and interpretability, on classic time-series benchmarks and a complex autonomous-driving lane-keeping task.

Introduction

In the world of deep learning, researchers often navigate between the raw power of black-box models like LSTMs and the elegant, physics-informed nature of Neural Ordinary Differential Equations (Neural ODEs). While Neural ODEs promise better interpretability and the ability to handle irregularly sampled data, they frequently suffer from a notorious "stiffness" problem—they tend to oscillate wildly, requiring expensive mathematical solvers to maintain stability.

The Problem: Stiffness in Neural ODEs

The researchers target a specific weakness in Liquid Time-Constant networks (LTCs) and Saturated LTCs (STCs). These models, inspired by biological neurons, are mathematically "stiff," making them prone to high-frequency oscillations. As shown in Figure 4, previous models like STCs can exhibit significant erratic behavior when using simple solvers, failing to track the ground truth accurately in complex tasks like road curvature prediction.

Erratic oscillations in the baseline STC model's predictions

To train such models, researchers typically rely on "expensive" ODE solvers (like Runge-Kutta) that require many steps for a single update, leading to high computational costs. The authors argue that this stiffness arises from an oversimplification: previous models assumed a constant "capacitance" (the ability of a neuron's membrane to store charge), whereas in biological systems, this capacitance is state-dependent.

Methods: Liquid-Resistance Liquid-Capacitance (LRC) Networks

The core innovation of this work is the introduction of Liquid-Resistance Liquid-Capacitance (LRC) networks. By adding a liquid elastance term, $\epsilon(w_i)$ (the reciprocal of capacitance), to the state equation, the model gains a dynamic damping effect. This term acts as a controller: it increases the time constant to smooth out "gentle" dynamics while leaving "stiff" dynamics unchanged.

The LRC Unit (LRCU)

Because LRC dynamics are inherently smoother, complex solvers are no longer necessary. By solving the LRC equations with a simple, one-step explicit Euler scheme, the authors derived the LRC Unit (LRCU).

Architecture of the LRC Unit (LRCU) as a gated RNN

As illustrated in Figure 6, the LRCU is an architectural hybrid. It functions as a gated RNN—similar to a GRU or LSTM—but is derived directly from the physics of electrical equivalent circuits. Formal proofs (Theorems 1 and 2) demonstrate that LRCs have a lower Lipschitz constant, making them mathematically "smoother" and more robust to noise than their predecessors.

Experimental Results

The models were evaluated across a diverse set of challenges, including classic RNN benchmarks (IMDB sentiment, activity localization), Neural ODE benchmarks (Duffing Oscillator), and a complex autonomous-driving lane-keeping task.

Key Performance Metrics

  • Superior Accuracy: LRCUs consistently outperformed LSTMs and GRUs. For instance, on the IMDB dataset, the LRCU-A achieved 87.00% accuracy, surpassing the LSTM's 86.56%.
  • Efficiency Gains: LRCs achieved a 3x to 7.8x total speedup compared to standard LTCs by enabling the use of simpler solvers without sacrificing accuracy.
  • Robustness to Noise: In autonomous driving simulations with injected Gaussian noise, LRCUs maintained a 0.000 crash likelihood at moderate noise levels, while traditional gated RNNs like GRUs and MGUs began to fail significantly.
  • Interpretability: The activity of LRCU neurons showed a high correlation (up to 0.766) with physical road trajectories, nearly double that of LSTMs (~0.45), making the model's internal state much easier to audit.

Conclusion

By bridging the gap between biological reality and machine learning efficiency, LRCs offer a promising path for researchers requiring fast, stable, and interpretable models. By incorporating state-dependent capacitance, they provide a stable framework for time-series modeling that outperforms traditional black-box RNNs. Future work will focus on testing these models on larger industrial datasets and further refining their biological plausibility.

Summary updated

BibTeX
@inproceedings{farsang2024liquid,
  author = {Mónika Farsang and Radu Grosu and Grosu, Radu},
  title = {{Liquid Resistance Liquid Capacitance Networks}},
  booktitle = {NeuroAI @ NeurIPS},
  year = {2024},
  url = {https://openreview.net/forum?id=DzCxA1iovy},
}
Figure