The average pooling layer were added to a lot of torchvision models to relax the input shape limitation and allow more flexible input shapes.
If you pass the expected 3x224x224 image tensors, then you’ll get the same result as with the original pooling operation.