Skip to content
AI & Machine Learning Simple #pooling#cnn#downsampling

Pooling: Max & Average

Pool 2x2 to one value. Spatial downsample, translation tolerance.

A free, animated pooling: max & average you can read here or embed on any website, from Scrollchart.

Pooling: Max & Average

Pooling: Max vs Average2x2 kernel, stride 2 -- 4x4 feature map halved to 2x2 in each dimensionInput 4x4Max Pool 2x2Avg Pool 2x21324561232781053stride = 2 (no overlap)max()6438Keeps strongest signaltranslation-invariant detectionmean()3.82.31.55.8Smooths feature mapGAP used before classifier head2x2 output2x2 outputSpatial dims halved each pool layer: 224x224 image reaches 7x7 after 5 max-pool ops in VGG

A feature map reduced by 2x2 max pooling and 2x2 average pooling. Each cell of the output is the max or mean of the corresponding 2x2 window. Stride and overlap variants shown.

Good for

  • Intro CNN tutorials explaining spatial downsampling and receptive-field growth through pooling
  • Architecture explainers for VGG, ResNet, and MobileNet comparing max pool, avg pool, and stride-2 convolution as downsampling strategies
  • Global Average Pooling articles explaining how GAP replaces FC layers and enables variable-resolution inference

Source & accuracy

This pooling: max & average is an editorial illustration built to represent the concept accurately. Where it shows figures, they are typical or representative values chosen to make the relationship clear, not a single underlying dataset. The diagram and its explainer are reviewed and maintained centrally, and updated over time as understanding improves.

Spatial downsampling through aggregation

Pooling layers reduce spatial dimensions by aggregating regions of the feature map into single values. Max pooling takes the largest value in each non-overlapping region (typically 2x2), discarding the others. Average pooling takes the mean. A 64x64 image pooled with 2x2 becomes 32x32. Pooling reduces computation, memory, and parameters for downstream layers. It also provides translation invariance: if an object shifts by a pixel, max pooling in that region still captures its presence. Early CNNs heavily used pooling; modern architectures use it less and prefer strided convolutions for downsampling, which are learnable and often more expressive.

Tradeoffs with learned alternatives

Max pooling is nonsmooth and non-differentiable (gradients are sparse), but the flow-through version used in backprop approximates the gradient. Average pooling is smooth but loses spatial specificity: the presence of a high-activation edge is collapsed to the same pool value as a high-activation region elsewhere. Strided convolution (advancing the kernel by 2 steps instead of 1) also downsamples and is learnable, but adds parameters. Modern best practice for CNNs uses strided conv for spatial reduction with occasional max pooling in specific layers. Vision transformers sidestep the question entirely by patchifying the image upfront, avoiding explicit pooling until the end (global average pooling before classification).

Embed this diagram

Add this animated pooling: max & average to your own site. Copy one line of HTML, or use the embed builder for theme and sizing options.

Reference

What this is
A free, embeddable, animated pooling: max & average for any website.
Who uses it
AI/ML blogs, CS educators.
How to embed
Copy one line of HTML. No signup. No watermark. Works in WordPress, Webflow, Ghost, Substack, plain HTML.
File size
iframe embed, ~80 KB gzipped (loads on demand, does not block your page paint).
License
Free forever. Editorial explainer text included; updated centrally over time.

Embed format options

Copy the universal HTML snippet, the WordPress shortcode, or an iframe fallback - see the WordPress plugin page for details. Any format keeps the same Core Web Vitals profile and the same explainer text.

Embed snippet
<div data-scrollchart="pooling-layer" data-scrollchart-v="1"></div>
<script src="https://scrollchart.com/embed.js" async></script>

Frequently asked questions

Where can I get a free animated "Pooling: Max & Average" for my website?
Scrollchart provides "Pooling: Max & Average" as a free, embeddable animated diagram you can add to any website with one line of HTML. No signup is required and there is no watermark. The diagram and its explainer text are served from scrollchart.com, so the embed stays current without any maintenance on your end.
How do I embed a pooling: max & average in a developer or tech blog?
Copy the one-line snippet from the Scrollchart diagram page and paste it into your post HTML. It works in any static site generator, CMS, or hand-coded HTML page. The embed is a thin loader, not an iframe, so the content is fully in your DOM.