Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
athena
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
John Derek Chapman
athena
Commits
eb399ad0
Commit
eb399ad0
authored
6 years ago
by
Tomasz Bold
Browse files
Options
Downloads
Patches
Plain Diff
Drops deprecated flags get/set functions, adds ESD output related flags
parent
a7745206
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Control/AthenaConfiguration/python/AllConfigFlags.py
+16
-29
16 additions, 29 deletions
Control/AthenaConfiguration/python/AllConfigFlags.py
Control/AthenaConfiguration/python/AthConfigFlags.py
+0
-11
0 additions, 11 deletions
Control/AthenaConfiguration/python/AthConfigFlags.py
with
16 additions
and
40 deletions
Control/AthenaConfiguration/python/AllConfigFlags.py
+
16
−
29
View file @
eb399ad0
...
...
@@ -8,43 +8,30 @@ from AthenaConfiguration.AutoConfigFlags import GetFileMD
def
_createCfgFlags
():
acf
=
AthConfigFlags
()
#Global Flags:
#They are becoming, please use the specific flags below.
# acf.addFlag('global.InputFiles',["_ATHENA_GENERIC_INPUTFILE_NAME_",])
# acf.addFlag('global.isOnline',False)
# acf.addFlag('global.GeoLayout',"atlas")
# acf.addFlag('global.ProjectName',lambda prevFlags : GetFileMD(prevFlags.get("global.InputFiles")).get("Project","data17_13TeV"))
# acf.addFlag('global.isMC',lambda prevFlags : GetFileMD(prevFlags.get("global.InputFiles")).get("isMC",None))
# acf.addFlag('global.BunchSpacing',25) # Bunch spacing in ns
# acf.addFlag("global.NumberOfCollisions",0) #"Number of collisions per beam crossing. Should be 2.3*(L/10**33)*(bunchSpacing/25 ns)
# acf.addFlag("global.BeamType",'collisions') # "Specify data taking type: 'collisions' (default), 'singlebeam','cosmics'")
# acf.addFlag("global.BeamEnergy",lambda prevFlags : GetFileMD(prevFlags.get("global.InputFiles")).get("BeamEnergy",7*TeV))
# acf.addFlag("global.estimatedLuminosity",lambda prevFlags : 1E33*(prevFlags.get("global.NumberOfCollisions")/2.3)* \
# (25./prevFlags.get("global.BunchSpacing")))
# acf.addFlag("global.RunNumber",lambda prevFlags : list(GetFileMD(prevFlags.get("global.InputFiles")).get("RunNumber",None)))
# Replacement for global flags
# people please comment here
acf
.
addFlag
(
'
Input.Files
'
,
[
"
_ATHENA_GENERIC_INPUTFILE_NAME_
"
,]
)
acf
.
addFlag
(
'
Input.isMC
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
isMC
"
,
None
))
acf
.
addFlag
(
'
Input.RunNumber
'
,
lambda
prevFlags
:
list
(
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
RunNumber
"
,
None
)))
acf
.
addFlag
(
'
Input.ProjectName
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
Project
"
,
"
data17_13TeV
"
)
)
acf
.
addFlag
(
'
Input.Files
'
,
[
"
_ATHENA_GENERIC_INPUTFILE_NAME_
"
,]
)
# fromer global.InputFiles
acf
.
addFlag
(
'
Input.isMC
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
isMC
"
,
None
))
# former global.isMC
acf
.
addFlag
(
'
Input.RunNumber
'
,
lambda
prevFlags
:
list
(
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
RunNumber
"
,
None
)))
# former global.RunNumber
acf
.
addFlag
(
'
Input.ProjectName
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
Project
"
,
"
data17_13TeV
"
)
)
# former global.ProjectName
acf
.
addFlag
(
'
Common.isOnline
'
,
False
)
# Job runs in an online environment (access only to resources available at P1)
acf
.
addFlag
(
'
Common.isOnline
'
,
False
)
# Job runs in an online environment (access only to resources available at P1)
# former global.isOnline
# replace global.Beam*
acf
.
addFlag
(
'
Beam.BunchSpacing
'
,
25
)
acf
.
addFlag
(
"
Beam.NumberOfCollisions
"
,
0
)
acf
.
addFlag
(
'
Beam.Type
'
,
'
collisions
'
)
acf
.
addFlag
(
'
Beam.Energy
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
'
BeamEnergy
'
,
7
*
TeV
))
acf
.
addFlag
(
'
Beam.BunchSpacing
'
,
25
)
# former global.BunchSpacing
acf
.
addFlag
(
"
Beam.NumberOfCollisions
"
,
0
)
# former global.NumberOfCollisions
acf
.
addFlag
(
'
Beam.Type
'
,
'
collisions
'
)
# former global.BeamType
acf
.
addFlag
(
'
Beam.Energy
'
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
'
BeamEnergy
'
,
7
*
TeV
))
# former global.BeamEnergy
acf
.
addFlag
(
'
Beam.estimatedLuminosity
'
,
lambda
prevFlags
:
(
1E33
*
(
prevFlags
.
Beam
.
NumberOfCollisions
)
/
2.3
)
*
\
(
25.
/
prevFlags
.
Beam
.
BunchSpacing
))
(
25.
/
prevFlags
.
Beam
.
BunchSpacing
))
# former flobal.estimatedLuminosity
acf
.
addFlag
(
'
Output.doESD
'
,
False
)
# produce ESD containers
acf
.
addFlag
(
'
Output.writeESD
'
,
False
)
# configure ESD output writing
#Geo Model Flags:
acf
.
addFlag
(
'
GeoModel.Layout
'
,
'
atlas
'
)
# replaces global.GeoLayout
acf
.
addFlag
(
"
GeoModel.AtlasVersion
"
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
Geometry
"
,
"
ATLAS-R2-2016-01-00-01
"
))
acf
.
addFlag
(
"
GeoModel.AtlasVersion
"
,
lambda
prevFlags
:
GetFileMD
(
prevFlags
.
Input
.
Files
).
get
(
"
Geometry
"
,
"
ATLAS-R2-2016-01-00-01
"
))
#
#IOVDbSvc Flags:
...
...
This diff is collapsed.
Click to expand it.
Control/AthenaConfiguration/python/AthConfigFlags.py
+
0
−
11
View file @
eb399ad0
...
...
@@ -93,11 +93,6 @@ class AthConfigFlags(object):
def
hasFlag
(
self
,
name
):
return
name
in
self
.
_flagdict
def
set
(
self
,
name
,
value
):
import
warnings
warnings
.
warn
(
"
The flags should be set with programatic syntax: flag.
"
+
name
,
stacklevel
=
2
)
self
.
_set
(
name
,
value
)
def
_set
(
self
,
name
,
value
):
if
(
self
.
_locked
):
raise
RuntimeError
(
"
Attempt to set a flag of an already-locked container
"
)
...
...
@@ -110,12 +105,6 @@ class AthConfigFlags(object):
if
len
(
closestMatch
)
>
0
:
errString
+=
"
. Did you mean
\'
%s
\'
?
"
%
closestMatch
[
0
]
raise
KeyError
(
errString
)
def
get
(
self
,
name
):
import
warnings
warnings
.
warn
(
"
The flags should be red with programatic syntax: flag.
"
+
name
,
stacklevel
=
2
)
return
self
.
_get
(
name
)
def
_get
(
self
,
name
):
try
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment