Image convolution using Message Passing Interface (MPI)
Application of convolution kernels such as sharpening, blurring, edge detection to grayscale images in parallel using MPI. This is a C++ project that performs convolution operations such as blurring, sharpening, or edge detection to greyscale images and utilize Message Passing Interface (MPI) to perform that in parallel. This project utilizes CMake build system. Assuming one is located at the root of the project, the following snippet details instructions to build the executable. It offers a couple of checks and options that aim to provide flexibility. E.g. This builds the executable that is entirely serialized. Might be more suitable for GNU compiler. The default is This generates the doxyfile that could be used to generate documentation with make. The default is Once the executable is built, the sequential version’s execution is straightforward, provided that the current working directory is In case of the MPI version, the execution is recommended to be through The input file name is, at the moment, supposed to be changed through The following images show the original image with 512 x 512 pixels size, as well as the results upon application of edge detection, gaussian blur, and all three convolutions applied simultaneously. Links
Repository: git/hpc-img-convolution
Link to Documentation
Introduction
Build
mkdir build && cd build
cmake ..
makemkdir build && cd build
cmake -DWITH_MPI=False ..
makeWITH_MPI=True.mkdir build && cd build
cmake -DWITH_DOXYGEN=True ..
make docsWITH_DOXYGEN=False. This however generates the documentation using default theme provided by Doxygen. To get themed documentation as presented here, the working directory should be docs where a separate Makefile is provided which integrates Sphinx. Usage
build as explained earlier../HPC2020mpirun or mpiexec.mpirun -np 2 ./HPC2020main.cpp file only and the file must be present in inputs directory. The generated image can be found in output directory. Showcase

Fig. 1: Original Image 
Fig. 2: Blurred Image 
Fig. 3: Edges detected 
Fig. 4: Sharpened Image