Class 10 AI Unit 5: Computer Vision – Notes (Pixels, RGB, Convolution, CNN) | CBSE Code 417

Class 10 · AI (417) · Part B · Unit 5
Computer Vision

How computers "see": pixels, resolution, RGB, CV tasks, convolution and CNNs, plus no-code tools like Teachable Machine.

4 Marks (Theory)10 hrs Theory + 20 hrs PracticalPractical Exam Unit
In this chapter
  1. What is Computer Vision?
  2. Applications of CV
  3. CV tasks
  4. Pixels, resolution, grayscale and RGB
  5. Image features and convolution
  6. Convolutional Neural Networks (CNN)
  7. No-code CV tools
📖 Your phone already does this

You look at your phone and it unlocks. You point Google Lens at a flower and it tells you the name. Your Instagram filter puts dog ears exactly on your head, even when you move. None of this is magic: the phone is turning the picture into numbers and finding patterns in them. That's Computer Vision.

1. What is Computer Vision?

🔑 Definition

Computer Vision (CV) is the domain of AI that enables machines to see, understand and interpret images and videos, and take decisions based on them.

2. Applications of CV

🔓

Facial recognition

Face unlock, smart attendance, airport DigiYatra.

🐶

Face filters

Snapchat/Instagram filters track your face in real time.

🔎

Google Lens / search by image

Identify objects, translate text on signboards.

🚗

Self-driving cars

Detect lanes, signals, vehicles and pedestrians.

🩻

Medical imaging

Spot diseases in X-rays and MRI scans.

🛒

Retail

Track stock on shelves and customer movement in stores.

3. Computer Vision Tasks

1. Classification🐱Cat ✔2. Classif. + Localisation🐱Cat3. Object Detection🐱🐶🐱CatDogCat4. Instance Segmentation🐱🐶🐱
Watch each task do a little more: name it → box it → box every object → colour each object's exact shape.
TaskWhat it doesObjectsExample
ClassificationSays what the image is (one label).Single"This is a cat."
Classification + LocalisationSays what it is and draws a box around it.SingleA box around the one cat.
Object DetectionFinds and boxes all objects of different classes.MultipleBoxes around 2 cats and a dog.
Instance SegmentationMarks the exact pixels of each object separately.MultipleEach cat coloured differently, pixel by pixel.

4. How a Computer Sees an Image

Pixels and resolution

What you see Zoomed in: 12 × 12 pixels 🔍 Every digital image ismade of tiny squares
Zoom into any photo on your phone far enough and you'll see the squares: pixels.

A digital image is a grid of tiny squares called pixels (picture elements). Resolution is the number of pixels in width × height, e.g., 1920 × 1080. More pixels = more detail.

6 × 636 pixels12 × 12144 pixels24 × 24576 pixels
Same heart, three resolutions. More pixels = smoother, more detailed image (and a bigger file).

Pixel value

Each pixel stores a number. In the common byte image format, each value is stored in 8 bits (1 byte), so it ranges from 0 to 255 — that's 28 = 256 possible values. 0 = black, 255 = white.

➜ 255255255255255 25502550255 255255128255255 02552552550 255000255
What you see (left) vs what the computer sees (right): just a grid of numbers from 0 to 255.

Grayscale vs RGB images

⬛

Grayscale

Only shades of grey. One value per pixel (0–255). Stored in a single layer/channel.

🌈

RGB (colour)

Each pixel has three values: Red, Green, Blue, each 0–255. So a colour image has 3 channels. Mixing them makes every colour.

ColourRGB
■ Red25500
■ Green02550
■ Yellow2552550
□ White255255255
■ Black000
Colour image Red channel Green channel Blue channel
A colour image is really three layers stacked together. Each layer stores 0–255 for one colour.
🎨 Try it: mix your own colour (drag the sliders)
RGB (255, 136, 0)

5. Image Features and Convolution

Features are the useful parts of an image that help identify it: edges, corners and blobs. Corners are the best features because they're unique; a flat patch of sky is hard to locate.

