Yeah it will.
You can also use convolutions instead of max pooling, you’ll have to manually create Conv2d later and the fully connected layer instead of average pooling. (As they say then entire network is hyperparameter)