0

I'm almost newbie at PyTorch

One of my output size from conv is [1, 25, 8, 32] (25=channel, 8=height, 32=width)

I can use squeeze and make it to [25, 8, 32].

But I'm confused with 25 channel.

When I want to visualize sum of 25 channel and make to one GRAYorRGB image(1or3x8x32),How can i deal with in code??

I can use matplot or tensorboardX for visualizing..

yKim
  • 63
  • 4
  • I think you usually just visualize the channels separately like [this one](https://www.researchgate.net/figure/Deep-features-visualization-a-output-feature-maps-and-b-convolution-kernels-of-the_fig3_320461081) – ddoGas Feb 27 '20 at 14:49

1 Answers1

2

It is difficult to visualize images with more than 3 channels and it is unclear what a feature vector in 25 dimensional space actually looks like.

The most straight forward approach would be to visualize the 8x32 feature maps you have as separate 25 gray scale images of size 8x32. Each image will show how how "sensitive" is a specific neuron/conv filter/channel (these are all equivalent) to the input at a certain spatial location.

There are more intricate methods for feature visualization, you can find more details about them in this blog post.

Shai
  • 111,146
  • 38
  • 238
  • 371