Parallel Implementation of Similarity Measures on GPU Architecture using CUDA Kuldeep Yadav Department of Computer Science and Engineering College of Engineering Roorkee, Roorkee-247667, INDIA Kul82_deep@rediffmail.com Ankush Mittal Department of Computer Science and Engineering College of Engineering Roorkee, Roorkee-247667, INDIA dr.ankush.mittal@gmail.com 2 M.A Ansari Department of Electrical and Engineering Gautam Budha University, Greater Noida, INDIA ma.ansari@.ieee.org VennkteshVishwarup Department of Computer Science and Engineering College of Engineering Roorkee, Roorkee-247667, INDIA vnktshv@rediffmail.com Abstract- Image processing and pattern recognition algorithms take more time for execution on a single core processor. Graphics Processing Unit (GPU) is more popular now-a-days due to their speed, programmability, low cost and more inbuilt execution cores in it. Most of the researchers started work to use GPUs as a processing unit with a single core computer system to speedup execution of algorithms and in the field of Content based medical image retrieval (CBMIR), Euclidean distance and Mahalanobis plays an important role in retrieval of images. Distance formula is important because it plays an important role in matching the images. In this research work, we parallelized Euclidean distance algorithm on CUDA. CPU with IntelĀ® Dual-Core E5500 @ 2.80GHz and 2.0 GB of main memory which run on Windows XP (SP2). The next step was to convert this code in GPU format i.e. to run this program on GPU NVIDIA GeForce series 9500GT model having 1023 MB of video memory of DDR2 type and bus width of 64bit. The graphic driver we used is of 270.81 series of NVIDIA. In this paper both the CPU and GPU version of algorithm is being implemented on the MATLAB R2010. The CPU version of the algorithm is being analyzed in simple MATLAB but the GPU version is being implemented with the help of intermediate software Jacket-win-1.3.0. For using Jacket, we have to make some changes in our source code so to make the CPU and GPU to work simultaneously and thus reducing the overall computational acceleration . Our work employs extensive usage of highly multithreaded architecture of multi- cored GPU. An efficient use of shared memory is required to optimize parallel reduction in Compute Unified Device Architecture (CUDA), Graphic Processing Units (GPUs) are emerging as powerful parallel systems at a cheap cost of a few thousand rupees. Keywords: Euclidean distance, Mahalanobis Distance, Content Based Medical Image Retrieval (CBMIR), CUDA, GPU, Parallelization 1. INTRODUCTION Content-based image retrieval (CBIR) has gained considerable attention especially in the last decade. Image retrieval based on content is extremely useful in several applications such as medicine, publishing and Kuldeep Yadav et al / Indian Journal of Computer Science and Engineering (IJCSE) ISSN : 0976-5166 Vol. 3 No. 1 Feb -Mar 2012 1