PEATSA/Core/PEATSAParallel.py
def CreatePBSLaunchScript(executable, arguments, numberOfNodes=4, processorsPerNode=2, queue="short", runDirectory=os.getcwd(), logDirectory=os.getcwd(), keep=True):
	
	'''Creates a PBS script for a parallel job submission'''
	
	argString = " ".join(arguments)
	runString = "%s %s" % (executable, argString)
	
	pbsString = "## Autogenerated script for submitting PEAT_SA to the PBS queue\n\n" 
	pbsString = pbsString + "#PBS -l nodes=%s:ppn=%s\n" % (numberOfNodes, processorsPerNode)
	pbsString = pbsString + "#PBS -j oe\n"
	pbsString = pbsString + "#PBS -q %s\n" % queue
	pbsString = pbsString + "#PBS -d %s\n" % os.path.abspath(runDirectory)
	pbsString = pbsString + "#PBS -o %s\n" % os.path.abspath(logDirectory)
	if keep is True:
		pbsString = pbsString + "#PBS -k oe\n"
	
	pbsString = pbsString + "\nmpirun -np %d python %s\n" % (int(numberOfNodes)*int(processorsPerNode), runString)

	return pbsString
Creates a PBS script for a parallel job submission
Creates a PBS script for a parallel job submission
Creates a PBS script for a parallel job submission
def CreatePBSLaunchScript(executable, arguments, numberOfNodes=4, processorsPerNode=2, queue="short", runDirectory=os.getcwd(), logDirectory=os.getcwd(), keep=True):
	argString = " ".join(arguments)
	runString = "%s %s" % (executable, argString)
	pbsString = "## Autogenerated script for submitting PEAT_SA to the PBS queue\n\n" 
	pbsString = pbsString + "#PBS -l nodes=%s:ppn=%s\n" % (numberOfNodes, processorsPerNode)
	pbsString = pbsString + "#PBS -j oe\n"
	pbsString = pbsString + "#PBS -q %s\n" % queue
	pbsString = pbsString + "#PBS -d %s\n" % os.path.abspath(runDirectory)
	pbsString = pbsString + "#PBS -o %s\n" % os.path.abspath(logDirectory)
	if keep is True:
		pbsString = pbsString + "#PBS -k oe\n"
	pbsString = pbsString + "\nmpirun -np %d python %s\n" % (int(numberOfNodes)*int(processorsPerNode), runString)
	return pbsString
def CreatePBSLaunchScript ( executable , arguments , numberOfNodes = 4 , processorsPerNode = 2 , queue = "short" , runDirectory = os . getcwd ( ) , logDirectory = os . getcwd ( ) , keep = True ) : argString = " " . join ( arguments ) runString = "%s %s" % ( executable , argString ) pbsString = "## Autogenerated script for submitting PEAT_SA to the PBS queue\n\n" pbsString = pbsString + "#PBS -l nodes=%s:ppn=%s\n" % ( numberOfNodes , processorsPerNode ) pbsString = pbsString + "#PBS -j oe\n" pbsString = pbsString + "#PBS -q %s\n" % queue pbsString = pbsString + "#PBS -d %s\n" % os . path . abspath ( runDirectory ) pbsString = pbsString + "#PBS -o %s\n" % os . path . abspath ( logDirectory ) if keep is True : pbsString = pbsString + "#PBS -k oe\n" pbsString = pbsString + "\nmpirun -np %d python %s\n" % ( int ( numberOfNodes ) * int ( processorsPerNode ) , runString ) return pbsString
Creates a PBS script for a parallel job submission
Creates a PBS script for a parallel job submission
'''Creates a PBS script for a parallel job submission'''
executable
arguments
numberOfNodes
processorsPerNode
queue
runDirectory
logDirectory
keep