Changeset 27919


Ignore:
Timestamp:
09/20/23 23:55:12 (18 months ago)
Author:
vverjans
Message:

CHG: updating pace cluster script

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/classes/clusters/pace.m

    r27532 r27919  
    99        properties (SetAccess=public)
    1010        % {{{
    11                 name            = 'login-phoenix-4.pace.gatech.edu' %Phoenix cluster name
     11                name            = 'login-phoenix-slurm.pace.gatech.edu' %Phoenix cluster name
    1212                login           = ''; %personal login
    1313                numnodes        = 1; %number of nodes requested
     
    1717                queue           = 'inferno'; %queue
    1818                time            = 60; %time requested per run [minutes]
    19                 accountname     = 'GT-arobel3-atlas'; %group account name
     19                accountname     = 'gts-arobel3-atlas'; %group account name
    2020                codepath        = ''; %path to issm binaries
    2121                executionpath   = ''; %path for execution folder
     
    6262                        fid=fopen([modelname '.queue'],'w');
    6363                        fprintf(fid,'#!/bin/sh\n');
    64                         fprintf(fid,'#PBS -l walltime=%i\n',cluster.time*60); %conversion of walltime from minutes to seconds.
    65                         fprintf(fid,'#PBS -N %s\n',modelname);
    66                         fprintf(fid,'#PBS -l nodes=1:ppn=%i\n',cluster.np);
    67                         fprintf(fid,'#PBS -l pmem=%igb\n',cluster.mem);
    68                         fprintf(fid,'#PBS -q %s\n',cluster.queue);
    69                         fprintf(fid,'#PBS -A %s\n',cluster.accountname);
    70                
    71                         fprintf(fid,'#PBS -o %s/%s/%s.outlog \n',cluster.executionpath,dirname,modelname);
    72          fprintf(fid,'#PBS -e %s/%s/%s.errlog \n\n',cluster.executionpath,dirname,modelname);
    7364
    74                         fprintf(fid,'export PBS_O_WORKDIR=%s\n',[cluster.executionpath '/' dirname]);
    75                         fprintf(fid,'cd $PBS_O_WORKDIR\n');
    76                         fprintf(fid,'mpiexec -np %i %s/%s %s %s %s \n',cluster.np,cluster.codepath,executable,solution,[cluster.executionpath '/' dirname],modelname); 
     65                        fprintf(fid,'#SBATCH -t%i\n',cluster.time);
     66         fprintf(fid,'#SBATCH -J%s\n',modelname);
     67         fprintf(fid,'#SBATCH -N 1 --ntasks-per-node=%i\n',cluster.np);
     68         %fprintf(fid,'#SBATCH -N %i\n',cluster.numnodes);
     69         %fprintf(fid,'#SBATCH --ntasks=1\n');
     70         %fprintf(fid,'#SBATCH --cpus-per-task=%i\n',cluster.np);
     71         fprintf(fid,'#SBATCH --mem-per-cpu=%iG\n',cluster.mem);
     72         fprintf(fid,'#SBATCH -p%s\n',cluster.queue);
     73         fprintf(fid,'#SBATCH -A %s\n',cluster.accountname);
     74         fprintf(fid,'#SBATCH -o%s/%s/%s.outlog \n',cluster.executionpath,dirname,modelname);
     75         fprintf(fid,'#SBATCH -e%s/%s/%s.errlog \n\n',cluster.executionpath,dirname,modelname);
     76         fprintf(fid,'export SLURM_SUBMIT_DIR=%s\n',[cluster.executionpath '/' dirname]);
     77         fprintf(fid,'cd $SLURM_SUBMIT_DIR\n');
     78         fprintf(fid,'export LD_LIBRARY_PATH=/opt/slurm/current/lib:/opt/pmix/current/lib:$LD_LIBRARY_PATH \n');
     79         fprintf(fid,'srun --mpi=pmi2 -n %i %s/%s %s %s %s \n',cluster.np,cluster.codepath,executable,solution,[cluster.executionpath '/' dirname],modelname);
    7780
    7881                        fclose(fid);
     
    97100                        disp('launching solution sequence on remote cluster');
    98101                        if ~isempty(restart)
    99                                 launchcommand=['cd ' cluster.executionpath ' && cd ' dirname ' && qsub ' modelname '.queue '];
     102                                launchcommand=['cd ' cluster.executionpath ' && cd ' dirname ' && sbatch ' modelname '.queue '];
    100103                        else
    101104                                launchcommand=['cd ' cluster.executionpath ' && rm -rf ./' dirname ' && mkdir ' dirname ...
    102                                         ' && cd ' dirname ' && mv ../' dirname '.tar.gz ./ && tar -zxf ' dirname '.tar.gz  && qsub ' modelname '.queue '];
     105                                        ' && cd ' dirname ' && mv ../' dirname '.tar.gz ./ && tar -zxf ' dirname '.tar.gz  && sbatch ' modelname '.queue '];
    103106                        end
    104107                        issmssh(cluster.name,cluster.login,cluster.port,launchcommand);
Note: See TracChangeset for help on using the changeset viewer.