Skip to content

A Pytorch library designed to provide tools to identify neural state-space models for control purposes. This library includes control-oriented neural networks architectures. Custom losses including LMI constraints and others.

License

Notifications You must be signed in to change notification settings

Alex-Hache/ctrlnnmod

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

124 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ctrlnmod

This libray intends to provide tools and implementations for control-oriented neural state-space models. Its main features include several models based on Linear Matrix Inequalities (LMI) constraints. Documentation : Documentation Status

Requirements

pip install mosek A personal license file can be asked freely for academics

  • cvxpy v1.4

Currently implemented LMIs

  • Lyapunov alpha stability for continuous and discrete time LTI models
  • $\mathcal{H}^\infty$ norm for continuous and discrete time LTI models see Real Bounded Lemma
  • $\mathcal{H}^2$ norm for both continuous and discrete time LTI models see System H2 norm
  • Lipschitz constant estimation for feedfoward neural networks (with no skip connections) see Pauli et al. 2021

Currently implemented models

From these LMIs one can obtain models with certified properties such as stability, contraction or dissipativity, and incremental boundedness

  • Recurrent Equilibrium Networks (REN) implemented in dsicrete-time only for now see Revay et al. 2023
  • An incrementally bounded (and stable but not globally contractive) of GrNSSM based on real bounded lemma for Taylor Linearizations
  • Parameterized Explicit and semi-Implicit linear state-space models using aforementioned LMIs

Geotorch backend

Finally, the parametrizations involving Positive (Semi-) Definite (PSD) matrices are built using the geotorch library. Since the right inverse methods now involve solving a LMI, cvxpy is now needed, an extended version is then included in this library.

Experiments framework

In order to train networks on data coming from several experiments and trajectories the class ExperimentsDataset encapsulates different experiments and is readily compatible with DataLoader.

Minimalist working example :

A minimalist working example for the simple pendulum can be found in example_pendulum.py

This library is the summary of my PhD's work and is still currently under development.

Future updates

  • Manage compatibility with torchdiffeq integrators
  • Implement stability-based initializations strategies
  • And enabling hessian logging with PyHessian

Feel free to contribute and you can contact me at alexandre DOT hache AT outlook DOT fr

About

A Pytorch library designed to provide tools to identify neural state-space models for control purposes. This library includes control-oriented neural networks architectures. Custom losses including LMI constraints and others.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published