|
[Sponsors] |
March 19, 2012, 03:40 |
How to run decomposePar with parMetis?
|
#1 |
New Member
xiaoweii
Join Date: Mar 2012
Posts: 7
Rep Power: 14 |
parMetis is a parallel decompose method, that means we can decompose the mesh using several processes.
I just don't know how to do this? After change the decomposeParDict, run "decomposePar" just executes in serial, and the command "mpirun -n 4 decomposePar -parallel" cannot work. |
|
April 5, 2012, 07:19 |
|
#2 |
Member
Martin
Join Date: Nov 2011
Posts: 35
Rep Power: 15 |
Hello xiaow_g,
the decomposing is normally done after blockMesh to run snappyHexMesh in parallel (parallel meshing) or to decompose the mesh after meshing with snappyHexMesh to run the calculation in parallel (parallel calculation). The decomposing needs only the decomposeParDict so that you can run it by simply type decomposePar in the terminal. For the next steps parallel Meshing / calculation you need to use the mpirun -np ... (snappyHexMesh/rhoSimpleFoam) -parallel ... I hope my explanation is not to difficult MARTIN |
|
April 5, 2012, 11:00 |
|
#3 | |
New Member
xiaoweii
Join Date: Mar 2012
Posts: 7
Rep Power: 14 |
Quote:
I got your idea. You told me how to "parallel meshing" and "parallel calculation", but I am confused about how to "parallel decomposing". If running the decomposing in serial , I just need to run decomposePar in the terminal. but parMetis or ptScotch is parallel decomposing method, and the decomposing method can be set in the decomposeParDict. |
||
April 13, 2012, 09:06 |
|
#4 |
Member
Martin
Join Date: Nov 2011
Posts: 35
Rep Power: 15 |
There is nothing like parallel decomposing. The only thing what the decomposer is doing is to decompose the mesh or field into processor-folders. This is accomplished in serial by running decomposePar. The methods how the field is beeing decomposed is described in the dictionary (hierarical, scotch, metis ...).
|
|
April 13, 2012, 16:49 |
|
#5 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings to all!
Martin is right. The only thing that the ptscotch and parmetis methods are good for is for parallel mesh manipulation. One example, already mentioned by Martin, is snappyHexMesh when executed in parallel, which allows mesh manipulation in parallel... although I don't know if cells are exchanged between processors in a load balancing system or if only the mesh structure is accessible between processors. If you study the script "incompressible/simpleFoam/turbineSiting/Allrun", you'll notice exactly this: snappyHexMesh must use ptscotch... ... or in other words, it can't use scotch, because I think I've been able to use simple and hierarchical with snappyHexMesh... Best regards, Bruno
__________________
|
|
October 1, 2012, 09:26 |
|
#6 | |
Senior Member
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21 |
Quote:
I'm bumping this thread, because I need to use dynamic load balancing for the code I wrote. It's a two phase library with a geometrical transport of the volume fraction field, so the "action" is happening mostly near the interface. Is there a "recipe" for using dynamic load balancing in OpenFOAM in general? If there is none, can you at least name the ingredients? How do I use ptscotch and parmetis together with the dynamicRefineFvMesh? Tomislav |
||
October 1, 2012, 18:06 |
|
#7 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Hi Tomislav,
I think it's best that you ask in a new thread in the "Running" sub-forum, because that's more closely related to your question . The closest I know about load balancing in OpenFOAM is the redistributePar application, but this would require you to stop the solver once in a while for redistribution and then running it again to continue. You can have a look in the folder "application/test" for ideas. Last but not least: I suspect that said capability is possible in OpenFOAM, but probably it's not implemented yet. Best regards, Bruno
__________________
|
|
October 2, 2012, 03:04 |
|
#8 | |
Senior Member
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21 |
Quote:
Thanks, I will check it out. Best regards, Tomislav |
||
October 2, 2012, 17:38 |
|
#9 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Hi Tomislav,
Here you go, someone else is working on this subject as well: http://www.cfd-online.com/Forums/ope...tml#post384606 My guess is that you weren't lucky enough to find that thread in the first place... Best regards, Bruno
__________________
|
|
October 4, 2012, 06:25 |
|
#10 | |
Senior Member
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 284
Blog Entries: 5
Rep Power: 21 |
Quote:
|
||
April 11, 2013, 17:45 |
|
#11 |
New Member
Anirban Jana
Join Date: Apr 2010
Location: Pittsburgh, PA, USA
Posts: 19
Rep Power: 16 |
Hi All,
Shouldn't the function ParMETIS _V3_PartMeshKway function, for example, be able to do decomposition of the mesh in parallel? This is based on a parallel multi-level graph-partitioning algorithm. The paper describing this algorithm can be found here: http://www.cs.ucsb.edu/~gilbert/cs29...mlevel_mpi.pdf. ptScotch also has parallel graph partitioning routines. Hence it seems to me xiaoweii has a point. It should be possible to parallelize decomposePar itself. It seems to me from the discussion in this thread though that currently only a serial version of decomposePar is available. Am I right? Is there at least some near term plan to parallelize decomposePar using these parallel graph partioning algorithms? Thanks Anirban Last edited by jans; April 11, 2013 at 18:17. |
|
April 14, 2013, 08:16 |
|
#12 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings Anirban,
AFAIK, as I've mentioned in one of the old posts:
Thinking a bit further on this last option, it gives the idea that we can do the following:
Best regards,Bruno
__________________
|
|
April 16, 2013, 19:14 |
|
#13 |
New Member
Anirban Jana
Join Date: Apr 2010
Location: Pittsburgh, PA, USA
Posts: 19
Rep Power: 16 |
Hi Bruno,
Thanks much. Your suggestions are very interesting. I play with these and get back on what I discover. I still do not entirely convinced why even the initial decomposition cannot be done in parallel. It seems like you are saying it is impossible algorithmically. I am not sure why. Oh well! Best regards Anirban |
|
April 17, 2013, 17:06 |
|
#14 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Hi Anirban,
AFAIK, the current OpenFOAM framework contemplates only a few parallel mesh paradigms:
And I think I forgot to mention in the previous posts a certain important aspect of how the official OpenFOAM version works: it only uses MPI for parallel processing. It does not use OpenMP nor is it prepared to work with multi-threaded processes. The Extend variant of OpenFOAM on the other hand, is suppose to be able to work with multi-threaded capabilities, but I'm not familiar enough with it so I don't know what it can do with those multiple threads... Now back on the multi-level topic: this option might be insinuating that the authors of OpenFOAM are already working on this kind of situation, namely a situation where they have hundreds of million cells in a mesh that need to be decomposed to thousands of cores, therefore the distribution has to be made in a multi-level manner, in order to propagate the mesh gradually throughout the whole system. Nonetheless, I'm not aware of any specific documentation on this topic; and from what I know, it requires to start with at least with a seed decomposition of 2 sub-domains and then rely on redistributePar to take care of things and lead them to the thousands. Either way, you do have some more possible ways to find more about this:
Bruno
__________________
|
|
June 10, 2013, 15:35 |
|
#15 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Greetings to all!
@Anirban: Apparently redistributePar can redistribute from one processor to multiple processors, as somewhat explained on the following thread: http://www.cfd-online.com/Forums/ope...oundaries.html It's even implied in the header documentation: https://github.com/OpenFOAM/OpenFOAM...istributePar.C Quote:
Bruno
__________________
|
||
July 4, 2017, 08:10 |
running decomposePar in parallel
|
#16 |
New Member
Alex Landsberg
Join Date: Sep 2009
Location: Australia
Posts: 15
Rep Power: 0 |
Hi All,
I tried to do use decomposePar in parallel as it is shown in the OF v3.0+ guide : mpirun -np 2 redistributePar -decompose -parallel but got an error that the argument decompose doesn't exist in redistributePar. Did someone already used it ? and specifically with the metis domain decomposition decomposition tool? Thanks Alex |
|
July 8, 2017, 14:37 |
|
#17 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Quick answer:
Quote:
If you are using any other version of OpenFOAM, namely the versions from http://openfoam.org - then that option does not exist. |
||
Tags |
decomposepar, parallel.ptscotch, parmetis |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Error trying to run steady-state sonicFoam | dancfd | OpenFOAM Running, Solving & CFD | 2 | February 12, 2013 04:15 |
SnappyHexMesh OF-1.6-ext crashes on a parallel run | norman1981 | OpenFOAM Bugs | 5 | December 7, 2011 13:48 |
how to map results from steady state run to tranient case? | phsieh2005 | OpenFOAM Running, Solving & CFD | 2 | November 7, 2010 07:20 |
How to run and save tranisent case on Cray XD1 | Leon | FLUENT | 0 | October 3, 2006 22:59 |
Windows 64-bit, Distributed Parallel Run Issues... | Erich | CFX | 3 | March 28, 2006 17:36 |