keras/src/layers/pooling/global_average_pooling2d.py/GlobalAveragePooling2D/call
class GlobalAveragePooling2D:    def call(self, inputs):
        if self.data_format == "channels_last":
            return ops.mean(inputs, axis=[1, 2], keepdims=self.keepdims)
        return ops.mean(inputs, axis=[2, 3], keepdims=self.keepdims)