From f5638a3e29c0e4b7b18836163916cb15945b47f1 Mon Sep 17 00:00:00 2001 From: Thomas Gibson <gibsonthomas1120@hotmail.com> Date: Sat, 13 Nov 2021 07:52:18 -0600 Subject: [PATCH] Add short comments concerning rank-local trace pairs --- grudge/trace_pair.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/grudge/trace_pair.py b/grudge/trace_pair.py index f8a32a94..3dbca276 100644 --- a/grudge/trace_pair.py +++ b/grudge/trace_pair.py @@ -220,6 +220,14 @@ def interior_trace_pair(dcoll: DiscretizationCollection, vec) -> TracePair: *dcoll* with a discretization tag specified by *discr_tag*. This does not include interior faces on different MPI ranks. + For certain applications, it may be useful to distinguish between + rank-local and cross-rank trace pairs. For example, avoiding unnecessary + communication of derived quantities (i.e. temperature) on partition + boundaries by computing them directly. Having the ability for + user applications to distinguish between rank-local and cross-rank + contributions can also help enable overlapping communication with + computation. + :arg vec: a :class:`~meshmode.dof_array.DOFArray` or object array of :class:`~meshmode.dof_array.DOFArray`\ s. :returns: a :class:`TracePair` object. @@ -244,6 +252,9 @@ def interior_trace_pairs(dcoll: DiscretizationCollection, vec) -> list: defined on the interior faces of *dcoll* and any faces connected to a parallel boundary. + Note that :func:`interior_trace_pair` provides the rank-local contributions + if those are needed in isolation. + :arg vec: a :class:`~meshmode.dof_array.DOFArray` or object array of :class:`~meshmode.dof_array.DOFArray`\ s. :returns: a :class:`list` of :class:`TracePair` objects. -- GitLab