Coupling flows divide the input into two parts so that and define the flow as:
Here is an elementwise flow (or other invertible layer) with parameters that are themselves a nonlinear function of the inputs . The function is usually a neural network of some kinda and does not have to be invertible.

The original variables can be recovered as:
If the function is an elementwise flow, the Jacobian will be lower triangular with the identity matrix in the top-left quadrant and the derivatives of the elementwise transformation in the bottom right. Its determinant is the product of these diagonal values.
With coupling flows, the inverse and Jacobian can be computed efficiently, but this approach only transforms the second half of the parameters in a way that depends on the first half. To make a more general transformation, the elements of are randomly shuffled using permutation matrices between layers, so every variable is ultimately transformed by every other. In practice, these permutation matrices are difficult to learn. Hence, they are initialized randomly and then frozen. For structured data like images, the channels are divided into two halves and and permuted using 1x1 convolutions.