def runJob(self, log, programName, params, numberOfMpi=1, numberOfThreads=1, env=None, cwd=None): # Import mpi here so if MPI4py was not properly compiled # we can still run in parallel with threads. from pyworkflow.utils.mpi import runJobMPI node = threading.current_thread().thId + 1 runJobMPI(programName, params, self.comm, node, numberOfMpi, hostConfig=self.hostConfig, env=env, cwd=cwd)