-
Notifications
You must be signed in to change notification settings - Fork 188
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
105 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
#!/bin/env sh | ||
|
||
# Distributed under the MIT License. | ||
# See LICENSE.txt for details. | ||
|
||
spectre_setup_modules() { | ||
echo "All modules on Sonic are provided by the system" | ||
} | ||
|
||
spectre_load_modules() { | ||
# The order here is important | ||
module load use.own | ||
# module load gcc/11.1.0 | ||
module load spectre-env > /dev/null 2>&1 | ||
} | ||
|
||
spectre_unload_modules() { | ||
# The order here is important | ||
module unload spectre-env > /dev/null 2>&1 | ||
# module unload gcc/11.1.0 | ||
module unload use.own | ||
} | ||
|
||
spectre_run_cmake() { | ||
if [ -z ${SPECTRE_SOURCE} ]; then | ||
echo "You must set SPECTRE_SOURCE to the cloned SpECTRE directory" | ||
return 1 | ||
fi | ||
|
||
if [ -z ${SPECTRE_INSTALL} ]; then | ||
echo "You must set SPECTRE_INSTALL to the target directory" | ||
return 1 | ||
fi | ||
|
||
spectre_load_modules > /dev/null 2>&1 | ||
cmake -D CMAKE_C_COMPILER=gcc \ | ||
-D CMAKE_CXX_COMPILER=g++ \ | ||
-D CMAKE_Fortran_COMPILER=gfortran \ | ||
-D CHARM_ROOT=$CHARM_ROOT \ | ||
-D MEMORY_ALLOCATOR=SYSTEM \ | ||
-D CMAKE_BUILD_TYPE=Release \ | ||
-D BUILD_PYTHON_BINDINGS=ON \ | ||
-D ENABLE_PARAVIEW=ON \ | ||
-D MACHINE=Sonic \ | ||
-D USE_XSIMD=yes \ | ||
-D DEBUG_SYMBOLS=OFF \ | ||
-D CMAKE_INSTALL_PREFIX=$SPECTRE_INSTALL \ | ||
"$@" \ | ||
$SPECTRE_SOURCE | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Distributed under the MIT License. | ||
# See LICENSE.txt for details. | ||
|
||
Machine: | ||
Name: Sonic | ||
Description: | | ||
HPC at ICTS-TIFR hosted by AstroRel. | ||
More information: | ||
https://it.icts.res.in/docs/sonic-cluster/ | ||
DefaultTasksPerNode: 3 | ||
DefaultProcsPerTasks: 32 | ||
DefaultQueue: "long" | ||
DefaultTimeLimit: "1-00:00:00" | ||
LaunchCommandSingleNode: ["mpirun", "-n", "1"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{% extends "SubmitTemplateBase.sh" %} | ||
|
||
# Distributed under the MIT License. | ||
# See LICENSE.txt for details. | ||
|
||
# Sonic is an HPC at ICTS-TIFR hosted by its AstroRel group. | ||
# More information: | ||
# https://it.icts.res.in/docs/sonic-cluster/ | ||
|
||
{% block head %} | ||
{{ super() -}} | ||
#SBATCH --nodes {{ num_nodes | default(1) }} | ||
#SBATCH --ntasks-per-node 3 | ||
#SBATCH --cpus-per-task 32 | ||
#SBATCH -p {{ queue | default("long") }} | ||
#SBATCH -t {{ time_limit | default("1-00:00:00") }} | ||
{% endblock %} |