Chapter 1 / 6
โฆ 0 XP
Chapter 1 / 6
Downsample the array
New here? Read the 60-sec briefing โThe sensor feed is too dense to process at full rate. Pool each pair of readings down to the stronger one, halving the data while keeping the signal.
Pooling is a windowed reduce. Max-pooling halves resolution while keeping the strongest activation, the exact downsampling step inside a CNN.
YOUR TASK
- 1Each core owns one output cell covering inputs 2*i and 2*i + 1.
- 2Write the larger of the pair into out[i].
๐ก Keep the strongest of each window: out[i] = max(inp[2*i], inp[2*i + 1]).
DEFINITIONS
- max-pooling
- โ A downsampling step that slides a small window across the data and keeps only the largest value in each window, shrinking the array while preserving the strongest signal.
- downsampling
- โ Reducing the resolution of a signal or feature map by collapsing groups of values into one, which cuts the work for every later layer.
- activation
- โ A single value in a neural network's feature map, the output of one unit. Max-pooling forwards the strongest activation in each window.
core_11_pooling.mojo
PUZZLE 11 ยท POOLINGClear all 6 chapters to forge๐ก Systems Core Shard