Skip to content

Commit

Permalink
Update hdf5 READMEs for Mahti
Browse files Browse the repository at this point in the history
  • Loading branch information
hokkanen committed Apr 30, 2024
1 parent 616bd8f commit 6dc8000
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
12 changes: 10 additions & 2 deletions parallel-io/hdf5-write-read/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,19 @@
Complete the HDF5 exercises ([hdf5.c](hdf5.c) or [hdf5.f90](hdf5.f90))
by writing HDF5 writer and reader functions/subroutines.

On Lumi, you will need to load the module `cray-hdf5-parallel` before you
On Mahti, you will need to load the module `hdf5/1.10.7-mpi` before you
can compile the code:

```
module load cray-hdf5-parallel
module load hdf5/1.10.7-mpi
```
Now you shoud be able to compile with
```
mpicc hdf5.c -lhdf5
```
or
```
mpif90 hdf5.f90 -I/appl/spack/v017/install-tree/gcc-11.2.0/hdf5-1.10.7-qc3apk/include -lhdf5_fortran
```

After compiling and running the program. You can use the `h5dump` and `h5ls`
Expand Down
12 changes: 10 additions & 2 deletions parallel-io/hdf5-writerank/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,19 @@

Explore the HDF5 codes ([hdf5-writerank.c](hdf5-writerank.c) or [hdf5-writerank.F90](hdf5-writerank.F90)) and try to compile them.

On Lumi, you will need to load the module `cray-hdf5-parallel` before you
On Mahti, you will need to load the module `hdf5/1.10.7-mpi` before you
can compile the code:

```
module load cray-hdf5-parallel
module load hdf5/1.10.7-mpi
```
Now you shoud be able to compile with
```
mpicc hdf5-writerank.c -lhdf5
```
or
```
mpif90 hdf5-writerank.F90 -I/appl/spack/v017/install-tree/gcc-11.2.0/hdf5-1.10.7-qc3apk/include -lhdf5_fortran
```

After compiling, try running the program with some number of MPI ranks. After this, try using the `h5dump` and `h5ls` commands to check the values in the HDF5 file that is produced by running the example. Do you understand what the program does and what are the values in the file (as shown by `h5dump`)?

0 comments on commit 6dc8000

Please sign in to comment.