ATLAS Offline Software
chi0chi1.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
2 
3 from AthenaCommon import Logging
4 from ..powheg_V2 import PowhegV2
5 import glob
6 import os
7 import shutil
8 
9 
10 logger = Logging.logging.getLogger("PowhegControl")
11 
12 
14  """! Default Powheg configuration for neutralino plus chargino production.
15 
16  Create a configurable object with all applicable Powheg options.
17 
18  @author James Robinson <james.robinson@cern.ch>
19  """
20 
21  def __init__(self, base_directory, **kwargs):
22  """! Constructor: all process options are set here.
23 
24  @param base_directory path to PowhegBox code.
25  @param kwargs dictionary of arguments from Generate_tf.
26  """
27  super(chi0chi1, self).__init__(base_directory, os.path.join("weakinos", "neuIchaJ"), powheg_executable="pwhg_main_nixj", **kwargs)
28  if not os.path.isfile("input_mSUGRA.slha"):
29  shutil.copy(os.path.join(os.path.split(self.executable)[0], "testrun", "input_mSUGRA.slha"), ".")
30  logger.info("Locating default mSUGRA input distributed with POWHEG...")
31 
32  # Load SLHA input
33  if len(glob.glob("*.slha")) > 0:
34  input_slha = glob.glob("*.slha")[0]
35  logger.info("Using input SLHA file: {}".format(input_slha))
36  shutil.move(input_slha, "input_parameters.slha")
37  else:
38  logger.info("Locating input SLHA distributed with POWHEG...")
39  shutil.copy(os.path.join(os.path.split(self.executable)[0], "testrun", "input_mSUGRA.slha"), "input_parameters.slha")
40 
41  # Add parameter validation functions
42  self.validation_functions.append("validate_weakinos")
43 
44 
45  self.allowed_weakinos = {"chi10": 1000022, "chi20": 1000023, "chi30": 1000025, "chi40": 1000035, "chi1+": 1000024, "chi1-": -1000024, "chi2+": 1000037, "chi2-": -1000037}
46 
47  # Add all keywords for this process, overriding defaults if required
48  self.add_keyword("bornktmin")
49  self.add_keyword("bornonly")
50  self.add_keyword("bornsuppfact")
51  self.add_keyword("bornzerodamp")
52  self.add_keyword("bottomthr")
53  self.add_keyword("bottomthrpdf")
54  self.add_keyword("btildeborn")
55  self.add_keyword("btildecoll")
56  self.add_keyword("btildereal")
57  self.add_keyword("btildevirt")
58  self.add_keyword("btlscalect")
59  self.add_keyword("btlscalereal")
60  self.add_keyword("charmthr")
61  self.add_keyword("charmthrpdf")
62  self.add_keyword("check_bad_st1")
63  self.add_keyword("check_bad_st2")
64  self.add_keyword("clobberlhe")
65  self.add_keyword("colltest")
66  self.add_keyword("compress_lhe")
67  self.add_keyword("compress_upb")
68  self.add_keyword("compute_rwgt")
69  self.add_keyword("doublefsr")
70  self.add_keyword("evenmaxrat")
71  self.add_keyword("ewi")
72  self.add_keyword("facscfact", self.default_scales[0])
73  self.add_keyword("fakevirtuals")
74  self.add_keyword("fastbtlbound")
75  self.add_keyword("fin1", "chi10", name="neutralino")
76  self.add_keyword("fin2", "chi1+", name="chargino")
77  self.add_keyword("fixedgrid")
78  self.add_keyword("flg_debug")
79  self.add_keyword("foldcsi")
80  self.add_keyword("foldphi")
81  self.add_keyword("foldy")
82  self.add_keyword("fullrwgt")
83  self.add_keyword("hdamp")
84  self.add_keyword("hfact")
85  self.add_keyword("icsimax")
86  self.add_keyword("ih1")
87  self.add_keyword("ih2")
88  self.add_keyword("incomingflavors")
89  self.add_keyword("inv_alpha", -1)
90  self.add_keyword("itmx1", 4)
91  self.add_keyword("itmx1osres")
92  self.add_keyword("itmx1rm")
93  self.add_keyword("itmx2", 5)
94  self.add_keyword("itmx2osres")
95  self.add_keyword("itmx2rm")
96  self.add_keyword("iupperfsr")
97  self.add_keyword("iupperisr")
98  self.add_keyword("iymax")
99  self.add_keyword("lhans1", self.default_PDFs)
100  self.add_keyword("lhans2", self.default_PDFs)
101  self.add_keyword("lhrwgt_descr")
102  self.add_keyword("lhrwgt_group_combine")
103  self.add_keyword("lhrwgt_group_name")
104  self.add_keyword("lhrwgt_id")
105  self.add_keyword("LOevents")
106  self.add_keyword("manyseeds")
107  self.add_keyword("max_io_bufsize")
108  self.add_keyword("maxseeds")
109  self.add_keyword("minlo")
110  self.add_keyword("mintupbratlim")
111  self.add_keyword("mintupbxless")
112  self.add_keyword("ncall1", 10000)
113  self.add_keyword("ncall1osres")
114  self.add_keyword("ncall1rm")
115  self.add_keyword("ncall2", 10000)
116  self.add_keyword("ncall2osres")
117  self.add_keyword("ncall2rm")
118  self.add_keyword("noevents")
119  self.add_keyword("novirtual")
120  self.add_keyword("nubound", 10000)
121  self.add_keyword("olddij")
122  self.add_keyword("par_2gsupp")
123  self.add_keyword("par_diexp")
124  self.add_keyword("par_dijexp")
125  self.add_keyword("parallelstage")
126  self.add_keyword("pdfreweight")
127  self.add_keyword("ptsqmin")
128  self.add_keyword("ptsupp")
129  self.add_keyword("radregion")
130  self.add_keyword("rand1")
131  self.add_keyword("rand2")
132  self.add_keyword("renscfact", self.default_scales[1])
133  self.add_keyword("runningscale")
134  self.add_keyword("rwl_add")
135  self.add_keyword("rwl_file")
136  self.add_keyword("rwl_format_rwgt")
137  self.add_keyword("rwl_group_events")
138  self.add_keyword("skipextratests")
139  self.add_keyword("SLHA")
140  self.add_keyword("smartsig")
141  self.add_keyword("softtest")
142  self.add_keyword("stage2init")
143  self.add_keyword("storeinfo_rwgt")
144  self.add_keyword("storemintupb")
145  self.add_keyword("testplots")
146  self.add_keyword("testsuda")
147  self.add_keyword("ubexcess_correct")
148  self.add_keyword("ubsigmadetails")
149  self.add_keyword("use-old-grid")
150  self.add_keyword("use-old-ubound")
151  self.add_keyword("withdamp")
152  self.add_keyword("withnegweights")
153  self.add_keyword("withsubtr")
154  self.add_keyword("Wmass", -1)
155  self.add_keyword("Wwidth", -1)
156  self.add_keyword("xupbound")
157  self.add_keyword("Zmass", -1)
158  self.add_keyword("Zwidth", -1)
159 
160  def validate_weakinos(self):
161  """! Validate weakinos."""
162  self.expose() # convenience call to simplify syntax
163  # Neutralino
164  self.check_decay_mode(list(self.parameters_by_name("neutralino"))[0].value, [x for x in self.allowed_weakinos.keys() if x[-1] == "0"])
165  list(self.parameters_by_name("neutralino"))[0].value = self.allowed_weakinos[list(self.parameters_by_name("neutralino"))[0].value]
166  # Chargino
167  self.check_decay_mode(list(self.parameters_by_name("chargino"))[0].value, [x for x in self.allowed_weakinos.keys() if x[-1] != "0"])
168  list(self.parameters_by_name("chargino"))[0].value = self.allowed_weakinos[list(self.parameters_by_name("chargino"))[0].value]
python.processes.configurable.Configurable.expose
def expose(self)
Add all names to the interface of this object.
Definition: configurable.py:46
vtune_athena.format
format
Definition: vtune_athena.py:14
python.processes.configurable.Configurable.parameters_by_name
def parameters_by_name(self, name)
Retrieve all parameters that use a given name.
Definition: configurable.py:64
python.processes.powheg_base.PowhegBase.default_scales
def default_scales(self)
Default scale variations for this process.
Definition: powheg_base.py:246
python.processes.configurable.Configurable.add_keyword
def add_keyword(self, keyword, value=None, name=None, frozen=None, hidden=None, description=None, **kwargs)
Register configurable parameter that is exposed to the user.
Definition: configurable.py:21
python.processes.powheg.chi0chi1.chi0chi1.__init__
def __init__(self, base_directory, **kwargs)
Constructor: all process options are set here.
Definition: chi0chi1.py:21
dumpHVPathFromNtuple.append
bool append
Definition: dumpHVPathFromNtuple.py:91
python.processes.powheg_base.PowhegBase.validation_functions
validation_functions
List of validation functions to run before preparing runcard.
Definition: powheg_base.py:179
python.processes.powheg_base.PowhegBase.check_decay_mode
def check_decay_mode(self, decay_mode, allowed_decay_modes=None)
Check whether a decay mode is allowed an raise an exception if it is not.
Definition: powheg_base.py:283
histSizes.list
def list(name, path='/')
Definition: histSizes.py:38
python.processes.powheg_base.PowhegBase.default_PDFs
def default_PDFs(self)
Default PDFs for this process.
Definition: powheg_base.py:241
python.processes.powheg_V2.PowhegV2
Base class for PowhegBox V2 processes.
Definition: powheg_V2.py:6
python.processes.powheg_base.PowhegBase.executable
executable
Powheg executable that will be used.
Definition: powheg_base.py:154
python.processes.powheg.chi0chi1.chi0chi1.validate_weakinos
def validate_weakinos(self)
Validate weakinos.
Definition: chi0chi1.py:160
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
python.processes.powheg.chi0chi1.chi0chi1.allowed_weakinos
allowed_weakinos
List of allowed weakinos.
Definition: chi0chi1.py:45
python.processes.powheg.chi0chi1.chi0chi1
Default Powheg configuration for neutralino plus chargino production.
Definition: chi0chi1.py:13