Skip to content

A review of HAVOK and Reservoir computing for chaotic dynamics forecast

License

Notifications You must be signed in to change notification settings

baronefr/rhavok-analysis

Repository files navigation

HAVOK & Reservoir computing for chaotic dynamics forecast

Group 2202 // Barone, Nagaro, Ninni, Valentini
Referee // Prof. Jeff M. Byers, Naval Research Laboratory, Washington (linkedin)

This is our final project for Laboratory of Computational Physics (module B). In this work, we review two dynamical systems analysis techniques and explore whether it is possible to use them in chaotic dynamics forecast.

The first technique is the Hankel Alternative View Of Koopman (HAVOK) analysis, based on a paper by S. Brunton et al, 2017. At first, we develop the framework to achieve the same results shown in the paper; then we discuss some features of the new coordinate space.

The second technique in our review is reservoir computing. Reservoir computing is an excellent machine learning tool for analyzing dynamical systems in a data driven fashion. The reservoir computing algorithm uses randomly sampled matrices for defining an underlying recurrent neural network, which has a pool of interconnected neurons (which make the reservoir), an input layer feeding observed data to the network, and an output layer with weights assigned to the network states. Recently, theoretical results demonstrated the equivalence between reservoir computing and the nonlinear vector autoregression. Nonlinear vector autoregression has the advantage of being computationally much less demanding, and of providing interpretable results. In this work, we used nonlinear vector autoregression in order to make predictions on the behavior of the Lorenz attractor.


In this review, we probe the two techniques above to characterize the dynamics reconstruction accuracy & prediction capabilities. Our results are benchmarked on a Lorenz attractor system. Eventually, we provide a demo which uses HAVOK to issue a trigger that prevents the Lorenz attractor to switch lobes. To achieve this, we train a Reinforcement Learning model to interact with the Lorenz system.

HAVOK sentinel reinforced model

The following demo implements a trigger for chaotic dynamics control. The acting model is a Deep Deterministic Policy Gradient built in Keras, whereas the sentinel model is a thresholded HAVOK coordinate. In other words, when the coordinate computed through the HAVOK analysis (on a moving window) exceeds a given threshold, the actor model is triggered to execute an action that prevents the Lorenz attractor to switch lobes.

Watch the video
click to open on YouTube


usage of rhavok

rhavok is a small library we use to collect all the common routines required by this work. You can install the library in development mode running the following command from current directory:

pip install -e ./lib/

Then, the library will by available on your system through the usual import fashion:

import rhavok

You may find some documentation on it, provided as Jupyter notebooks (doc_*.ipynb) inside the lib_rhavok folder.


Workflow summary

HAVOK analysis

workflow_havok

Reservoir Computing

workflow_reservoir

Picture from 10.1038/s41467-021-25801-2.


Bibliography

Lab of Computational Physics (module B) project
AY 2021/2022 University of Padua

About

A review of HAVOK and Reservoir computing for chaotic dynamics forecast

Topics

Resources

License

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •  

Languages