Image analysis and pattern recognition
EE-451
Media
Objectives of this course:
Learn the basic methods of digital image analysis and pattern recognition: pre-processing, image segmentation, shape representation and classification. These concepts will be illustrated by applications in computer vision and medical image analysis.
2025 Schedule: Fridays, morning (8:15am - 12:00am)

Labs:
The lab materials will be available through the public GitHub repository: https://github.com/LTS5/iapr2025. Lab assignments are designed to develop practical implementation skills related to the topics covered in class and serve as preparation for the final project. This project will be a hands-on application of the concepts learned throughout the course.
Labs are provided as Jupyter Notebooks and must be completed in groups of three students. Please form your groups on Moodle before March 7th. Note that the same groups will be used for the final project later in the semester.
We highly recommend consulting the
- Q&A Forum (Forum)
- News Forum (Forum)
- Group choice IAPR 2025 (Group choice)
- Final Project Presentation Date Poll (Choice)
- Interview schedule - Zoom (regularly updated) (Page)
- List of questions for the interview (oral exam) (Page)
Lecture 1 : introduction and pre-processing
- introduction (File)
- Lecture 1 - pre-processing (File)
- Video recording of the introduction 2025 (URL)
- Video recording of lecture 1 (2020) (URL)
Lecture 2: image segmentation
Lab 1: Image segmentation
Use the same notebook to write your code and discussions. The routine(s) from the second part may be useful for the final project, so pay close attention.
Submission Details
- Work in groups of three and submit one lab per group.
- Deadline: March 19th at 23:59 (submission box below).
- The report will be graded—ensure all group members' names and SCIPER are included.
- Verify your code by rerunning the notebook before submission.
- Follow the naming convention: lab_1_group_<group_id>.ipynb
- The notebook will be rerun with the provided libraries. No additional packages are allowed.
Lecture 3: active contours
Lecture 3: object description
Lecture 4: classification
Lab 2: Object description
The Lab 2 is available on GitHub IAPR: https://github.com/LTS5/iapr2025
Use the same notebook to write your code and discussions.
Submission Details
- Work in groups of three and submit one lab per group.
- Deadline: April 9th at 23:59 (submission box below).
- The report will be graded—ensure all group members' names and SCIPER are included.
- Verify your code by rerunning the notebook before submission.
- Follow the naming convention: lab_2_group_<group_id>.ipynb
- The notebook will be rerun with the provided libraries. No additional packages are allowed.
Lab 3 : Classification
The Lab 3 is available on GitHub IAPR: https://github.com/LTS5/iapr2025
Use the same notebook to write your code and discussions. The routine(s) from the second part may be useful for the final project, so pay close attention.
Submission Details
- Work in groups of three and submit one lab per group.
- Deadline: April 16th at 23:59 (submission box below).
- The report will be graded—ensure all group members' names and SCIPER are included.
- Verify your code by rerunning the notebook before submission.
- Follow the naming convention: lab_3_group_<group_id>.ipynb
- The notebook will be rerun with the provided libraries. No additional packages are allowed.
Lecture 5 - Introduction to Deep Learning
Final project
🍫 IAPR 2025 – Final Project Overview
The final project for IAPR 2025 will assess your skills in image analysis and pattern recognition. Your task is to implement a chocolate detector that can count chocolates of predefined types in an image.
🏆 Project Format: Kaggle Competition
This project will run as a Kaggle competition, where you will:
-
Access training and testing data;
-
Submit predictions and track your performance on a public leaderboard;
-
Compete for fun!
⚠️ Note: The Kaggle public leaderboard is not part of the official grading, while the private leaderboard (released one day after the deadline) is: you'll have to beat the TA's baseline to get the points. Additionally, top-performing teams will receive bonus points and chocolate boxes! 🎁
You are free to use any techniques covered in the course—from classical image processing methods to advanced deep learning models. However, since deep learning approaches often yield significantly stronger results, and this is not primarily a deep learning course, we have created two separate Kaggle challenges to ensure a fair comparison across methods:
-
Chocolate Recognition (Classic)
➤ Invitation Link: https://www.kaggle.com/t/316191fa57da43df8464e49cde94745b
For solutions not using deep learning -
Chocolate Recognition (Deep Learning)
➤ Invitation Link: https://www.kaggle.com/t/fffe48b6588d4ffe86afae15ea498524
For solutions using deep learning
👉 Read the rules of your selected challenge carefully to understand the allowed resources and constraints.🚨 You must choose one challenge to participate in. You may switch between challenges at any point during the project period.
👉 To access the links, please sign in to Kaggle using the "Sign in With Email" option and use your EPFL email address.
📦 Submission Requirements
Each group must submit a
Your archive must include the following:
1. 📝 Jupyter Notebook Report
The report is a critical component of your project. It must focus on:
-
Clear justification of design choices, explaining how each component in your method contributes to performance;
-
Detailed technical descriptions of your solution;
-
Strong quantitative and qualitative analysis, demonstrating and explaining the ability of your solution to segment the chocolates from the background and to compute relevant descriptors for each chocolate type, through means of metrics and visualizations (e.g. confusion matrix, class response heatmaps, clustering metrics, high-dimensional separability, learned filter visualization, etc.)
🚨 The report must be about only one of the two challenges.
2. 🐍 main.py(Executable Script)
This script should:
-
Produce the exact submission file uploaded to Kaggle;
-
Use only Python packages covered in Labs 1–3 (Python 3.9).
ℹ️ Info: An environment file is provided in the project folder on the GitHub repo for you to create an environment with the allowed packages.
⚠️ Note: The reproducibility of your Kaggle submission is part of the grade!
3. 📁 src/Folder
Include all additional code and files used by
If using deep learning, you may also include your model checkpoints, ensuring they can be loaded correctly.
📤 Submission Instructions
-
Work in groups of three – one submission per group
-
📅 Deadline: May 21st at 11:59 PM;
-
🧾 Include the names and SCIPERs of all group members in your report, as well as the challenge you chose to participate in;
-
🗂️ Use the following naming convention:
final_group_<group_id>_<kaggle_group_name>.zip<span style="color:rgb(51,51,51);">.</span>
🗣️ Final Presentation
Each group will deliver a 7-minute presentation followed by an 8-minute Q&A with the TAs. TAs will read your report beforehand and prepare specific questions based on your work. Your presentation should:
Summarize your approach and design decisions;
Highlight your main results;
Be ready to answer questions on any part of your pipeline.
🗓️ Date: Friday, May 23rd
🕗 Time: Between 8:00 AM – 1:00 PM
📍 Location: In person (see detailed schedule below)
| Time | ELD 016 | ELD 138 | ELD 120 | DIA 003 |
|---|---|---|---|---|
| 8h00 | Group 22 | Group 50 | Group 44 | Group 43 |
| 8h15 | Group 14 | Group 10 | Group 9 | Group 2 |
| 8h30 | Group 37 | Group 4 | Group 52 | Group 55 |
| 8h45 | Group 75 | Group 64 | Group 46 | Group 47 |
| 9h15 | Group 23 | Group 39 | Group 1 | Group 12 |
| 9h30 | Group 5 | Group 40 | Group 34 | Group 35 |
| 9h45 | Group 33 | Group 80 | Group 74 | Group 31 |
| 10h00 | Group 13 | Group 24 | Group 26 | Group 77 |
| 10h30 | Group 7 | Group 32 | Group 38 | Group 19 |
| 10h45 | Group 69 | Group 20 | Group 48 | Group 51 |
| 11h00 | Group 15 | Group 8 | Group 73 | Group 17 |
| 11h15 | Group 18 | Group 67 | Group 25 | Group 66 |
| 11h45 | Group 21 | Group 41 | Group 56 | - |
| 12h00 | Group 11 | Group 3 | Group 36 | Group 27 |
| 12h15 | Group 49 | Group 42 | Group 29 | Group 30 |
| 12h30 | Group 60 | Group 28 | Group 16 |
📚 Project Resources
📊 Grading Scheme (100 Points)
| Category | Criteria | Points |
|---|---|---|
| 1. Report | Design justification. | 20 |
| Technical implementation. | 10 | |
| Qualitative analysis (segmentation/object description). | 30 | |
| 2. Kaggle Performance | Beat TA’s baseline in your challenge. | 10 |
| 3. Reproducibility | Executable produces same submission as on Kaggle. | 10 |
| 4. Presentation | Clarity of presentation and quality of answers. | 20 |
| 5. Bonus / Penalty | Top-5 ranking bonus / rule violation penalty. | ±X |
🏅 Bonus Points (Kaggle Ranking)
| Rank | Bonus Points |
|---|---|
| 🥇 1st | +10 + 🍫 |
| 🥈 2nd | +7 |
| 🥉 3rd | +5 |
| 4th | +3 |
| 5th | +1 |
🚫 Penalties
-
Violation of Kaggle rules: –50 points