MCPcopy Create free account
hub / github.com/PaddlePaddle/Paddle / _pool_flops

Function _pool_flops

python/paddle/utils/flops.py:371–377  ·  view source on GitHub ↗

FLOPs computation for pool op. For pool(input): equation: flops = (numel)total number of elements in the input tensor.

(input_shapes, attrs)

Source from the content-addressed store, hash-verified

369
370@register_flops("pool")
371def _pool_flops(input_shapes, attrs):
372 """FLOPs computation for pool op.
373 For pool(input):
374 equation: flops = (numel)total number of elements in the input tensor.
375 """
376 input = input_shapes.get('X')[0]
377 return prod(input)

Callers

nothing calls this directly

Calls 2

prodFunction · 0.70
getMethod · 0.45

Tested by

no test coverage detected