User Tools

Site Tools


hpc:applications_and_libraries

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
hpc:applications_and_libraries [2024/06/11 14:37] Adrien Alberthpc:applications_and_libraries [2025/01/15 09:39] (current) – [FOSS toolchain] Yann Sagon
Line 195: Line 195:
  
  
-If you want to compile your software against MPI, it is very important not to compile using directly ''gcc'', ''icc'' or similar commands, but rather rely on the wrappers ''mpicc'', ''mpic++'', ''mpicxx'' or similar ones provided by module.+If you want to compile your software against MPI, it is very important not to compile using directly ''gcc'', ''icc'' or similar commands, but rather rely on the wrappers ''mpicc'', ''mpic<nowiki>++</nowiki>'', ''mpicxx'' or similar ones provided by module.
  
 All the newer versions of ''MPI'' will be available through the use of [[hpc:applications_and_libraries#module_-_lmod|module]]. All the newer versions of ''MPI'' will be available through the use of [[hpc:applications_and_libraries#module_-_lmod|module]].
Line 218: Line 218:
 |foss/2023a |gcc 12.3.0 |openmpi 4.1.5     | |foss/2023a |gcc 12.3.0 |openmpi 4.1.5     |
 |foss/2023b |gcc 13.2.0 |openmpi 4.1.6     | |foss/2023b |gcc 13.2.0 |openmpi 4.1.6     |
 +|foss/2024a |gcc 13.3.0 |openmpi 5.0.3     |
  
  
Line 558: Line 559:
 </code> </code>
  
 +<code>
 +(yggdrasil)-[alberta@login1 ~]$ cat sbatch_nv 
 +#!/bin/bash
 +#SBATCH --job-name=compile_test
 +#SBATCH --output=compile_test.out
 +#SBATCH --error=compile_test.err
 +#SBATCH --time=00:01:00
 +#SBATCH --partition=debug-cpu
  
 +# Load the necessary modules
 +ml GCC
 +
 +# Set up the environment for NVIDIA HPC SDK
 +export HPC_SDK_DIR=/home/users/a/alberta/HPC_sdk
 +export PATH=$HPC_SDK_DIR/Linux_x86_64/24.5/compilers/bin:$PATH
 +export MANPATH=$HPC_SDK_DIR/Linux_x86_64/24.5/compilers/man:$MANPATH
 +export PATH=$HPC_SDK_DIR/Linux_x86_64/24.5/comm_libs/mpi/bin:$PATH
 +
 +# Run add_network_host to create host-specific localrc files
 +$HPC_SDK_DIR/Linux_x86_64/24.5/compilers/bin/add_network_host
 +
 +
 +# Compile the test.cpp file
 +nvc++ test.cpp -o test
 +</code>
 +
 +<code>
 +(yggdrasil)-[alberta@login1 ~]$ sbatch sbatch_nv
 +Submitted batch job 33866816
 +
 +</code>
 +
 +
 +<WRAP center round info 60%>
 +  * Ensure to run the ''add_network_host'' command on all nodes in your heterogeneous cluster to create the necessary ''localrc'' files.
 +  * Make sure the environment variables are set in your shell configuration files (e.g., `.bashrc`, `.cshrc`) for persistent settings across sessions.
 +  * For more details and further documentation, visit the [NVIDIA HPC SDK website](https://developer.nvidia.com).
 +</WRAP>
  
-Compile  the program using ''mpic++'' through slurm 
  
 ===== Gurobi ===== ===== Gurobi =====
Line 1075: Line 1112:
 You can install R packages as a user. Just follow once the steps given below: You can install R packages as a user. Just follow once the steps given below:
  
-Create a file named .Rprofile (note the dot in front of the file) in your home directory with the following content:+Create a file named ''.Rprofile'' (note the dot in front of the file) in your home directory with the following content:
  
 <code> <code>
-(yggdrasil)-[alberta@login1 ~]$ cat ~/.Rprofile 
- 
 local({ local({
 r = getOption("repos") # hard code the Switzerland repo for CRAN r = getOption("repos") # hard code the Switzerland repo for CRAN
Line 1088: Line 1123:
  
  
-The first line is purely informative. The output may break things such as package installation. Feel free to comment out this line or remove it. +Create a file named ''.Renviron'' (note the dot in front of the file) in your home directory with the following content:
- +
-Create a file named .Renviron (note the dot in front of the file) in your home directory with the following content:+
  
 <code> <code>
hpc/applications_and_libraries.1718116668.txt.gz · Last modified: 2024/06/11 14:37 by Adrien Albert