L08 | English F3 Student Learning Log

Persona: I'm a Form 3 (Grade 9) student and I only read English. I know basic Python (variables, for loops, lists) and school algebra up to quadratics. I learn from the official pages, the videos with captions, and the book. Kaggle notebook steps are written as a practice log that follows the official notebooks.

What I understood (in my own words)

  • A convolution slides a small grid over the image, multiplying and adding at each position, to find patterns like edges.
  • Layer one finds lines; layer two combines lines into corners and curves; later layers see more and more complex things.
  • Max pooling keeps the biggest value in each 2×2 block, so the image shrinks but the important features stay.
  • Dropout makes the model 'see less' on purpose so it can't rely on just a few features.
  • After training, embeddings can be analysed, e.g. to find films that even the right audience dislikes.

Where I got stuck, and how I got unstuck

Where I got stuckHow I solved it
How big is the convolution output?A 3×3 kernel fits into a 4×4 image in only 2×2 positions, so the output is 2×2. The rule is 4 − 3 + 1 = 2.
The Excel convolution sheet had too many cellsI picked just the top-left position, worked it out on paper, then compared with Excel.
I didn't understand PCA at allThe lesson says to treat it for now as 'squash many numbers into two so you can plot them'. The theory can wait.

My answers to the exercises

Q1. A 4×4 image has 0s in the top two rows and 9s in the bottom two. Convolve with kernel [[−1,−1,−1],[0,0,0],[1,1,1]] (no padding). What size is the output, what are its values, and what does the kernel detect?

Output is 2×2. Each 3×3 window covers rows of 0, 0, 9 or 0, 9, 9; either way the result is (−1)(0)(3) + 0 + (1)(9)(3) = 27. All four cells are 27. The kernel detects a horizontal edge that is dark above and bright below.

Q2. Apply 2×2 max pooling to [[1,3,2,0],[5,4,1,1],[0,2,8,6],[1,1,3,7]]. Write the result.

Top-left [1,3,5,4] → 5; top-right [2,0,1,1] → 2; bottom-left [0,2,1,1] → 2; bottom-right [8,6,3,7] → 8. Result [[5,2],[2,8]].

Q3. With dropout probability 0.5, what are the surviving values multiplied by during training, and why? Is dropout used at prediction time?

Multiply by 2 (that is 1 ÷ (1 − 0.5)). Half the values are switched off, which would halve the average, so doubling the rest keeps the average the same. At prediction time there's no dropout; every value is kept.

Q4. What does a very low movie bias mean? Why is it more informative than the average rating alone?

It means even people who like that kind of film don't like this one. Average ratings depend on who watches (only horror fans watch horror), but the bias removes that effect, so it shows how good the film itself is.

Q5. In your own words: why can a CNN's second layer detect more complex patterns than its first layer?

First-layer kernels look straight at pixels, so they can only find simple lines and edges. The second layer's input is the first layer's feature maps, so it can combine 'horizontal + vertical line' into 'corner'. Later layers build eyes, wheels and so on.

My Zettelkasten card

Card|Complex recognition is built from layers of simple features

A CNN sees images the way you build with Lego. Layer one only finds horizontal and vertical lines, layer two joins lines into corners and curves, and later layers assemble eyes, wheels and feathers. Each layer is simple, but stacked together they recognise complex things.

It reminds me of learning a kickflip. I kept trying the full trick and kept falling. My friend made me practise each part separately: foot position, the ollie pop, the flick of the front foot, then landing. Once I had each piece, putting them together finally worked. The big difference with a CNN is that nobody tells it what order to learn things in. Its layers learn from the data by themselves, and I'm curious how it 'knows' to learn lines first.

My next step this week: do a vertical-edge convolution by hand on a 6×6 grid, then check it in a spreadsheet.

🔗 Related notes to grow next: → Learning: 'Break complex skills into parts you can practise alone' → Sport: 'Practise the pieces, then chain them together' → Tech: 'Each deeper layer re-describes the layer before it'


Back to lesson note:L08_卷積神經網路_202611041526

Built with LogoFlowershow