Commit bc7d89a7 authored by Alexis SALZMAN's avatar Alexis SALZMAN

[xMeshTool] add a new Parmetis partition function with weight

This commit is adding template function setParmetisPartitionWithWeight that
use a set of weights per element to optimize ParMetis partitioning based on
multi criteria (the weights).  The template parameter (an int) is fixing the
number of weights per element. The interface is kept simple. Only an extra
xAttachedDataManagerAOMD is used to passe weights set per element.

No test case for now but it have been heavily tested in some apps.

This function is using almost the same algo as the one used for
setParmetisPartition in the cc file. It is rather dirty (code
duplication) but efficient.

It add also a new dependency in terms of cmake. xInterfaceParMetis must
now be added in cmake to use xLoadBalanceTools. But anyway from my point
of view it should already be the case. Normally xInterfaceParMetis should
embedded ParMetis and in cmake finding metis/parmetis lib should not be
done.... Modern cmake would do even more by setting all this dependency
setting for you .....
parent 3af9ff86
This diff is collapsed.
......@@ -32,7 +32,7 @@ include_directories( ${PARMETIS_INCLUDE_DIR} ${METIS_INCLUDE_DIR} )
list(APPEND EXTERNAL_LIBRARIES ${PARMETIS_LIBRARIES} ${METIS_LIBRARIES})
list(APPEND xDistMesh_EXTERNAL_INCLUDES ${PARMETIS_INCLUDE_DIR} ${METIS_INCLUDE_DIR})
find_and_set(xInterfaceParMetis xInterfaceParMetis EXTERNAL_INCLUDES EXTERNAL_LIBRARIES REQUIRED )
set(LISTAOMDPARMETIS ${CMAKE_CURRENT_SOURCE_DIR}/testLoadBalanceToolsAOMD )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment