Global maximum pooling?

I’m using this as last layer

self.final = nn.Sequential(
            nn.MaxPool2d((100,100)),
            nn.Sigmoid()
        )

I had the feeling that there was something wrong at the output, so I checked manually the maximum value it is the same but when applying the sigmoid the results are different.

the input is of size
(64,1,100,100)

Could you post a small script creating this issue?
As far as I understand, the maximal value changes when sigmoid is applied?

Maybe you need to assign one more parameter that stride=1 in MaxPool2d?