openai / glow

Code for reproducing results in "Glow: Generative Flow with Invertible 1x1 Convolutions"
https://arxiv.org/abs/1807.03039
MIT License
3.11k stars 515 forks source link

Meaning 1x1 convolution as generalization for permuation #104

Closed working12 closed 2 years ago

working12 commented 3 years ago

Hi, In the paper there is a line saying "Note that a 1 × 1 convolution with equal number of input and output channels is a generalization of a permutation operation."

I don't understand how this is the case? Can anybody explain or show me things so that I can understand this?

p0p4k commented 2 years ago

Hey, did you understand this?

gitfourteen commented 6 months ago

Permutation in matrix is about exchanging rows or columns. Glow generalizes this idea to manipulate tensor along channel dimension without changing its size. Generally, this operation is not exchanging rows or columns but fusing all to one multiple times(e.g., #output channels).