We can model distributions using neural networks in two ways:

Deterministic way

In this way the output of neural network is a sample from the distribution.

Image Description

Probabilistic way

In this way the output of neural network are parameters of the distribution.

Image Description