Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
Run2Support
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
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
LHCb
Run2Support
Merge requests
!56
Draft: Remove use of DDDB when using DD4hep
Code
Review changes
Check out branch
Download
Patches
Plain diff
Closed
Draft: Remove use of DDDB when using DD4hep
gcorti_handle_dd4hep
into
master
Overview
12
Commits
4
Pipelines
4
Changes
1
Closed
Gloria Corti
requested to merge
gcorti_handle_dd4hep
into
master
1 year ago
Overview
12
Commits
4
Pipelines
4
Changes
1
Expand
Backport and adapt changes from LHCb as done in DDDB in
LHCb!3510 (merged)
0
0
Merge request reports
Compare
master
version 4
4a434fda
1 year ago
version 3
5c8a494c
1 year ago
version 2
20668fb5
1 year ago
version 1
f1f0e0dd
1 year ago
master (base)
and
latest version
latest version
4a434fda
4 commits,
1 year ago
version 4
4a434fda
4 commits,
1 year ago
version 3
5c8a494c
3 commits,
1 year ago
version 2
20668fb5
2 commits,
1 year ago
version 1
f1f0e0dd
1 commit,
1 year ago
1 file
+
71
−
1
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Det/DDDB/python/DDDB/Configuration.py
+
71
−
1
Options
@@ -87,10 +87,12 @@ class DDDBConf(ConfigurableUser):
False
,
"
EnableRunStampCheck
"
:
False
,
"
GeometryBackend
"
:
""
,
"
GeometryLocation
"
:
""
,
"
GeometryVersion
"
:
"
trunk
"
,
"
run3/
trunk
"
,
"
GeometryMain
"
:
"
LHCb.xml
"
,
"
ConditionsLocation
"
:
@@ -117,6 +119,8 @@ class DDDBConf(ConfigurableUser):
"""
Disable check on latest update of ONLINE CondDB
"""
,
'
EnableRunStampCheck
'
:
"""
Enable the check for run stamp (valid data for the run)
"""
,
'
GeometryBackend
'
:
"""
Format of the geometry, i.e. DD4Hep or DetDesc, when empty it means not DD4Hep
"""
,
'
GeometryLocation
'
:
"""
Top directory for the DD4hep geometry files
"""
,
'
GeometryVersion
'
:
@@ -129,6+133,6 @@
"""
Tag for the conditions database
"""
,
}
__used_configurables__
=
[
CondDB
]
def
__apply_configuration__
(
self
):
"""
Converts the high-level information passed as properties into low-level configuration.
"""
##########################################################################
# DD4hep Detector Configuration
##########################################################################
##########################################################################
if
(
self
.
getProp
(
"
GeometryBackend
"
).
upper
()
==
"
DD4HEP
"
):
from
Configurables
import
LHCb__Det__LbDD4hep__DD4hepSvc
as
DD4hepSvc
dd4hepSvc
=
DD4hepSvc
()
if
self
.
getProp
(
"
GeometryLocation
"
)
and
not
dd4hepSvc
.
isPropertySet
(
"
GeometryLocation
"
):
dd4hepSvc
.
GeometryLocation
=
self
.
getProp
(
"
GeometryLocation
"
)
if
self
.
getProp
(
"
GeometryVersion
"
)
and
not
dd4hepSvc
.
isPropertySet
(
"
GeometryVersion
"
):
dd4hepSvc
.
GeometryVersion
=
self
.
getProp
(
"
GeometryVersion
"
)
if
self
.
getProp
(
"
GeometryMain
"
)
and
not
dd4hepSvc
.
isPropertySet
(
"
GeometryMain
"
):
dd4hepSvc
.
GeometryMain
=
self
.
getProp
(
"
GeometryMain
"
)
if
self
.
getProp
(
"
ConditionsVersion
"
)
and
not
dd4hepSvc
.
isPropertySet
(
"
ConditionsVersion
"
):
dd4hepSvc
.
ConditionsVersion
=
self
.
getProp
(
"
ConditionsVersion
"
)
if
self
.
getProp
(
"
ConditionsLocation
"
)
and
not
dd4hepSvc
.
isPropertySet
(
"
ConditionsLocation
"
):
dd4hepSvc
.
ConditionsLocation
=
self
.
getProp
(
"
ConditionsLocation
"
)
else
:
if
not
hasattr
(
dd4hepSvc
,
"
ConditionsLocation
"
):
lhcb_cond_db
=
GIT_CONDDBS
.
get
(
"
lhcb-conditions-database
"
,
None
)
if
not
lhcb_cond_db
:
log
.
warning
(
"
Could not find git repository: lhcb-conditions-database
"
)
else
:
url
=
"
git:
"
+
lhcb_cond_db
if
(
not
lhcb_cond_db
.
endswith
(
"
.git
"
)):
url
=
"
file:
"
+
lhcb_cond_db
+
"
/
"
log
.
info
(
"
Using git repository:
"
+
url
)
dd4hepSvc
.
ConditionsLocation
=
url
if
self
.
getProp
(
"
DD4HepDetectorList
"
):
if
not
hasattr
(
dd4hepSvc
,
"
DetectorList
"
):
dd4hepSvc
.
DetectorList
=
self
.
getProp
(
"
DD4HepDetectorList
"
)
log
.
info
(
dd4hepSvc
)
# make sure we do not use HeartBeat and RunStampCheck in DD4hep mode
self
.
_properties
[
"
IgnoreHeartBeat
"
].
setDefault
(
True
)
self
.
_properties
[
"
EnableRunStampCheck
"
].
setDefault
(
False
)
# FIXME: We need to find a way to configure LHCb__ParticlePropertySvc for Run3
from
Configurables
import
LHCb__ParticlePropertySvc
pps
=
LHCb__ParticlePropertySvc
()
if
not
pps
.
isPropertySet
(
"
ParticlePropertiesFile
"
):
from
PartProp
import
DEFAULT_PARTICLE_PROPERTY_FILE
pps
.
ParticlePropertiesFile
=
str
(
DEFAULT_PARTICLE_PROPERTY_FILE
)
return
# everything else in this function is about using the old CondDB
##########################################################################
# Detector Transient Store Configuration
##########################################################################
Loading