# Attend, Infer, Repeat

*19 February 2018*

## Generative network

Here is a pseudocode for the generative network where the observation is an image and are all the latent variables in the execution trace.
contains parameters of various neural nets in the generative network.

- Initialize the image mean ,
- While :
- .

where is an inverse Spatial Transformer Network, and the a parametric function.

## Inference Network

Here is a pseudocode for the inference network .
contains parameters of various neural nets in the inference network.

- Initialize the hidden state for the LSTM cell ,
- ,
- While :

where is a Spatial Transformer Network, and the LSTM cell takes in an (input, hidden state) pair and outputs an (output, next hidden state) pair.

[back]