University of Technology Malaysia (UTM)
SKEL 4673 - DSP Architectures
Group 4
Ha How Ung, Kenneth Lo, Yeap Eng Jau
Assignment 1
Image processing - noise reduction with 3x3 median filter
Note that this tool is only useable on Windows, and it can only produce grayscale outputs.
C++ compiler (mingw32-gcc-g++)
Python 3
NumPy
Pillow
Matplotlib
- Run the following command in command prompt
cmd.exe
under your desired folder.git clone https://github.com/antonblaise/3x3-median-filter.git
- Double click on the new
3x3-median-filter
folder. - For first time usage after fresh install,
python requirements.py
before using the program. - Place your input image inside the
data
folder, and rename it asinput.png
. - Double click
launcher.bat
to run the program. - The result is generated and saved in both the main directory and the
data
folder asoutput.png
.
Input, grayscaled, and output.
-
Each program file is run in the correct order, with the help of automation using the
launcher.bat
file. So we don't have to run the files one by one every time. The PDF below shows brief explanations of each of the scripts involved.
3x3 Median Filter.pdf -
The
clear_dat.py
is run at the very beginning to remove all the old.dat
files to avoid erroneous overlapping. -
Running
requirements.py
helps to install the packages listed.
- Switched from static to dynamic memory allocation for the huge matrices and vectors to overcome segmentation fault besides improving processing speed.
- Eliminated the usage of
fstream
library, as it causes problems during integration with Vivado HLS.