A Disentangled Recognition and Nonlinear Dynamics Model for Unsupervised Learning

Marco Fraccaro, Simon Kamronn, Ulrich Paquet, Ole Winther

TL;DR

The Kalman Variational Auto-Encoder (KVAE) is a framework that learns to understand video by disentangling "what" an object is from "how" it moves. By combining deep learning for image recognition with classical Kalman filtering for dynamics, it can "imagine" trajectories and fill in missing video frames more accurately than standard deep learning models.

What Problem Does This Paper Address?

When humans watch a tennis ball, we don't just see a sequence of independent pixels; we recognize the ball as an object and intuitively understand the Newtonian physics governing its flight. Most deep learning models for video, however, are autoregressive: they try to predict the next frame pixel-by-pixel based on previous frames. This is computationally expensive and often fails to capture the underlying "logic" of movement.

The authors identify a major gap: current models struggle to separate spatial representation (recognizing the object) from temporal dynamics (predicting its path). Furthermore, most models are good at predicting the future but poor at imputing (filling in) the past or middle of a sequence because they cannot easily incorporate information from future frames into their current estimate.

Methods

To address these limitations, the authors introduce the Kalman Variational Auto-Encoder (KVAE), which "sandwiches" a classical state-space model between deep neural networks.

Graphical model of the Kalman Variational Auto-Encoder (KVAE).
  1. The Recognition Model (VAE): A Variational Auto-Encoder compresses high-dimensional video frames ($x_t$) into a low-dimensional latent space ($a_t$). This part handles the "what"—the visual appearance and position of the object.
  2. The Dynamics Model (LGSSM): The latent encodings ($a_t$) are treated as noisy observations for a Linear Gaussian State Space Model. This model tracks the "hidden" state ($z_t$), such as velocity or acceleration, which isn't directly visible in a single frame.
  3. The Dynamics Parameter Network: To handle complex, non-linear movements (like a ball bouncing off a wall), the authors use a Recurrent Neural Network (LSTM) that sits outside the Kalman filter. This network adjusts the Kalman filter's parameters over time. It essentially chooses from a "mixture" of different linear behaviors (e.g., "moving left," "moving right," "bouncing") based on the history of the object's position.
  4. Exact Inference: Because the core dynamics model remains linear (even if its parameters change), the model can use the classical Kalman Smoother. This allows the model to use information from both the past and the future to estimate the state at any given time step.

Datasets

The model was evaluated on several simulated physical systems:

  • Bouncing Ball: A ball moving in a 2D box with elastic collisions (32x32 binary images).
  • Torque-Controlled Pendulum: A standard physics benchmark used to compare against Deep Variational Bayes Filters (DVBF).
  • Complex Environments: An irregular polygon box, a box with gravity, and a "Pong-like" environment where paddles track the ball.

Key Insights and Ideas

  • Disentanglement is Efficiency: By separating recognition from dynamics, the model doesn't need to generate high-dimensional images to "think" about the future. It can perform temporal reasoning entirely within the low-dimensional latent space.
  • The Power of Smoothing: Most RNN-based models only look forward. The KVAE’s ability to perform "smoothing" (looking backward from the future) makes it significantly better at missing data imputation. If you know where a ball starts and where it ends, the KVAE is much better at guessing the path it took in the middle.
  • Linearity as a Constraint: While "deep everything" is a common trend, this paper shows that forcing the dynamics to be locally linear allows for exact, stable mathematical solutions (the Kalman filter) that are often more robust than purely black-box neural approaches.

Key Results

  • Pendulum Benchmark: The KVAE achieved a higher Evidence Lower Bound (ELBO) than competing models like Deep Variational Bayes Filters (DVBF) and Deep Markov Models (DMM), suggesting a better fit for the underlying data.
  • Missing Data Imputation: In experiments where frames were dropped at random or in large chunks, KVAE (with smoothing) consistently outperformed AE-RNNs and VAE-RNNs. Even when 40% of the video frames were missing during training, the model could still learn the underlying physics with minimal performance loss.
Performance comparison on missing data imputation tasks.
  • Qualitative "Imagination": The model successfully learned to transition between different dynamic modes—for example, automatically switching its internal physics matrices when it detected the ball was near a wall.

Limitations and Future Work

The authors acknowledge that their current experiments are limited to simple physical systems with a few moving objects and static backgrounds. The "toy" nature of the 32x32 and 16x16 pixel datasets means it is unclear how well this specific architecture would scale to visually complex, real-world "in the wild" videos (like a busy street scene).

Future directions suggested include:

  • Extending the model to handle more complex, real-world video sequences.
  • Integrating the KVAE into reinforcement learning agents, where the "latent reasoning" could be used for planning future actions.
  • Handling scenes with multiple, interacting objects more explicitly.

Summary updated

BibTeX
@inproceedings{fraccaro2017disentangled,
  author = {Marco Fraccaro and Simon Kamronn and Ulrich Paquet and Ole Winther},
  title = {{A Disentangled Recognition and Nonlinear Dynamics Model for Unsupervised Learning}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2017},
  url = {https://openreview.net/forum?id=ryEt5DWObB},
}
Figure