toil.batchSystems.gridengine

Attributes

logger

Classes

GridEngineBatchSystem

A partial implementation of BatchSystemSupport for batch systems run on a

Module Contents

toil.batchSystems.gridengine.logger
class toil.batchSystems.gridengine.GridEngineBatchSystem(config, maxCores, maxMemory, maxDisk)[source]

Bases: toil.batchSystems.abstractGridEngineBatchSystem.AbstractGridEngineBatchSystem

A partial implementation of BatchSystemSupport for batch systems run on a standard HPC cluster. By default auto-deployment is not implemented.

Parameters:
class GridEngineThread(newJobsQueue, updatedJobsQueue, killQueue, killedJobsQueue, boss)[source]

Bases: toil.batchSystems.abstractGridEngineBatchSystem.AbstractGridEngineBatchSystem.GridEngineThread[list[str]]

Grid Engine-specific AbstractGridEngineWorker methods

Parameters:
getRunningJobIDs()[source]

Get the running Toil job IDs and how long each has been running, in seconds. Implementation-specific; called by boss AbstractGridEngineBatchSystem implementation via AbstractGridEngineBatchSystem.getRunningBatchJobIDs()

Return type:

dict[int, float]

killJob(jobID)[source]

Kill specific job with the Toil job ID. Implementation-specific; called by GridEngineThread.killJobs()

Parameters:

jobID (string) – Toil job ID

Return type:

None

prepareSubmission(cpu, memory, disk, walltime, jobID, command, jobName, job_environment=None, gpus=None)[source]

Preparation in putting together something submittable for submitting to batch system (via submitJob().)

Param:

cpu: number of cores

Param:

memory: bytes of memory

Param:

disk: bytes of disk

Param:

walltime: amount of wall clock time in seconds

Param:

jobID: Toil job ID

Param:

command: the command line string to be called

Param:

jobName: the name of the Toil job, to provide metadata to batch systems if desired

Param:

job_environment: the environment variables to be set on the worker

Param:

gpus: number of gpus

Returns:

the submission to pass to submitJob()

Parameters:
Return type:

list[str]

submitJob(subLine)[source]

Wrapper routine for submitting the actual command-line call, then processing the output to get the batch system job ID

Param:

string subLine: the literal command line string to be called

Return type:

string: batch system job ID, which will be stored internally

Parameters:

subLine (list[str])

getJobExitCode(batchJobID)[source]

Get job exist code, checking both qstat and qacct. Return None if still running. Higher level should retry on CalledProcessErrorStderr, for the case the job has finished and qacct result is stale.

Parameters:

batchJobID (str)

Return type:

int | None

prepareQsub(cpu, mem, jobID, job_environment=None)[source]
Parameters:
Return type:

list[str]

classmethod getWaitDuration()[source]
Return type:

float