🚀 Comparison between sequential and parallel implementations
This project explores the Mean Shift clustering for image segmentation, comparing a sequential version with a parallel one optimized with OpenMP.
- ✂️ Image segmentation using Mean Shift.
- ⏱️ Performance comparison between sequential and parallel versions.
- 📁 Support for
.jpg,.png, and.bmpimage files. - 💾 Saves results in a dedicated folder.
✅ C++
✅ OpenCV (for image processing).
✅ OpenMP (for parallelization).
✅ MinGW (for compilation).
✅ CMake (for cross-platform builds).
- Add images to the
./imgdirectory. Some sample 512x512 images are already included in the project. - Choose the version to use and run the program.
- Select an image from the list displayed in the terminal (images in the
./imgdirectory) and choose which Mean Shift version to use. - Check the results in the
./img_resultsdirectory and compare the execution time of the chosen version.
💡 The program will display execution times for the selected implementation!
- 📏 Bandwidth: The search window size (larger = less detailed segmentation).
- 🎯 Epsilon: Convergence threshold (smaller = more precise results, but slower).
- 🔍 Resize Factor: Rescales the image for faster testing (1 = no scaling).
Images will be saved in:
./img_results/sequential_segmented_image_X.jpg./img_results/parallel_segmented_image_X.jpg./img_results/resized_image_X.jpg
A copy of the report (in Italian) can be found here📄.
A copy of the presentation can be found here📄.
💡 This project was developed by Giovanni Stefanini as part of the Parallel Computing course.
Mean Shift segmentation applied to the sample images included in the project:
| Original Input | Sequential Segmentation | Parallel Segmentation |
|---|---|---|
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |








