Closed glanzkaiser closed 2 years ago
Answering on behalf of the @KratosMultiphysics/technical-committee. These are research applications that are not officially maintained. If you don't strictly require the features in these applications we advise to compile the ones "officially" maintained, which cover a wide range of the capabilities in Kratos. These are the ones in the CI. Here it is the link to the CI configure.
With regard to the FluidTransportApplication
I ping @ipouplana
With regard to the ConstitutiveModelsApplication
I ping @josep-m-carbonell @lluis-mv
@ipouplana @josep-m-carbonell @lluis-mv If these issues are not solved we will move these (as well as other not compiling applications) to the legacy repo.
Thanks @rubenzorrilla , I'll try to fix the FluidTransportApplication error ASAP. I am not using the ConstitutiveModelsApplication.
Thanks @rubenzorrilla , I'll try to fix the FluidTransportApplication error ASAP. I am not using the ConstitutiveModelsApplication.
Thanks for the quick reply!
@ipouplana @rubenzorrilla
Hi all,
thanks for all the replies. I try the configure.sh but I think my memory of 8 GB can't handle the Unity, so I OFF the build Unity.
I also try to OFF the MPI module and it can't found the TRILIINOS DIR that has been set. SO it is related. One must ON the ENABLE_MPI in order to detect the set TRILINOS_ROOT / TRILINOS_INCLUDE_DIR.
I wonder do I need the Unity software for enabling Unity? What is the cons of Disabling Unity in Kratos?
It is compiling now and waiting till finish. Hopefully work and I can try Kratos for Engineering and Science experimentation. Great software, no wonder it is used by TUM.
Thank You.
Hi @glanzkaiser
Unity build is used to reduce the compilation time in exchange for more memory usage. You can safely turn it off. If you want more info: https://cmake.org/cmake/help/latest/prop_tgt/UNITY_BUILD.html
Edit: Already solved it: put MMG_DIR into env variable is the solution
I have a question on MMG. Why it can't find my libmmg / my MMG_INCLUDE_DIRS ? I have installed it and put the right path.
Screenshots attached below.
Hi all,
Thanks for let this post be centralized till I can compile Kratos fully. I want to compile with bunch of applications because I want to test all of it one at a time..
I basically / initially interested to simulate this example: https://kratosmultiphysics.github.io/Examples/mmg_remeshing_examples/use_cases/lamborghini/
Lamborghini is cool!
But to compile Kratos, it took a lot of trial and tests and still not working till now...
The problems:
But it needs MeshingApplication (continue to number 2)
The MMG_INCLUDE_DIRS can't be found, I try to edit the words perhaps typo or such. Still not working, thus I have to exclude Meshing Application. Is there something wrong with my configure.sh so I can include the MMG? I have installed it all the MMGS MMG2D and MMG3D
Is it true that Metis only have one include file ? metis.h? and the library is libmetis.so?
My current condition of compiling -> Metis still can't be find with METIS_INCLUDE cmake var.
HI @glanzkaiser
1 - MMG: The recomended way to activate MMG is by setting:
-DMMG_ROOT="/home/roigcarlo/MMG/build"
In order to work, the directory tree of the folder you are pointing at should look something like this:
According to the screen you posted your mmg installation is done in the system, so in order for it to work you probably have to make it point to /opt/hamzstlib/include
directly
2 - Boost
The minimum required version of boost is 1.67. I assume you are using 1.70 and 1.79, those should be fine.
The auto
and the std::enable_if
errors are caused because of the compiler version. Note that Kratos currently supports only C++14 (but we will soon move to C++17). If you are using an old compiler (I recommend you to use at least gcc8 or clang5) you should add the -std=c++14
flags into -DCMAKE_CXX_FLAGS=
:
-DCMAKE_CXX_FLAGS="-std=c++14"
Hope this helps
Hi @roigcarlo ,
I follow your include for MMG. So it has to use the build folder from the source folder of MMG, not the installed headers.
This are what happens and I am compiling now with MetisApplication and MeshApplication.
Just a bit weird/bugging me. I use "-std=c++14" and while configuring there is another "-std=c++11", I do not know how to eliminate the "-std=c++11"
I am using GCC-11.2.0 from this one: https://www.linuxfromscratch.org/blfs/view/11.0/general/gcc.html
Thank You
Hi,
It should get overwritten by the ++14, but you can change it in the CMakeLists.txt, lines 3 and 168
Hi,
I guess the boost problem still occuring, I get it till 94% of compiling, it stop at certain point (43%, 72%, 83%, 94%) I have to type make again.
I Compiled Trilinos without MPI since my MPI is version 2 coming from OpenFOAM-9 installation, that's why it has no Epetra_MPI header.
I will compile with only minimal applications then. If there is a way around to solve the boost it will be great.
Thank You.
I reopen this because I am adding some thoughts and analysis of mine why I could not make Kratos MultiPhysics compilation smooth till 100%, perhaps not only me who face this kind of issue:
This Trilinos without MPI triggers chain of errors like missing Epetra_Mpicomm.h, etc.
Boost library always triggering warning errors of wrong syntaxes. I have installed the neewest Boost. I do not know how to fix this.
Last week I upgraded my RAM to 16 GB, but still compiling Kratos stop at certain percentage: 43%, I have to type again "make -j4" to continue and stop again at 73% then at 80% then at 94% never till 100%. So I cannot type "make install" at the end.
Hi @glanzkaiser
Trilinos cannot be built without MPI for Kratos.
May I ask you for the full specifications of your OS, configure file and what versions of libraries are you using? It may help to discover what is happening with boost.
For the ram problem, I suspect you still have the -DCMAKE_UNITY_BUILD=ON, please set that option to OFF or remove it.
Hi @roigcarlo and all other people who will be reading,
I am using my own made OS from Linux From Scratch (LFS) book. Previously, I installed Boost 1.77 from LFS book as well: Boost
Currently, Boost that I have installed is the newest version (1.79), I download it here and install it without problems: https://www.boost.org/
This is my configure file for Kratos: standard-configure.sh
I will turn off UNITY. But first, I have to fix the MPI problem for Trilinos, because I have double MPI from OpenFOAM installation and it becomes an obstacle to new MPI (OpenMPI-4) that is needed to build Trilinos with MPI (Trilinos needs OpenMPI-4 above).
I think RAM 16 GB is more than enough to compile Kratos. It becomes faster than before.
Hi @glanzkaiser
I've been testing our code in similar env and the problem with boost seems to be related with some compiler flags. Could you try compiling from this version: core/enable-cxx17
To change:
git checkout core/enable-cxx17
(Note: Be carefull to remove the build
directory or otherwise there may be problems if some flag is still in the build cache.
The help I can give for trilinos Its a little bit more limited: For Kratos to work trilinos needs to be compiled with MPI. This is not optional since Trilinos is our backbone for MPI. As far as I can tell you from our side there is no restriction on which version or implementation of MPI you can use.
We have an example configuration for trilinos:
TRILINOS_HOME="/home/roigcarlo/compiled_libraries/Trilinos-trilinos-release-12-18-1"
EXTRA_LINK_FLAGS=""
EXTRA_ARGS=$@
cmake \
-D CMAKE_INSTALL_PREFIX:PATH="/home/roigcarlo/compiled_libraries/bin/Trilinos-trilinos-release-12-18-1" \
-D CMAKE_BUILD_TYPE:STRING=RELEASE \
-D TPL_ENABLE_MPI:BOOL=ON \
-D MPI_BASE_DIR:PATH=/usr/bin \
-D MPI_INCLUDE_DIRS:PATH=/usr/include \
-D BUILD_SHARED_LIBS:BOOL=ON \
-D TPL_ENABLE_SuperLUDist:BOOL=ON \
-D SuperLUDist_INCLUDE_DIRS:PATH="/home/roigcarlo/compiled_libraries/SuperLU_DIST_4.3/SRC" \
-D SuperLUDist_LIBRARY_DIRS:PATH="/home/roigcarlo/compiled_libraries/bin/superludist/4.3/lib" \
-D SuperLUDist_LIBRARY_NAMES:STRING="libsuperlu_dist_4.3.a" \
-D TPL_ENABLE_METIS:BOOL=ON \
-D METIS_INCLUDE_DIRS:PATH="/globalfs/opt/metis/5.1.0/include" \
-D METIS_LIBRARY_DIRS:PATH="/globalfs/opt/metis/5.1.0/lib" \
-D TPL_ENABLE_ParMETIS:BOOL=ON \
-D ParMETIS_INCLUDE_DIRS:PATH="/globalfs/opt/parmetis/3.2.0/include" \
-D ParMETIS_LIBRARY_DIRS:PATH="/globalfs/opt/parmetis/3.2.0/lib" \
-D Trilinos_EXTRA_LINK_FLAGS:STRING="$EXTRA_LINK_FLAGS" \
-D Trilinos_ENABLE_Amesos:BOOL=ON \
-D Amesos_ENABLE_SuperLUDist:BOOL=ON \
-D Trilinos_ENABLE_Anasazi:BOOL=ON \
-D Trilinos_ENABLE_AztecOO:BOOL=ON \
-D AztecOO_ENABLE_Teuchos:BOOL=ON \
-D Trilinos_ENABLE_Didasko:BOOL=OFF \
-D Trilinos_ENABLE_Epetra:BOOL=ON \
-D Trilinos_ENABLE_EpetraExt:BOOL=ON \
-D Trilinos_ENABLE_Galeri:BOOL=OFF \
-D Trilinos_ENABLE_Ifpack:BOOL=ON \
-D Trilinos_ENABLE_ML:BOOL=ON \
-D Trilinos_ENABLE_PyTrilinos:BOOL=OFF \
-D Trilinos_ENABLE_Teuchos:BOOL=ON \
-D Trilinos_ENABLE_Triutils:BOOL=ON \
-D Trilinos_ENABLE_TESTS:BOOL=OFF \
-D DART_TESTING_TIMEOUT:STRING=600 \
-D CMAKE_Fortran_FLAGS:STRING="-O5 -funroll-all-loops -fPIC" \
-D CMAKE_C_FLAGS:STRING="-O3 -fPIC -funroll-loops" \
-D CMAKE_CXX_FLAGS:STRING="-O3 -fPIC -funroll-loops -ffast-math" \
$EXTRA_ARGS \
${TRILINOS_HOME}
That should allow you to compile with MPI.
Thanks for the CMake scripts,
I have saved and adjust with my path. I know now I have to fix the MPI Fortran. After it is fixed then I can build Trilinos with MPI then to Kratos. Perhaps in a few days. I will report here. I am now asking at MPI issue forum.
I knew this when I try to install SuperLUDist:
Closing due to inactivity. Please @glanzkaiser reopen if necessary.
Alright thanks. I am focusing on Julia now. Will come back to Kratos in the future.
Hi all,
I am compiling Kratos with this standard-configure.sh that I modify: standard-configure.sh
But I get error and I can't compile Trilinos maybe I wrongly put the TRILINOS_ROOT.
If anyone can point me which place should I place TRILINOS_ROOT and METIS_INCLUDE_DIR as well.
Not only that, there are other errors when compiling (see attachment below), how to get pass this? Thank You.