[slurm-users] LAST TASK ID

david martin vilanew at gmail.com
Tue Feb 6 08:40:04 MST 2018


Hi,

I´m running a batch array script and would like to execute a command 
after the last task


#SBATCH --array 1-10%10:1

sh myscript.R inputdir/file.${SLURM_ARRAY_TASK_ID}

# Would like to run a command after the last task

For exemple when i was using SGE there was something like this

| if($SGE_TASK_ID == $SGE_TASK_LAST ) then|
|||#||do||last-task stuff here|
|endif|


Can i do that with slurm ?


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.schedmd.com/pipermail/slurm-users/attachments/20180206/210635a9/attachment.html>


More information about the slurm-users mailing list