14 for f
in glob.glob(
"*.events"):
17 newfile = infile+
'.temp'
20 if line.startswith(
' 25 1'):
21 f2.write(line.replace(
' 25 1',
' 35 1'))
26 os.system(
'mv %s %s '%(infile, infile+
'.old') )
27 os.system(
'mv %s %s '%(newfile, infile) )
34 dict_pdgIds[
"mu"] = 13
35 dict_pdgIds[
"tau"] = 15
47 for substr
in jonamelist:
53 print(
"squirrel",jonamelist,tune)
54 process = jonamelist[tune+1]
56 decayChan =
str(jonamelist[tune+4])
58 if len(jonamelist)-tune>5:
59 partFilter =
str(jonamelist[tune+5])
63 for part
in dict_pdgIds.keys():
64 decay = re.findall(
"[1-4]%s" % part, decayChan)
66 decayProducts.append(decay[0][1:])
68 return process, ma, decayChan, decayProducts, partFilter
71 process, ma, decayChan, decayProducts, partFilter =
getParameters()
73 print process, ma, decayChan, decayProducts, partFilter
78 include(
'Pythia8_i/Pythia8_AZNLO_CTEQ6L1_EvtGen_Common.py')
85 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 2']
87 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 3']
89 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 3']
91 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 3']
93 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 3']
95 genSeq.Pythia8.UserModes += [
'Main31:NFinal = 2']
102 genSeq.Pythia8.Commands += [
105 '35:mWidth = 0.00407',
106 '35:doForceWidth = on',
108 '35:onIfMatch = 36 36',
117 if len(decayProducts)==1:
118 genSeq.Pythia8.Commands += [
119 '36:onIfAny = %d' % dict_pdgIds[decayProducts[0]],
124 elif len(decayProducts)==2:
127 for part
in decayProducts:
128 pdgId = dict_pdgIds[part]
129 if pdgId==21
or pdgId==22:
132 genSeq.Pythia8.Commands += [
133 '36:oneChannel = 1 0.5 100 %d %d' % (dict_pdgIds[decayProducts[0]], sign*dict_pdgIds[decayProducts[0]]),
134 '36:addChannel = 1 0.5 100 %d %d' % (dict_pdgIds[decayProducts[1]], sign*dict_pdgIds[decayProducts[1]]),
136 '36:mMin %.1f' % (ma-0.5),
137 '36:mMax %.1f' % (ma+0.5),
146 evgenConfig.keywords = [
"BSM",
"Higgs",
"BSMHiggs",
"mH125"]
148 if process==
"ggH" and (decayChan==
"2b2mu" or decayChan==
"2mu2b"):
149 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->bbmumu mh=125 GeV"
150 evgenConfig.process =
"ggH H->aa->bbmumu"
151 evgenConfig.contact = [
'christopher.hayes@cern.ch',
'ljiljana.morvaj@cern.ch' ]
153 if process==
"VBF" and (decayChan==
"2b2mu" or decayChan==
"2mu2b"):
154 evgenConfig.description =
"POWHEG+Pythia8 VBF H production, H->aa->bbmumu mh=125 GeV"
155 evgenConfig.process =
"VBF H->aa->bbmumu"
156 evgenConfig.contact = [
'christopher.hayes@cern.ch',
'ljiljana.morvaj@cern.ch' ]
158 if process==
"ggH" and decayChan==
"4tau":
159 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->4tau mh=125 GeV"
160 evgenConfig.process =
"ggH H->aa->4tau"
161 evgenConfig.contact = [
'rachel.smith@cern.ch',
'huacheng.cai@cern.ch',
'roger.caminal.armadans@cern.ch' ]
163 if process==
"ggH" and (decayChan==
"2mu2tau" or decayChan==
"2tau2mu"):
164 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->mumutautau mh=125 GeV"
165 evgenConfig.process =
"ggH H->aa->mumutautau"
166 evgenConfig.contact = [
'josefina.alconada@cern.ch' ]
168 if process==
"ggH" and (decayChan==
"2b2tau" or decayChan==
"2tau2b"):
169 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->bbtautau mh=125 GeV"
170 evgenConfig.process =
"ggH H->aa->bbtautau"
171 evgenConfig.contact = [
'christopher.hayes@cern.ch',
'ljiljana.morvaj@cern.ch' ]
173 if process==
"VBF" and (decayChan==
"2b2tau" or decayChan==
"2tau2b"):
174 evgenConfig.description =
"POWHEG+Pythia8 VBF H production, H->aa->bbtautau mh=125 GeV"
175 evgenConfig.process =
"VBF H->aa->bbtautau"
176 evgenConfig.contact = [
'christopher.hayes@cern.ch',
'ljiljana.morvaj@cern.ch' ]
178 if process==
"ggH" and (decayChan==
"2y2g" or decayChan==
"2g2y"):
179 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->gamgamgg mh=125 GeV"
180 evgenConfig.process =
"ggH H->aa->gamgamgg"
181 evgenConfig.contact = [
'rubbo@cern.ch' ]
183 if process==
"VBF" and (decayChan==
"2y2g" or decayChan==
"2g2y"):
184 evgenConfig.description =
"POWHEG+Pythia8 VBF H production, H->aa->gamgamgg mh=125 GeV"
185 evgenConfig.process =
"VBF H->aa->gamgamgg"
186 evgenConfig.contact = [
'rubbo@cern.ch' ]
188 if process==
"ggH" and (decayChan==
"4mu"):
189 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->4mu mh=125 GeV"
190 evgenConfig.process =
"ggH H->aa->4mu"
191 evgenConfig.contact = [
'roger.caminal.armadans@cern.ch' ]
193 if process==
"WpH" and decayChan==
"4b":
194 evgenConfig.description =
"POWHEG+MiNLO+Pythia8 H+W+jet->l+vbbbarbbbar production"
195 evgenConfig.process =
"WpH, H->aa->4b, W->lv"
196 evgenConfig.contact = [
'roger.caminal.armadans@cern.ch' ]
198 if process==
"WmH" and decayChan==
"4b":
199 evgenConfig.description =
"POWHEG+MiNLO+Pythia8 H+W-jet->l-vbbbarbbbar production"
200 evgenConfig.process =
"WmH, H->aa->4b, W->lv"
201 evgenConfig.contact = [
'roger.caminal.armadans@cern.ch' ]
203 if process==
"ZH" and decayChan==
"4b":
204 evgenConfig.description =
"POWHEG+MiNLO+Pythia8 H+Z+jet->l+l-bbbarbbbar production"
205 evgenConfig.process =
"ZH, H->aa->4b, Z->ll"
206 evgenConfig.contact = [
'roger.caminal.armadans@cern.ch' ]
208 if process==
"ggZH" and decayChan==
"4b":
209 evgenConfig.description =
"POWHEG+MiNLO+Pythia8 gg->H+Z+jet->l+l-bbbarbbbar production"
210 evgenConfig.process =
"ggZH, H->2a->4b, Z->ll"
211 evgenConfig.contact = [
'roger.caminal.armadans@cern.ch' ]
213 if process==
"ZH" and decayChan==
"4g":
214 evgenConfig.description =
"POWHEG+MiNLO+Pythia8 H+Z+jet->l+l-gggg production"
215 evgenConfig.process =
"ZH, H->aa->4g, Z->ll"
216 evgenConfig.contact = [
'bnachman@cern.ch' ]
218 if process==
"ggH" and decayChan==
"4y":
219 evgenConfig.description =
"POWHEG+Pythia8 H+jet production with NNLOPS and the A14 tune, H->aa->4\gamma mh=125 GeV"
220 evgenConfig.process =
"ggH, H->aa->4y"
221 evgenConfig.contact = [
'bnachman@cern.ch' ]
226 if partFilter==
"filterXXYY" or partFilter==
"filterlh" or partFilter==
"filterll":
227 if not hasattr(filtSeq,
"XtoVVDecayFilter"):
228 from GeneratorFilters.GeneratorFiltersConf
import XtoVVDecayFilter
229 filtSeq += XtoVVDecayFilter()
230 if(partFilter==
"filterlh" or partFilter==
"filterll"):
231 filtSeq+= XtoVVDecayFilter(
"tauscalarFilter")
235 filtSeq.XtoVVDecayFilter.PDGGrandParent = 35
236 filtSeq.XtoVVDecayFilter.PDGParent = 36
237 filtSeq.XtoVVDecayFilter.StatusParent = 22
238 print [dict_pdgIds[decayProducts[0]]], [dict_pdgIds[decayProducts[1]]]
239 filtSeq.XtoVVDecayFilter.PDGChild1 = [dict_pdgIds[decayProducts[0]]]
240 filtSeq.XtoVVDecayFilter.PDGChild2 = [dict_pdgIds[decayProducts[1]]]
241 if(partFilter==
"filterlh" or partFilter==
"filterll"):
242 filtSeq.tauscalarFilter.PDGGrandParent = 36
243 filtSeq.tauscalarFilter.PDGParent = 15
244 filtSeq.tauscalarFilter.StatusParent = 2
245 filtSeq.tauscalarFilter.PDGChild1 = [11,13]
246 if partFilter==
"filterll":
247 filtSeq.tauscalarFilter.PDGChild2 = [11,13]
248 elif partFilter==
"filterlh":
249 filtSeq.tauscalarFilter.PDGChild2 = [111,130,211,221,223,310,311,321,323]
251 elif partFilter==
"filter2taulep2tauhad":
254 from GeneratorFilters.GeneratorFiltersConf
import TauFilter
255 lfvfilter = TauFilter(
"lfvfilter")
257 filtSeq.lfvfilter.UseNewOptions =
True
258 filtSeq.lfvfilter.Ntaus = 4
259 filtSeq.lfvfilter.Nleptaus = 2
260 filtSeq.lfvfilter.Nhadtaus = 2
261 filtSeq.lfvfilter.EtaMaxlep = 2.7
262 filtSeq.lfvfilter.EtaMaxhad = 2.7
263 filtSeq.lfvfilter.Ptcutlep = 3000.0
264 filtSeq.lfvfilter.Ptcutlep_lead = 3000.0
265 filtSeq.lfvfilter.Ptcuthad = 12500.0
266 filtSeq.lfvfilter.Ptcuthad_lead = 12500.0