How to get/visualise each layer?

How to get each of these layer output in a single image using pytorch.
Just like a [ keract library used for the TensorFlow model visualize each of these output layers.