Original image Edge kernel convolution Feature map: edges & corners
A kernel keeps only the places where colour changes sharply. The yellow dots are corners, the most useful features.
🔑 Convolution

Convolution is an operation where a small matrix called a kernel (filter) slides over the image. At each position, we multiply overlapping numbers and add them up. The result is a new image called a feature map that highlights features like edges.

Image (5×5) × kernel = Feature map (3×3) Each position of the yellow window produces one number in the feature map.
🧮 Solved example

Image patch: [[1, 2, 0], [0, 1, 3], [2, 1, 0]] · Kernel: [[0, 1, 0], [1, −4, 1], [0, 1, 0]]
Multiply matching cells and add: (0×1)+(1×2)+(0×0)+(1×0)+(−4×1)+(1×3)+(0×2)+(1×1)+(0×0) = 2 − 4 + 3 + 1 = 2. This single number goes into the feature map.

6. Convolutional Neural Network (CNN)

A CNN is a deep learning network specially built for images. It has four main layers:

🖼️ Image Convolutionfind features ReLUremove negatives Poolingshrink size Fully Connectedclassify "Cat" 🐱
LayerJob (in simple words)
Convolution layerUses kernels to extract features like edges and textures, creating feature maps.
ReLU layerRectified Linear Unit: changes all negative values to 0, keeping only useful positive features.
Pooling layerReduces the size of the feature map while keeping important info. Max pooling keeps the biggest value; average pooling keeps the average.
Fully connected layerCombines all features to decide the final class of the image.

See ReLU in action

Feature map before ReLU -35-120-47 ⬇ ReLU: negative → 0, positive stays same ⬇ After ReLU 0502007

See max pooling in action

Feature map (4 × 4) 1321465072981534 max of each 2×2 ➜ Pooled map (2 × 2) 6579 16 numbers → 4 numbers, key info kept
The red window visits each 2×2 block and keeps only the biggest number. The image gets smaller but the strongest features survive.

7. No-Code CV Tools (for practicals)

🤖

Teachable Machine

Train an image model with your webcam in minutes. Handbook activity: Smart Sorter (sort waste into recyclable/non-recyclable).

💡

Lobe

Drag in labelled photos; it trains an image classifier automatically.

🪸

Orange (Image Analytics)

Handbook use case: early detection of coral bleaching by classifying healthy vs bleached coral images.

🎮
Try it now: open Teachable Machine → Image Project → make two classes ("Pen" and "Pencil"), record 30 photos of each with your webcam, click Train, and test it live. You just built a CV classifier!
⚠️ Common mistakes

1) Pixel values go from 0 to 255, not 256. 2) "1920×1080" is resolution, not pixel value. 3) Object detection finds multiple objects; classification + localisation handles only one.

Quick Check

Q1. What does 1280 × 1024 describe?

Resolution (pixels in width × height).

Q2. How many channels does an RGB image have?

Three: Red, Green, Blue.

Q3. Which CNN layer reduces the size of the feature map?

Pooling layer.

Q4. RGB value of yellow?

(255, 255, 0)

⚡ One-minute revision

  • CV = AI that understands images and videos.
  • Tasks: classification, classification + localisation, object detection, instance segmentation.
  • Pixel values 0–255 (byte image); resolution = width × height.
  • Grayscale = 1 channel; RGB = 3 channels.
  • Convolution: kernel slides over image → feature map.
  • CNN: Convolution → ReLU → Pooling → Fully Connected.

Done reading? Test yourself on AI Unit 5 in board-exam style.

📝 Take the Practice PaperNext: AI Unit 6 ›🏠 Class 10 Hub

Comments

🧭 Explore AI Topics

Keep learning with our topic guides for CBSE AI (Classes 6–12).

🔄 AI Project Cycle🐍 Python for AI🤖 Machine Learning💬 NLP👁️ Computer Vision⚖️ AI Ethics