Open main menu

CDOT Wiki β

Changes

GPU610/SSD

644 bytes added, 15:35, 19 April 2013
Closest Pair
GPU: nVIDIA GEFORCE GT 620
== Closet Closest Pair ==
'''Unfortunately we had to abandon the project since it was not really compatible with CUDA(there is no time to look more into it as the semester is almost over...). Team TudyBert, who are also working on the same project, have found that CUDA uses dynamic libraries where Dirve_God_Lin uses static libraries and there isn’t much to be done about that. As a result, we will be using Stephanie’s closet pair program.'''
The closet closest pair problem can be explained simply by imagining a random set of points spread in a [http://en.wikipedia.org/wiki/Metric_space metric space]. Now the process of finding two points with the smallest distance between them is called the closet closest pair problem.
One of the more common algorithm algorithms used to find the closet closest pair is the Brute-force algorithm; which is calculating the distances of all the point points ( O(n^2) notation):
n=total number of pintspoints
n(n-1)/2
then simply look for the pair of points that has the smallest distance between each other. However, this algorithm was evident to be slow.
This is the function used in the closestPair.c program that Stephanie used for here her assignment 1:
double brute_force(point* pts, int max_n, point *a, point *b)
}
This is the profile:
Flat profile:
Each sample counts as 0.01 seconds.
% cumulative self self total
time seconds seconds calls ms/call ms/call name
99.78 41.58 41.58 16384 2.54 2.54 brute_force
0.14 41.64 0.06 closest
0.05 41.66 0.02 cmp_x
0.02 41.67 0.01 cmp_y
 
 
System specifications:
OS: Ubuntu 12.04 32-bit
CPU: Intel(R) Core 2 Duo(R) CPU E4600 @ 2.40GHz x 2
RAM: 2GB DDR2
GPU: nVIDIA GEFORCE GT 620
As a consequence, we presume “parallellazing” this algorithm that by making the brute force function parallel using CUDA technology will speed up the process significantly.
Github link [https://github.com/sezar-gantous/GPU610-ClosestPair here]
=== Assignment 3 ===
1
edit