LLNL / libROM

Model reduction library with an emphasis on large scale parallelism and linear subspace methods
https://www.librom.net
Other
201 stars 36 forks source link

installing libROM #182

Closed gokhalen closed 1 year ago

gokhalen commented 1 year ago

I have cloned the libROM repo and I'm trying to install it on WSL2 (Ubuntu) on Windows. I'm getting the following errors. Firstly, is it possible to install without MPI? Any help would be appreciated.

./compile.sh

gives

CMake Error at CMakeLists.txt:26 (project):
  The CMAKE_C_COMPILER:

    mpicc

  is not a full path and was not found in the PATH.

  Tell CMake where to find the compiler by setting either the environment
  variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to
  the compiler, or to the compiler name if it is in the PATH.

CMake Error at CMakeLists.txt:26 (project):
  The CMAKE_CXX_COMPILER:

    mpicxx

  is not a full path and was not found in the PATH.

  Tell CMake where to find the compiler by setting either the environment
  variable "CXX" or the CMake cache entry CMAKE_CXX_COMPILER to the full path
  to the compiler, or to the compiler name if it is in the PATH.

CMake Error at CMakeLists.txt:26 (project):
  The CMAKE_Fortran_COMPILER:

    mpif90

  is not a full path and was not found in the PATH.

  Tell CMake where to find the compiler by setting either the environment
  variable "FC" or the CMake cache entry CMAKE_Fortran_COMPILER to the full
  path to the compiler, or to the compiler name if it is in the PATH.

-- Configuring incomplete, errors occurred!
See also "/mnt/c/Work/Ubuntu/LSROM/libROM/libROM/build/CMakeFiles/CMakeOutput.log".
See also "/mnt/c/Work/Ubuntu/LSROM/libROM/libROM/build/CMakeFiles/CMakeError.log".
make: *** No targets specified and no makefile found.  Stop.
/mnt/c/Work/Ubuntu/LSROM/libROM/libROM/scripts

Contents of CMakeOutput.log

The system is: Linux - 5.10.16.3-microsoft-standard-WSL2 - x86_64

Contents of CMakeError.log

Checking whether the C compiler is IAR using "" did not match "IAR .+ Compiler":
Checking whether the C compiler is IAR using "" did not match "IAR .+ Compiler":
Checking whether the CXX compiler is IAR using "" did not match "IAR .+ Compiler":
Checking whether the CXX compiler is IAR using "" did not match "IAR .+ Compiler":
Checking whether the Fortran compiler is Compaq using "-what" did not match "Compaq Visual Fortran":
Checking whether the Fortran compiler is NAG using "-V" did not match "NAG Fortran Compiler":
Checking whether the Fortran compiler is Compaq using "-what" did not match "Compaq Visual Fortran":
Checking whether the Fortran compiler is NAG using "-V" did not match "NAG Fortran Compiler":
chldkdtn commented 1 year ago

@dreamer2368 would you introduce your docker-based libROM to @gokhalen ?

dreamer2368 commented 1 year ago

If you have Docker installed for WSL2, there is a docker container where all the required dependencies are installed:

https://hub.docker.com/r/dreamer2368/librom_env

Instruction is included in the docker hub repository above, but please let me know if there is any question.

For docker on WSL2, you may want to consider this info page. In particular, it is recommended to store the source code in the Linux file system, not the windows.

For the first question about MPI being a requirement, @chldkdtn , can you comment on whether this requirement is necessary?

gokhalen commented 1 year ago

@dreamer2368 I tried installing Docker and then pulling librom_env. Unfortunately, Docker is reliably crashing my system due to something in dxgkrnl.sys ...let me check further and see if I can find any workarounds. Thanks.

gokhalen commented 1 year ago

This seems to have resolved the crash issue. The only issue seems that the mounted directory is coming up empty.

Edit: Supplying the absolute path to the directory to mount helped. It seems to be mounted and I'll try compiling tomorrow.

gokhalen commented 1 year ago

Unfortunately Docker is still crashing WSL2.

gokhalen commented 1 year ago

@dreamer2368 Thanks for the Docker image. I've been able to run Docker and build libROM on a different computer. I have one question: Does your docker image include the visualization programs VisIt or GLVis? (I'm guessing probably not)

dreamer2368 commented 1 year ago

I usually save output files in the mounted volume, which is accessible outside of the container. Then you can use any visualization software installed in your computer.

I think some lightweight visualization tools like glvis can be added in the container in a near future.

gokhalen commented 1 year ago

@dreamer2368 Thank you very much. If you could let me know the name of the viewer you use in Visit to read the HDF5 files generated by libROM examples, that would be much appreciated.

dreamer2368 commented 1 year ago

Unfortunately Docker is still crashing WSL2.

I currently started working with windows, and Docker seems to be working well at least on my end. With that, I suggest to close this issue, and start new threads for the issues not related to this one.

gokhalen commented 1 year ago

Docker is working perfectly on one windows machine at my end and not on another. I haven't had time to investigate what the differences between the two windows machines might be.