trilinos / Trilinos

Primary repository for the Trilinos Project
https://trilinos.org/
Other
1.21k stars 566 forks source link

MueLu_IntrepidPCoarsenFactory build error because Intrepid2_FieldContainer.hpp not in intrepid2/refactor #870

Closed pwxy closed 7 years ago

pwxy commented 7 years ago

I'm getting the following drekar build error with muelu (I'm using the trilinos develop branch as of ~5:00 this morning):

/projects/ptlin/projects/drekar/Trilinos20161121/packages/muelu/src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp(64): catastrophic error: cannot open source file "Intrepid2_FieldContainer.hpp"

include "Intrepid2_FieldContainer.hpp"

Intrepid2_FieldContainer.hpp is in intrepid2/core, but not in intrepid2/refactor. drekar (DrekarResearch) includes header files from intrepid2/refactor but not intrepid2/core, which is why it cannot find Intrepid2_FieldContainer.hpp

ibaned commented 7 years ago

I'm also seeing similar errors in our Albany builds:

http://my.cdash.org/viewBuildError.php?buildid=1086442

@trilinos/muelu @trilinos/intrepid2 @lxmota

rppawlo commented 7 years ago

This is because we switched the default build of Intrepid2 from "core" to "refactor". I was under the impression that Albany was already switched over and using the refactor branch. If not, then you need to add this to your configure script:

-D Intrepid2_ENABLE_KokkosDynRankView:BOOL=OFF

rppawlo commented 7 years ago

Should have also added that the FieldContainer was removed form Intrepid in the refactor branch. All FieldContainers should be switched to Kokkos::DynRankViews

ibaned commented 7 years ago

Albany has switched to the Intrepid2 refactor branch, and has been building with Intrepid2_ENABLE_KokkosDynRankView:BOOL=ON. However, it seems parts of MueLu are still looking for FieldContainer. So this looks more like an issue with MueLu not supporting the Intrepid2 refactor branch.

In file included from /lore/dibanez/trilinos/build/Trilinos/packages/muelu/src/Utils/ExplicitInstantiation/MueLu_HierarchyUtils.cpp:55:0:
/lore/dibanez/trilinos/src/Trilinos/packages/muelu/src/MueCentral/MueLu_HierarchyUtils_def.hpp:60:40: fatal error: Intrepid2_FieldContainer.hpp: No such file or directory
 #include "Intrepid2_FieldContainer.hpp"
                                        ^
mperego commented 7 years ago

Yeah, @csiefer2 is working on that. What I don't understand is why this issue appeared recently and not when we switched Albany to use the re-factored Intrepid2.

ibaned commented 7 years ago

Yeah, @csiefer2 is working on that.

Great, thank you.

What I don't understand is why this issue appeared recently and not when we switched Albany to use the re-factored Intrepid2.

My guess is MueLu or Intrepid2 changed recently, after the switch to refactor. If its meaningful I could find the offending commit via bisect, but thats likely not needed to provide a fix.

mperego commented 7 years ago

Maybe this caused it? https://github.com/trilinos/Trilinos/commit/c024e1947242ca8afc7607903f61f72822b99aa4

Anyway, let's Chris work on it. Sorry we did not see this coming.

rppawlo commented 7 years ago

Looks like the Intrepid::FieldContainer is actively used in muelu:

