Parallel implementation, in CUDA, of Corner Detection in images using Gauss and Sobel filters.
Input: RGB image in .ppm format.
Output: Grayscale image with corners detected in .ppm format. Will be located in output folder.
Compilation and testing can be performed directly from makefile or with the following commands:
-
Compilation:
nvcc CornerDetector.cu -o CornerDetector
-
Execution:
./CornerDetector <imagePath> <gaussMask=size> <tpb=threadsPerBlock> <sigma=doubleValue>
<imagePath>
Path where the image is located.
Example: ../input/imageName.ppm
<gaussMask=size>
Size of the gaussian mask.
Default value = 7
Example: gaussMask=7 -> will generate a 7x7 gaussian mask
<tpb=threadsPerBlock>
Threads per block used in both Gauss and Sobel kernels.
Default value=32
Example: tpb=16 -> 16x16, tpb=32-> 32x32,etc.
<sigma=doubleValue>
Sigma value used in gaussianMask generation.
Default value=1.5
Example: sigma=0.5
Examples of execution:
./CornerDetector ../input/image1.ppm gaussMask=9
./CornerDetector ../input/image2.ppm gaussMask=7 tpb=32
./CornerDetector ../input/image3.ppm gaussMask=5 tpb=16 sigma=0.5