| ... | ... | @@ -37,6 +37,37 @@ mpirun --map-by socket:PE=32 -np MY_NUMBER_OF_MPI_RANKS swift_mpi --my-fancy-swi |
|
|
|
|
|
|
|
(for 4 ranks per node with 32 threads each)
|
|
|
|
|
|
|
|
### Installing Spack for SWIFT on Cosma's Grace-Hopper Nodes
|
|
|
|
|
|
|
|
1. Install spack to cosma apps directory
|
|
|
|
- Follow [the Spack tutorial](https://spack-tutorial.readthedocs.io/en/latest/tutorial_basics.html)
|
|
|
|
- You should end up with a spack install in e.g. `/cosma/apps/<project>/<username>/spack`
|
|
|
|
- You will run out of disk space if you install Spack in your home directory
|
|
|
|
- Running Spack's `setup-env.sh` will fail due to Cosma providing an incompatible Python module by default. So unload Python first:
|
|
|
|
```
|
|
|
|
$ cat ~/load_spack_aarch64.sh
|
|
|
|
module unload python
|
|
|
|
source ~/spack/share/spack/setup-env.sh
|
|
|
|
```
|
|
|
|
- Then you can source your Spack setup script and you should have access to the `spack` command.
|
|
|
|
2. Create a Spack environment just for SWIFT. You can call your environment whatever you like. Here I call it `swift`.
|
|
|
|
```
|
|
|
|
spack env create swift
|
|
|
|
spack env activate swift
|
|
|
|
```
|
|
|
|
3. Install required dependencies:
|
|
|
|
```
|
|
|
|
spack install --add hdf5
|
|
|
|
```
|
|
|
|
4. You should now be able to compile and run swift as normal.
|
|
|
|
|
|
|
|
#### Misc tips for SWIFT on Cosma Grace-Hopper
|
|
|
|
|
|
|
|
Sometimes Spack struggles to load the right library environment variables. You may need to compile with:
|
|
|
|
|
|
|
|
```
|
|
|
|
LIBRARY_PATH=$LD_LIBRARY_PATH ./configure ...
|
|
|
|
```
|
|
|
|
|
|
|
|
### Cosma 7
|
|
|
|
|
| ... | ... | |
| ... | ... | |