Skip to content

Commit

Permalink
Merge pull request #1144 from LLNL/feature/bramwell/mfem_sidre_fespac…
Browse files Browse the repository at this point in the history
…e_annotation_fix

Fix `MFEMSidreDataCollection` finite element space bug
  • Loading branch information
white238 committed Jul 26, 2023
2 parents 60e49c4 + bf4a93f commit 9da02a6
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/axom/sidre/core/MFEMSidreDataCollection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2636,11 +2636,12 @@ void MFEMSidreDataCollection::reconstructField(Group* field_grp)
}

// We cache the FESpaces to avoid reconstructing them when not needed
// An FESpace is uniquely identified by the basis of its FEColl and its ordering
// An FESpace is uniquely identified by the basis of its FEColl, ordering, and vdim number
const std::string fespace_id =
axom::fmt::format("{0}_{1}",
axom::fmt::format("{0}_{1}_{2}",
basis_name,
(ordering == mfem::Ordering::byVDIM) ? "nodes" : "vdim");
(ordering == mfem::Ordering::byVDIM) ? "vdim" : "nodes",
vdim);

// Only need to create a new FESpace if one doesn't already exist
if(is_gridfunc && (m_fespaces.count(fespace_id) == 0))
Expand Down

0 comments on commit 9da02a6

Please sign in to comment.