当我使用python-drmaa提交任务时,出现如下问题:
在jt.nativeSpecification中添加-clear参数,如标题所述,我们遇到了问题。
删除-clear参数,一切正常。
请给我一些有关此问题的线索。 非常感谢。
#!/usr/bin/env python
import drmaa
import os
def main():
"""
Submit a job.
Note, need file called sleeper.sh in current directory.
"""
with drmaa.Session() as s:
print('Creating job template')
jt = s.createJobTemplate()
jt.workingDirectory = os.getcwd()
jt.remoteCommand = os.path.join(os.getcwd(), 'test.sh')
jt.nativeSpecification = "-clear -binding linear:1 -P MASSspe -q bc.q -cwd -l vf=0.5g -l num_proc=1"
#jt.nativeSpecification = "-binding linear:1 -P MASSspe -q bc.q -cwd -l vf=0.5g -l num_proc=1"
jobid = s.runJob(jt)
print('Your job has been submitted with ID %s' % jobid)
print('Cleaning up')
s.deleteJobTemplate(jt)
if __name__=='__main__':
main()