View
109
Download
1
Category
Preview:
DESCRIPTION
For graph partition algorithm used in kmetis and parmetis
Citation preview
Graph Partitioning
Mentor Rohit TalwarDr. Suresh Purini 201001003
Metis
● One of the fastest open source graph partitioners
● Different implementations avaliable -– Sequential
– Open MP
– MPI
● Highly optimized – multi level algorithm
Algorithm - KMetis
● Coarsening – simplifying the graph– Matching: Sorted Heavy Edge Matching applied to
match vertices to a resultant coarse vertice
– Contraction: Edges are collapsed
● Partitioning: Using KL method● Uncoarsening
– Projection: Recreating the bigger graph
– Refinement: Move border vertices to improve cutset
Parallelizing Kmetis using OpenMP
● Coarsening – 2 pass policy– 1st pass: Local unmatched vertices matched
– 2nd pass: Non local matchings pending on each thread's request buffer is accepted or rejected
● Partitioning – recursive k way bisection● Uncoarsening
– Projection: each thread wants to label vertices of bigger graph
– Refinement: Priority queue for each thread● Boundary vertices are divided amongst these threads● Verices are removed from the top of the queue and checked for gain in
cutset value – and are moved only when the weight criteria is adhered to
Sequential KL implementation
● An iteration consists of– Calculating D Values
● For each vertice check its adjacent vertices and calculate external edge and internal edge sum
– Sort D Values– Find next swaps
● Use sorted D values to obtain the next swap(a,b) ● Update D values – 1. Find edges connected to a and b by going
through their adjacency list● Update the D values for these vertices
– Maximize G value
Parallelizing using OpenMP
Show Code
Results
● Increased run time– OpenMP does not allow use of “break” statement
in its for loop constructs
– Hence most loops run completely leading to useless computations
– Presence of Synchronization points/critical sections
– Limited cores
Experimental Results
Graph Metis Sequential
N=58,348 ; M=20,16,578 0.320 s 67 mins
N=40,174 ; M=1,40,831 0.116 s 23 mins
N=32,212 ; M=3,00,801 0.220 s 44 mins
N=10,498 ; M=53,868 0.032 s 58 s
Thanks
Q&A
Recommended