Parallel Graph & Mesh Partitioning

Discussions about the routines in ParMETIS

Hi!

I'm trying to use ParMETIS to partition a graph stored in a compatible file.
To do that, I'm using ParMETIS_V3_PartKway. It works perfectly with graphs containing 64, 128 or 256 vertices. But every case containing more than 256 vertices raise a segmentation fault. I use my own code to call ParMETIS_V3_PartKway but the "parmetis" binary included with ParMETIS give me exactly the same result. I call it like this : ./parmetis 1024_parmetis.graph 1 8 0 0 0 0 and it gives me that :

[fourmi048:27917] [ 0] /lib64/libc.so.6 [0x7ffff6caa6e0]
[fourmi048:27917] [ 1] ./parmetis(libmetis__CreateCoarseGraphNoMask+0x2fd) [0x46999c]
[fourmi048:27917] [ 2] ./parmetis(libmetis__CreateCoarseGraph+0xb8) [0x468c8c]
[fourmi048:27917] [ 3] ./parmetis(libmetis__Match_SHEM+0x66d) [0x468af1]
[fourmi048:27917] [ 4] ./parmetis(libmetis__CoarsenGraph+0x1b9) [0x467c2d]
[fourmi048:27917] [ 5] ./parmetis(libmetis__MultilevelBisect+0xa0) [0x460b6f]

Hi,
I tried to install and use ParMETIS 4.0.2 but the header
metis.h does not get installed. I followed the provided
install instructions and configured it using prefix=..
that I get ParMETIS installed in one folder.
Unfortunately the include directory does only contain
parmetis.h and no metis.h.

A colleague analyzed the situation and found out that:


It looks like a glitch in the CMake scripts to me. When building metis
within parmetis (METIS_PATH CMake variable is not specfified), the
variable METIS_INSTALL is not set. This leads to a missing install step
for the metis library. Further, the CMakeLists.txt file in metis/include
is never processed, so the install command for metis.h is not processed.

Is he right? Or is this new behavior intended?

Thanks for having a look
Christoph

When I run mtest and ptest, I got segmentation fault.
From gdb, both mtest and ptest break at the following line

if (gkmcore != NULL)

Do you have any idea about this? My gcc is 4.2.0, glibc version 2.3.3.

Thanks!
Hui

Hi, all, I found in some old posts in this forum that the format of the input graph file for ParMetis is the same as Metis. However, I want to do a repartitioning. How can I add the existing partitions of each vertex to the input file? Can some one give an example?

I know ParMetis is supposed to be used as a library, but in my case, I only need some black-box experiments. So I do not want to bother writing my own codes calling ParMetis library.

Many thanks!

I've been tracking an access violation error when calling METIS_PartMeshDual routine from a Fortran program. Here's what I have:

-- Visual Studio 2010
-- Intel Fortran compiler 12

everything compiles fine and links by using the following interface:

! Fortran to C calling conventions and interface
! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
MODULE libmetis
INTERFACE
SUBROUTINE METIS_PartMeshDual ( ne , &
nn , &
eptr , &
eind , &
vwgt , &
vsize , &
ncommon, &
nparts , &
tpwgts , &
options, &

dear all,

I'm using ParMETIS to partition FE meshes and I use "ParMETIS_V3_PartMeshKway" routine.
I get very pleasing results with this routine, but not always. So I was wondering if it is possible to use the geometric information (co-ordinates) of the mesh to improve the results.
If someone has an idea on this, please share it.
Also please share, if you know of any other way to improve the mesh partition.

This is the error code.

Maximum memory used: 13179196 bytes
Current memory used: 5431868 bytes
***Memory realloc failed for cnbrpoolGet: cnbrpool. Requested size: 194608 bytes
MPI process (rank: 0) terminated unexpectedly

you can see that it doesn't use so much memory.My memory is big enough.Why it fail to realloc?

My code looks like this.
MPI_Comm_size(comm,&allrank);
MPI_Comm_rank(comm,&myrank);
real_t ubvec = 1.05;
idx_t options[3] = {0, 0, 0};
idx_t wgtflag=0;
idx_t numflag=0;
idx_t ncon=1;
idx_t ncom=3;
idx_t nparts=allrank;
idx_t edgecut;
//I think the other parmeters are right.I can't understand the meaning of the parameters list above
//Can anyone tell me wheter there is some wrong with my call?
ParMETIS_V3_PartMeshKway(elemdistribute,elemstartendeach,elempar,NULL,
&wgtflag,&numflag, &ncon,&ncom,&nparts,
tpwgts,&ubvec,options, &edgecut, part,
&comm);

Hello,
Trying to compile parmetis under VS2010 I got the following error:

>> GKlib\GKlib.h(51): fatal error C1083: Cannot open include file: 'regex.h': No such file or directory

I couldn't find "regex.h" but I found the "regex" file in c:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\

I tried to use USE_GKREGEX cmake variable, but got a lot of compiler's errors.
The problem reproduced with VS2008.

Under Linux (RHEL and Ubuntu) the same code was compiled by gcc4.4.3 without troubles.

Could you help me with that ?
Thanks in advance.

Hello!

I have a graph with 2^n vertices and few weighted edges. I would like to partition my graph in subsets of 2 vertices. For example, if my graph contains 32 vertices, I want to partition it in 16 sets of 2 vertices. Here comes my first question : I did some try with the ./parmetis binary on this example and it creates less than 16 partition (I called ParMETIS_v3_PartKWay). In this case, partitions 1, 7, 11 and 13 contain 3 vertices while partitions 9 and 15 don't exist. How can we explain that? I used this command line : ./parmetis my_test.graph 1 16 0 0 0 0

Next, I need to create a binary tree of the partitionment. Typically, with successive 2-way partitionment, I would like to create a tree. Is there a way to do this with ParMETIS? Otherwise, I could call several time ParMETIS and recreate a tree from the output. But it implies that ParMETIS partitions the graph in 2 subsets, then each of them in 2, etc... Is this hypothesis true?

Thx in advance and have a nice day!

I have been using ParMetis for a number of years now, and recently I switched to version 4.0.1 from version 3.1. Previous versions gave me the same decomposition when using the same number of processors, but I noticed with version 4.0.1 the decomposition has changed. I have checked my inputs and they are all the same as far as I can tell. Both of my versions call ParMETIS_V3_PartKway, but one from 3.1 and one from 4.0.1. Both use the default options (at least option[0]=0). Is there something I can do to get the same decomposition with both versions?

In general it does not matter, but for parallel testing purposes on my code I would like to be able to force the same decomposition to compare to old versions.

Thanks,
Jimmy