Reputation: 4152
Is there any significance difference between the Pooling
layers. There are two types of Max and Average Pooling ( except 1,2,3-D ) basically named GlobalPooling
and (normal)Pooling
. In the documents provided by Keras, there is not so much difference and explanation provided.
What is the difference among the different layers?
Upvotes: 0
Views: 1743
Reputation: 2430
Normal pooling layers do the pool according to the specific pool_size
, stride
, and padding
.
For example
inp = Input((224, 224, 3))
x = MaxPooling()(x) # default pool_size and stride is 2
The output will has shape (112, 112, 3)
.
Global pooling is like, make the pool size equal to width and heigth, and do flatten. If input shape is (224, 224, 3)
you will get a tensor shape (3)
, if input is (7, 7, 1024)
you will get a (1024)
.
Upvotes: 1