Created
April 11, 2017 17:31
-
-
Save 3inar/7c937be149b5fe8750f1777c231e52e6 to your computer and use it in GitHub Desktop.
Example of job script for stallo
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
#!/usr/bin/env bash | |
# commands to the batch system start with '#SBATCH ' | |
# pick a name for your job | |
#SBATCH --job-name=my_job | |
# I want 500 duplicate jobs that use a single cpu each | |
#---------------------------------------------------------------- | |
# one machine per job: | |
#SBATCH --nodes=1 | |
# one cpu per job (if you're not using a special parallell backend you only need one) | |
#SBATCH --ntasks-per-node=1 | |
# duplicate this job 500 times | |
#SBATCH --array=1-500 | |
# You need to have realistic estimates of how long the job runs & how much memory you need | |
#---------------------------------------------------------------- | |
# run each job for 10 hrs: | |
#SBATCH --time=0-10:00:00 | |
# need 2000MB of memory per job: | |
#SBATCH --mem=2000 | |
# Setting this option makes the batch system email you when something happens to your job: | |
#SBATCH --mail-type=ALL | |
# I have set all the parameters I want, now I can run my job | |
#---------------------------------------------------------------- | |
# load R: | |
module load R | |
# execute my script: | |
R --vanilla < /home/einar/example_rscript.R | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment