cc_staff
239
edits
(running) |
(→Running: update after testing) |
||
Line 116: | Line 116: | ||
====Running==== | ====Running==== | ||
Please your R code in a script file, in this case test.R. | |||
Then place the following in a job submission script, job.sh : | Then place the following in a job submission script, job.sh : | ||
#!/bin/bash | #!/bin/bash | ||
#SBATCH --account=def-ppomorsk | #SBATCH --account=def-ppomorsk # replace this with your own account | ||
#SBATCH --ntasks= | #SBATCH --ntasks=5 # number of MPI processes | ||
#SBATCH --mem-per-cpu= | #SBATCH --mem-per-cpu=2048M # memory; default unit is megabytes | ||
#SBATCH --time=0- | #SBATCH --time=0-00:15 # time (DD-HH:MM) | ||
module load r/3.4.0 | module load r/3.4.0 | ||
export R_LIBS=~/local/R_libs/ | export R_LIBS=~/local/R_libs/ | ||
mpirun -np 1 R CMD BATCH test.R test.txt | |||
Finally, submit the job with: | Finally, submit the job with: | ||
Line 137: | Line 134: | ||
sbatch job.sh | sbatch job.sh | ||
For more on submitting jobs, see the [ | For more on submitting jobs, see the [[Running jobs]] page. | ||
</translate> | </translate> |