Hi @ddicostanzo,
I think this not possible as you want to do it in torch. However the way you are solving the problem, i.e., using CNN feature extractor followed by a Flatten layer and fully connected head is not the best choice. Modern neural networks (in computer vision) rely on a global pooling layer instead. I think you should use a similar approach.