concept flow in category Keras

This is an excerpt from Manning's book Probabilistic Deep Learning: With Python, Keras and TensorFlow Probability.
But how to set up and fit a flexible high dimensional distribution? Think, for example, of color images with 256 x 256 x 3 = 195,840 pixels defining a 195,840 dimensional space, where each image can be represented by one point. If you pick a random point in this space, then you’d most probably get an image that looks like noise. This means the distribution of realistic images like facial images only covers a subregion, which might not be easy to define. How can you learn the 195,840 dimensional distribution from which facial images can be drawn? Use normalizing flows! In a nutshell, an NF learns a transformation (flow) from a simple high dimensional distribution to a complex one. In a valid distribution, probabilities need to sum up to 1 in the discrete case, or the integral needs to be 1 in the continuous case, and these need to be normalized. The flows in NFs keep this normalizing property intact. Hence, the name normalizing flow or NF for short.
Figure 6.14 The histogram of the Old Faithful geyser waiting times (filled bars), along with the fitted density distribution (solid line). The histogram doesn’t show the shape of a simple distribution such as a Gaussian. A flow of five layers captures the characteristics of the data well (solid line)
![]()