def main(): """Submit a simple example job""" out_dir = "toymass13_30k_test" jobs = JDLCreator( ) # Default (no Cloud Site supplied): Docker with SLC6 image # Some example sites: # site_name='ekpsupermachines' "Super Machines" IO intesiv jobs jobs.executable = "job.sh" # name of the job script jobs.wall_time = 11 * 60 * 60 # job will finish in 10 hours jobs.memory = 1900 # Our regular 2048 MB per slot jobs.accounting_group = "cms.higgs" jobs.input_files = "/usr/users/friese/toymass/pythia_eventgeneration/eventgeneration,/usr/users/friese/toymass/pythia_eventgeneration/job.sh,/usr/users/friese/.globus/proxy.grid" arguments = [] for masses in range(40, 50, 2): #for masses in range(40,3200,2): for seed in [20]: for channel in ["tt", "mt", "et", "em", "mm", "ee"]: for invert in ["true", "false"]: arguments.append(" ".join([ str(x) for x in [masses, seed, channel, invert, out_dir] ])) print len(arguments) jobs.arguments = arguments # set arguments for condor job # Our job requires lots of CPU resources and needs access to the local EKP resources jobs.requirements = '(TARGET.ProvidesCPU ==True)' jobs.job_folder = "condor_jobs_" + out_dir # set name of the folder, where files and information are stored jobs.AddExtraLines('+RemoteJob = True') jobs.AddExtraLines('x509userproxy = /usr/users/friese/.globus/proxy.grid') jobs.WriteJDL() # write an JDL file and create folder for log files jobs.Submit()
def main(args): jobs = JDLCreator("docker") jobs.executable = "gof/job.sh" jobs.wall_time = 5 * 60 * 60 jobs.memory = 4096 jobs.accounting_group = "cms.higgs" jobs.image = "mschnepf/slc7-condocker" # Build list of arguments arguments = [] binning = yaml.load(open(args.binning)) variables = yaml.load(open(args.variables)) # 1D fits for channel in binning["gof"]: for variable in variables["selected_variables"][int(args.era)][channel]: arguments.append("{} {} {} {}".format(args.era, channel, variable, os.getcwd())) # 2D fits for channel in binning["gof"]: selected_2d_fits = [] for var1 in variables["selected_variables"][int(args.era)][channel]: for var2 in variables["selected_variables"][int(args.era)][channel]: selected_2d_fits.append("{}_{}".format(var1, var2)) for variable in selected_2d_fits: if variable in binning["gof"][channel]: arguments.append("{} {} {} {}".format(args.era, channel, variable, os.getcwd())) jobs.arguments = arguments # The job requires lots of CPU resources jobs.requirements = '(Target.ProvidesCPU == True) && (Target.ProvidesIO == True ) && (Target.ProvidesEKPResources == True)' jobs.job_folder = args.output jobs.WriteJDL()
def main(args): jobs = JDLCreator("ekpsupermachines") jobs.executable = "ml/job.sh" jobs.wall_time = 10 * 60 * 60 jobs.memory = 2048 jobs.accounting_group = "cms.higgs" jobs.image = "stwunsch/slc6-condocker:smhtt" # Build list of arguments arguments = [] for modifier in args.modifiers: arguments.append("{} {}".format(args.channel, modifier)) jobs.arguments = arguments # The job requires lots of CPU resources # NOTE: This selects the sg machines. jobs.requirements = "(Target.ProvidesCPU == True) && (Target.ProvidesEKPResources == True)" jobs.job_folder = args.output jobs.WriteJDL()
def main(args): jobs = JDLCreator("ekpsupermachines") jobs.executable = "gof/job.sh" jobs.wall_time = 1 * 60 * 60 jobs.memory = 2048 jobs.accounting_group = "cms.higgs" jobs.image = "stwunsch/slc6-condocker:smhtt" # Build list of arguments arguments = [] config = yaml.load(open(args.binning)) for channel in config["gof"]: for variable in config["gof"][channel]: arguments.append("{} {}".format(channel, variable)) jobs.arguments = arguments # The job requires lots of CPU resources # NOTE: This selects the sg machines. jobs.requirements = '(Target.ProvidesCPU == True) && (Target.ProvidesEKPResources == True)' jobs.job_folder = args.output jobs.WriteJDL()