[rppawlo@gge muelu]$ find . -name '*pp' | xargs grep FieldContainer
./test/unit_tests/MueLu_TestHelpers.hpp:#include "Intrepid2_FieldContainer.hpp"
./test/unit_tests/MueLu_TestHelpers.hpp:      static RCP<Matrix> Build1DPseudoPoissonHigherOrder(GO nx, int degree,Intrepid2::FieldContainer<LocalOrdinal> & elem_to_node,
./test/unit_tests/IntrepidPCoarsenFactory.cpp:#include "Intrepid2_FieldContainer.hpp"
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    typedef Intrepid2::FieldContainer<MT> FC;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    typedef Intrepid2::FieldContainer<MT> FC;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    typedef Intrepid2::FieldContainer<MT> FC;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    typedef Intrepid2::FieldContainer<LO> FCi;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    Intrepid2::FieldContainer<LocalOrdinal> elem_to_node;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    Intrepid2::FieldContainer<LocalOrdinal> elem_to_node;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    Intrepid2::FieldContainer<LocalOrdinal> elem_to_node;
./test/unit_tests/IntrepidPCoarsenFactory.cpp:    Intrepid2::FieldContainer<LocalOrdinal> elem_to_node;
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:Teuchos::RCP<Intrepid2::Basis<Scalar,Intrepid2::FieldContainer<Scalar> > >  BasisFactory(const std::string & name) {
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:      if(degree==1) return rcp(new Intrepid2::Basis_HGRAD_QUAD_C1_FEM<Scalar,Intrepid2::FieldContainer<Scalar> >());
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:      else          return rcp(new Intrepid2::Basis_HGRAD_QUAD_Cn_FEM<Scalar,Intrepid2::FieldContainer<Scalar> >(degree,Intrepid2::POINTTYPE_EQUISPACED));
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:      if(degree==1) return rcp(new Intrepid2::Basis_HGRAD_LINE_C1_FEM<Scalar,Intrepid2::FieldContainer<Scalar> >());
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:      else          return rcp(new Intrepid2::Basis_HGRAD_LINE_Cn_FEM<Scalar,Intrepid2::FieldContainer<Scalar> >(degree,Intrepid2::POINTTYPE_EQUISPACED));
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:void BuildLoElemToNode(const Intrepid2::FieldContainer<LocalOrdinal> & hi_elemToNode,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:            Intrepid2::FieldContainer<LocalOrdinal> & lo_elemToNode,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:void IntrepidPCoarsenFactory<Scalar, LocalOrdinal, GlobalOrdinal, Node>::GenerateLinearCoarsening_pn_kirby_to_p1(const Intrepid2::FieldContainer<LocalOrdinal> & hi_elemToNode, 
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:                                                      const Intrepid2:: FieldContainer<double> hi_DofCoords,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:                                                      const Intrepid2::Basis<double,Intrepid2::FieldContainer<double> > &lo_basis,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:  typedef Intrepid2::FieldContainer<double> FC;
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:    typedef Intrepid2::FieldContainer<LO> FCi;
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:    //    typedef Intrepid2::FieldContainer<SC> FC;
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_def.hpp:    typedef Intrepid2::FieldContainer<double> FC;
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:#include "Intrepid2_FieldContainer.hpp"
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:    | inc: element to node map               | RCP<Intrepid::FieldContainer<LocalOrdinal> > | null | * | * | A FieldContainer with the element-to-node map in local ids compatible with the matrix column map |
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:    void GenerateLinearCoarsening_pn_kirby_to_p1(const Intrepid2::FieldContainer<LocalOrdinal> & hi_elemToNode, 
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:                         const Intrepid2:: FieldContainer<double> hi_DofCoords,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:                         const Intrepid2::Basis<double,Intrepid2::FieldContainer<double> > &lo_Basis,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:    Teuchos::RCP<Intrepid2::Basis<Scalar,Intrepid2::FieldContainer<Scalar> > >  BasisFactory(const std::string & name);
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:    void BuildLoElemToNode(const Intrepid2::FieldContainer<LocalOrdinal> & hi_elemToNode,
./src/Transfers/PCoarsen/MueLu_IntrepidPCoarsenFactory_decl.hpp:               Intrepid2::FieldContainer<LocalOrdinal> & lo_elemToNode,
./src/MueCentral/MueLu_HierarchyUtils_def.hpp:#include "Intrepid2_FieldContainer.hpp"
./src/MueCentral/MueLu_HierarchyUtils_def.hpp:            level->Set(name, Teuchos::getValue<RCP< Intrepid2::FieldContainer<LocalOrdinal> > >(it2->second), NoFactory::get());
[rppawlo@gge muelu]$ 
mperego commented 7 years ago

Ah, OK.. before Muelu was using Intrepid, not Intrepid2.. https://github.com/trilinos/Trilinos/commit/bbb0e6b4faa4edc3abca2695dbe8afca1f42af8f

csiefer2 commented 7 years ago

Fix pushed.

mhoemmen commented 7 years ago

@ibaned wrote:

My guess is MueLu or Intrepid2 changed recently, after the switch to refactor.

@csiefer2 explained to me that he first added a thing to MueLu, then Intrepid2 switched to refactor not long after that.