All models

freia_glow_coupling

The affine coupling block from Glow, an invertible layer for flow-based generative models, built with FrEIA.

Diffusion and generative · 265 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (25 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
2.7M
Operations
265
Framework
PyTorch
Recurrent
No
Published
NeurIPS 2018
Cited by
825 (as of 23 October 2026)
Authors
Diederik P. Kingma, Prafulla Dhariwal
License
MIT
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m5084
Graph hash
b6171c449a73da2cb1f3106fad3d03ea832b66a79d28ea1ed742fc916b11f42c
Skeleton hash
9df9c52f734182799c87abcbba10fce6b08ecd7654257fc35c7b347091ed037b
Architecture hash
05be153475bc786cf175bcfbf20c5927157c836aac3be7cc17d1ae4ac0c007b8
Diagram SHA-256
06730b57e975387739913208fa66664f34ac8b6d68221f9f7b145692a7c2bdf4
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

This model chains 8 coupling blocks in sequence, the way FrEIA constructs an invertible network from simple invertible building blocks.

About this model's family

This model is the affine coupling layer on its own, which in Glow, a flow-based generative model, is the last part of each step of flow, after actnorm and an invertible 1 × 1 convolution. It is assembled with FrEIA, a framework for constructing invertible neural networks from simple invertible building blocks.

The layer splits its input into two halves, runs one half through a neural network that returns a log-scale and a shift, and applies that scale and shift to the other half, while the first half passes through unchanged. The paper describes it as a reversible transformation whose forward function, reverse function and log-determinant are all computationally efficient. The log-determinant is the change in log-density that the transformation causes. An additive coupling layer is the special case with a scale of 1 and a log-determinant of 0.

Glow itself builds on the earlier NICE and RealNVP flows. In the paper's CIFAR-10 comparison, the affine coupling models converge faster than the additive coupling models.

Key idea. The paper proposes Glow, a generative flow using an invertible 1x1 convolution, in which each step of flow ends with the coupling layer this model implements.

  • glow affine coupling block
  • glowcouplingblock
  • affine coupling layer
  • coupling layer
  • glow
  • normalizing flow
  • flow-based generative model
  • invertible neural network
  • freia

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{kingma2018glowgenerativeflowinvertible,
      title={Glow: Generative Flow with Invertible 1x1 Convolutions}, 
      author={Diederik P. Kingma and Prafulla Dhariwal},
      year={2018},
      eprint={1807.03039},
      archivePrefix={arXiv},
      primaryClass={stat.ML},
      url={https://arxiv.org/abs/1807.03039}, 
}