Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-09-25 01:45:27

0001 from CRABAPI.RawCommand import crabCommand
0002 from CRABClient.UserUtilities import config
0003 from copy import deepcopy
0004 import os
0005  
0006 def submit(config):
0007     res = crabCommand('submit', config = config)
0008     #save crab config for the future
0009     with open(config.General.workArea + "/crab_" + config.General.requestName + "/crab_config.py", "w") as fi:
0010         fi.write(config.pythonise_())
0011 
0012 samples = [
0013     ("/RelValQCD_FlatPt_15_3000HS_14/CMSSW_12_1_0_pre2-121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "QCD_noPU2"),
0014     ("/RelValQCD_FlatPt_15_3000HS_14/CMSSW_12_1_0_pre2-PU_121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "QCD_PU"),
0015     ("/RelValZEE_14/CMSSW_12_1_0_pre2-PU_121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "ZEE_PU"),
0016     ("/RelValZMM_14/CMSSW_12_1_0_pre2-PU_121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "ZMM_PU"),
0017     ("/RelValTenTau_15_500/CMSSW_12_1_0_pre2-PU_121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "TenTau_PU"),
0018     ("/RelValNuGun/CMSSW_12_1_0_pre2-PU_121X_mcRun3_2021_realistic_v1-v1/GEN-SIM-DIGI-RAW", "NuGun_PU"),
0019 ]
0020 
0021 if __name__ == "__main__":
0022     for dataset, name in samples:
0023 
0024         if os.path.isfile("step3_dump.pyc"):
0025             os.remove("step3_dump.pyc")
0026  
0027         conf = config()
0028         
0029         conf.General.requestName = name
0030         conf.General.transferLogs = True
0031         conf.General.workArea = 'crab_projects'
0032         conf.JobType.pluginName = 'Analysis'
0033         conf.JobType.psetName = 'step3_dump.py'
0034         conf.JobType.maxJobRuntimeMin = 8*60
0035         conf.JobType.allowUndistributedCMSSW = True
0036         conf.JobType.outputFiles = ["step3_inMINIAODSIM.root"]
0037         conf.JobType.maxMemoryMB = 20000
0038         conf.JobType.numCores = 8
0039         
0040         conf.Data.inputDataset = dataset
0041         conf.Data.splitting = 'LumiBased'
0042         conf.Data.unitsPerJob = 10
0043         #conf.Data.totalUnits = 50
0044         conf.Data.publication = False
0045         conf.Data.outputDatasetTag = 'pfvalidation'
0046         conf.Data.ignoreLocality = True
0047         
0048         # Where the output files will be transmitted to
0049         conf.Site.storageSite = 'T3_US_Baylor'
0050         #conf.Site.storageSite = 'T2_US_Caltech'
0051         #conf.Site.whitelist = ["T2_US_Caltech", "T2_CH_CERN"]
0052         
0053         submit(conf)