Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compiling error when trying to build for parallel running #194

Closed
GitPaean opened this issue Nov 24, 2015 · 7 comments
Closed

compiling error when trying to build for parallel running #194

GitPaean opened this issue Nov 24, 2015 · 7 comments

Comments

@GitPaean
Copy link
Member

I installed MPI (mpich2), dune with parallel compilation, pt-scotch, zoltan, superlu.

Any clues about the following compilation error. I suggest we have a detailed instruction on how to configure and build for parallel running. It can kill a lot of time easily.

 835 In file included from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:0:
 836 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp: At global scope:
 837 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:155:77: error: wrong number of template arguments (2, should be 1)
 838              typedef Dune::GridView<DefaultLevelGridViewTraits<CpGrid, pitype> > LevelGridView;
 839                                                                              ^
 840 In file included from /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh:28:0,
 841                  from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:52,
 842                  from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:
 843 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/defaultgridview.hh:23:10: error: provided for ‘template<class GridImp> struct Dune::DefaultLevelGridViewTraits’
 844    struct DefaultLevelGridViewTraits
 845           ^
 846 In file included from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:0:
 847 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:155:79: error: template argument 1 is invalid
 848              typedef Dune::GridView<DefaultLevelGridViewTraits<CpGrid, pitype> > LevelGridView;
 849                                                                                ^
 850 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:159:76: error: wrong number of template arguments (2, should be 1)
 851              typedef Dune::GridView<DefaultLeafGridViewTraits<CpGrid, pitype> > LeafGridView;
 852                                                                             ^
 853 In file included from /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh:28:0,
 854                  from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:52,
 855                  from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:
 856 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/defaultgridview.hh:223:10: error: provided for ‘template<class GridImp> struct Dune::DefaultLeafGridViewTraits’
 857    struct DefaultLeafGridViewTraits {
 858           ^
 859 In file included from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:0:
 860 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:159:78: error: template argument 1 is invalid
 861              typedef Dune::GridView<DefaultLeafGridViewTraits<CpGrid, pitype> > LeafGridView;
 862                                                                               ^
 863 In file included from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:52:0,
 864                  from /home/kaib/OPM/build/dune-cornerpoint/dune/grid/common/GridPartitioning.cpp:41:
 865 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh: In instantiation of ‘class Dune::Grid<3, 3, double, Dune::CpGridFamily>’:
 866 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh:999:9:   required from ‘class Dune::GridDefaultImplementation<3, 3, double, Dune::CpGridFamily>’
 867 /home/kaib/OPM/build/dune-cornerpoint/dune/grid/CpGrid.hpp:198:18:   required from here
 868 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh:419:55: error: no type named ‘LeafGridView’ in ‘Dune::CpGridFamily::Traits {aka struct Dune::CpGridTraits}’
 869      typedef typename GridFamily::Traits::LeafGridView LeafGridView;
 870                                                        ^
 871 /home/kaib/local/dune2.3/release_mpi/include/dune/grid/common/grid.hh:421:56: error: no type named ‘LevelGridView’ in ‘Dune::CpGridFamily::Traits {aka struct Dune::CpGridTraits}’
 872      typedef typename GridFamily::Traits::LevelGridView LevelGridView;
 873                                                         ^
@bska
Copy link
Member

bska commented Nov 24, 2015

Any clues about the following compilation error.

What version of Dune are you targeting?

@GitPaean
Copy link
Member Author

2.3

@bska
Copy link
Member

bska commented Nov 24, 2015

What version of Dune are you targeting?

2.3

That's strange. Lines 417--424 of grid.hh in the 2.3.1 release of dune-grid are

template <PartitionIteratorType pitype>
struct Partition
{
  typedef typename GridFamily::Traits::template Partition<pitype>::LevelGridView
  LevelGridView;
  typedef typename GridFamily::Traits::template Partition<pitype>::LeafGridView
  LeafGridView;
};

and these don't seem to agree with the error messages you're seeing. Are you absolutely positive that you don't have a straggling 2.2 version of Dune somewhere in your include path?

@GitPaean
Copy link
Member Author

Okay. Let me check.

@GitPaean
Copy link
Member Author

yes. My script failed in specifying the version and it downloaded a different version (probably 2.2 while I am not sure) from 2.3. Thanks.

@blattms
Copy link
Member

blattms commented Nov 24, 2015

Sounds like you want to test the parallelization. To get some speedup you need the yet not merged PR #195 and OPM/autodiff#547

@GitPaean
Copy link
Member Author

Yes. It looks like new development PRs require to be able to handle parallel running now. Without a parallel building, it is very difficult to test that.

Yesterday, I was trying to compile the OPM under parallel mode for the first time. Some small accidents made the process not that smooth, but finally it worked out. I will try your new PR. Thanks for the great works in parallelization.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants