When you will call nn.Maxpool2d(kernel_size,stride) twice on 14x14 input then it will automatically give you the output to be 3x3 as nn.Maxpool2d(kernel_size,stride) uses a floor function.
So you don’t have to avoid explicitly, it is done automatically.