ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Generators
PMGSystematicsTools
data
RivetAnalysis_JO.py
Go to the documentation of this file.
1
import
os
2
3
theApp.EvtMax = -1
4
5
import
AthenaPoolCnvSvc.ReadAthenaPool
6
svcMgr.EventSelector.InputCollections = [
"!TESTSAMPLE!"
]
7
8
systWeights =!SYSTWEIGHTS!
9
10
from
AthenaCommon.AlgSequence
import
AlgSequence
11
job = AlgSequence()
12
13
from
Rivet_i.Rivet_iConf
import
Rivet_i
14
15
16
from
AthenaCommon.AppMgr
import
ServiceMgr
as
svcMgr
17
from
GaudiSvc.GaudiSvcConf
import
THistSvc
18
19
svcMgr += THistSvc()
20
21
def
safeFileName
(name):
22
name=name.strip()
23
name= name.replace(
"."
,
"p"
).
replace
(
" "
,
"_"
)
24
name= name.replace(
"pyoda"
,
".yoda"
)
25
name= name.replace(
":"
,
"_"
)
26
return
name
27
28
if
systWeights==
None
: systWeights={
'Nominal'
: 0}
29
30
analyses=
"!RIVETANALYSIS!"
31
for
i
in
systWeights:
32
systName=
safeFileName
(i)
33
34
print
(
'weight name:'
,i,
', output name'
,systName)
35
36
rivet =
Rivet_i
(systName)
37
for
analysis
in
analyses.split(
","
):
38
rivet.Analyses +=[analysis]
39
40
rivet.RunName =
""
41
#rivet.HistoFile = "myanalysis"
42
if
i!=
"Nominal"
: rivet.WeightName=i
43
rivet.HistoFile = systName
44
rivet.DoRootHistos =
False
45
#rivet.IgnoreBeamCheck = True
46
rivet.AnalysisPath = os.environ[
'PWD'
]
47
rivet.CrossSection = 1.0
48
49
job += rivet
50
print
void print(char *figname, TCanvas *c1)
Definition
TRTCalib_StrawStatusPlots.cxx:26
Rivet_i
Interface to the Rivet analysis package.
Definition
Rivet_i.h:31
replace
std::string replace(std::string s, const std::string &s2, const std::string &s3)
Definition
hcg.cxx:312
RivetAnalysis_JO.safeFileName
safeFileName(name)
Definition
RivetAnalysis_JO.py:21
Generated on
for ATLAS Offline Software by
1.17.0