runtraj.execution.job_script#
- runtraj.execution.job_script(project, execution, folder, n_tasks, *, skip_existing=True, compute_root=None)[source]#
Return the
sbatchscript of a job array whose tasks each run a share of the releases.Task
irunsruntraj run <project> --releases <folder>/releases.parquet --task i/n_tasks --execution <folder>/execution.yaml --cpus <cpus>with the Python that called this: a task runs its share here,cpusreleases at once. The#SBATCHlines come from execution’sslurmblock: its resources,--requeue,--signal=B:USR1@120(seerun()), and its othersbatchoptions, which can replace any of them. Itssetupcommands run before the task, after the script exportsOMP_NUM_THREADSas the task’s CPUs divided by the workers it runs at once (cpus), which asetupline can export again. NumPy’s BLAS follows it, so a worker does not start a thread pool the size of the node.