Autoencoders

We use the autoencoder introduced in [1]. We assume an orthogonal matrix $\boldsymbol{U}\in\mathbb{R}^{n\times\nu}$ ($\boldsymbol{U}^{T}\boldsymbol{U}=\boldsymbol{I}$), a polynomial $\boldsymbol{W}:\mathbb{R}^\nu\to \mathbb{R}^n$ that starts with quadratic terms up to order $d$. The encoder is the linear map $\boldsymbol{U}^T$ and the decoder is

\[\boldsymbol{W}\left(\boldsymbol{z}\right)=\boldsymbol{U}\boldsymbol{z}+\boldsymbol{W}\left(\boldsymbol{z}\right).\]

To find the autoencoder we first solve

\[\arg\min_{\boldsymbol{U},\boldsymbol{W}}\sum_{k=1}^{N}\left\Vert \boldsymbol{y}_{k}\right\Vert ^{-2}\left\Vert \boldsymbol{W}\left(\boldsymbol{U}\left(\boldsymbol{y}_{k}\right)\right)-\boldsymbol{y}_{k}\right\Vert ^{2}.\]

then solve

\[\arg\min_{\boldsymbol{S}}\sum_{k=1}^{N}\left\Vert \boldsymbol{x}_{k}\right\Vert ^{-2}\left\Vert \boldsymbol{W}\left(\boldsymbol{S}\left(\boldsymbol{U}\left(\boldsymbol{x}_{k}\right)\right)\right)-\boldsymbol{y}_{k}\right\Vert ^{2}.\]

The methods are

FoliationsManifoldsAutoencoders.AENCManifoldType
M = AENCManifold(ndim, mdim, Sorder, Worder, orthogonal = true, field::AbstractNumbers=ℝ)

Creates an autoencoder as a matrix manifold.

The parameters are

  • ndim the dimansionality of the problem $\boldsymbol{F}$
  • mdim dimensionality of the low-dimensional map $\boldsymbol{S}$
  • Sorder polynomial order of map $\boldsymbol{S}$
  • Worder polynomial order of decoder $\boldsymbol{W}$
  • orthogonal whether $D\boldsymbol{W}(0)$ is orthogonal to $\boldsymbol{U}$. When the data is on a manifold true is the good answer.
source
Base.zeroMethod
X = zero(M::AENCManifold)

Creates a zero valued representation of an autoencoder.

source
FoliationsManifoldsAutoencoders.AENCIndentifyFunction
AENCIndentify(dataIN, dataOUT, Tstep, embedscales, freq, orders = (S=7,W=7))

Input:

  • dataIN is a two dimensional array, each column is an $\boldsymbol{x}_k$ value,
  • dataOUT is a two dimensional array, each column is an $\boldsymbol{y}_k$
  • Tstep is the time step between $\boldsymbol{x}_k$ and $\boldsymbol{y}_k$
  • embedscales, denoted by $\boldsymbol{w}$ is a matrix applied to $\boldsymbol{x}_k$, $\boldsymbol{y}_k$, used to calculate the amplitude of a signal
  • freq is the frequency that the invariant foliation is calculated for.
  • orders is a named tuple, specifies the polynomial order of $\boldsymbol{S}$ and $\boldsymbol{W}$.

Output is a tuple with elements

  1. vector of instantaneous frequencies
  2. vector of instantaneous damping
  3. vector of instantaneous amplitudes
  4. the scaling factor that was used to fit all data into the unit ball
  5. uncorrected vector of instantaneous frequencies
  6. uncorrected vector of instantaneous damping
  7. uncorrected vector of instantaneous amplitudes
source
  • 1M. Cenedese, J. Axås, B. Bäuerlein, K. Avila, and G. Haller. Data-driven modeling and prediction of non-linearizable dynamics via spectral submanifolds. Nat Commun, 13(872), 2022.