123456789101112131415161718192021222324252627282930 |
- import sys
- import os
- if __name__=="__main__":
- if len(sys.argv)!=2:
- print("Usage : python3 "+sys.argv[0]+" genus")
- exit(-1)
- g=int(sys.argv[1])
- mmax=int((3*(g+2))/5)
- n=0
- file=open("output/param_"+repr(g),'w')
- for m in range(2,mmax+1):
- for k in range(1,m):
- file.write(repr(m)+' '+repr(k)+"\n")
- n+=1
- file.close()
- print("Split in ",n," subtasks")
- os.system("make clean;make MAX_GENUS="+repr(g))
- file=open("oar_wilf.sh",'w')
- file.write("#!/bin/sh\n")
- file.write("#OAR -l core=1,walltime=02:00:00\n")
- file.write("#OAR -t idempotent\n")
- file.write("#OAR -q besteffort\n")
- file.write("#OAR -t besteffort\n")
- #OAR -p cputype="skylake"
- file.write("#OAR --array-param-file output/param_"+repr(g)+"\n")
- file.write("#OAR -O output/job.%jobid%.output\n")
- file.write("#OAR -E output/job.%jobid%.error\n")
- file.write("wilf_alone $*\n")
- file.close()
|