std::string containerNameInNS;
if(params.isMPI){
int nbproc;
- if ( (params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0) )
+ if ( params.nb_proc <= 0 )
nbproc = 1;
- else if ( params.resource_params.nb_node == 0 )
- nbproc = params.resource_params.nb_proc_per_node;
- else if ( params.resource_params.nb_proc_per_node == 0 )
- nbproc = params.resource_params.nb_node;
else
- nbproc = params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ nbproc = params.nb_proc;
if( getenv("LIBBATCH_NODEFILE") != NULL )
machFile = machinesFile(nbproc);
// A mpi parallel container register on zero node in NS
if (params.isMPI)
{
- if ((params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0))
+ if ( params.nb_proc <= 0 )
nbproc = 1;
- else if (params.resource_params.nb_node == 0)
- nbproc = params.resource_params.nb_proc_per_node;
- else if (params.resource_params.nb_proc_per_node == 0)
- nbproc = params.resource_params.nb_node;
else
- nbproc = params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ nbproc = params.nb_proc;
}
// "ssh -l user machine distantPath/runRemote.sh hostNS portNS WORKINGDIR workingdir \
{
o << "mpirun -np ";
- if ( (params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0) )
+ if ( params.nb_proc <= 0 )
nbproc = 1;
- else if ( params.resource_params.nb_node == 0 )
- nbproc = params.resource_params.nb_proc_per_node;
- else if ( params.resource_params.nb_proc_per_node == 0 )
- nbproc = params.resource_params.nb_node;
else
- nbproc = params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ nbproc = params.nb_proc;
o << nbproc << " ";
tempOutputFile << "mpirun -np ";
int nbproc;
- if ( (params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0) )
+ if ( params.nb_proc <= 0 )
nbproc = 1;
- else if ( params.resource_params.nb_node == 0 )
- nbproc = params.resource_params.nb_proc_per_node;
- else if ( params.resource_params.nb_proc_per_node == 0 )
- nbproc = params.resource_params.nb_node;
else
- nbproc = params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ nbproc = params.nb_proc;
std::ostringstream o;
{
if( !isMpiContainer(params) )
return 0;
- else if( (params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0) )
+ else if( params.nb_proc <= 0 )
return 1;
- else if( params.resource_params.nb_node == 0 )
- return params.resource_params.nb_proc_per_node;
- else if( params.resource_params.nb_proc_per_node == 0 )
- return params.resource_params.nb_node;
else
- return params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ return params.nb_proc;
}
//=============================================================================
if ( !params.isMPI )
nbproc = 0;
- else if ( (params.resource_params.nb_node <= 0) && (params.resource_params.nb_proc_per_node <= 0) )
+ else if ( params.nb_proc <= 0 )
nbproc = 1;
- else if ( params.resource_params.nb_node == 0 )
- nbproc = params.resource_params.nb_proc_per_node;
- else if ( params.resource_params.nb_proc_per_node == 0 )
- nbproc = params.resource_params.nb_node;
else
- nbproc = params.resource_params.nb_node * params.resource_params.nb_proc_per_node;
+ nbproc = params.nb_proc;
std::string ret = ContainerName(params.container_name);