title: what is the difference between Flatten() and GlobalAveragePooling2D() in keras
body: <p>I want to pass the output of ConvLSTM and Conv2D to a Dense Layer in Keras, what is the difference between using global average pooling and flatten
  Both is working in my case.</p>
  
  
  
  <pre class="lang-python prettyprint-override"><code>model.add(ConvLSTM2D(filters=256,kernel_size=(3,3)))
  model.add(Flatten())
  # or model.add(GlobalAveragePooling2D())
  model.add(Dense(256,activation='relu'))
  </code></pre>