Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
reconstruction_benchmarks
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
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
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
EIC
benchmarks
reconstruction_benchmarks
Commits
aad451ea
Commit
aad451ea
authored
2 years ago
by
Wouter Deconinck
Browse files
Options
Downloads
Patches
Plain Diff
Use sciglass when not athena
parent
5df51095
No related branches found
No related tags found
1 merge request
!252
Fixes to benchmarks to run with ecce:main
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
benchmarks/imaging_ecal/options/hybrid_cluster.py
+91
-24
91 additions, 24 deletions
benchmarks/imaging_ecal/options/hybrid_cluster.py
with
91 additions
and
24 deletions
benchmarks/imaging_ecal/options/hybrid_cluster.py
+
91
−
24
View file @
aad451ea
...
...
@@ -15,6 +15,9 @@ from Configurables import Jug__Reco__ImagingPixelReco as ImagingPixelReco
from
Configurables
import
Jug__Reco__ImagingTopoCluster
as
ImagingTopoCluster
from
Configurables
import
Jug__Reco__ImagingClusterReco
as
ImagingClusterReco
detector_name
=
str
(
os
.
environ
.
get
(
"
JUGGLER_DETECTOR
"
,
"
athena
"
))
detector_version
=
str
(
os
.
environ
.
get
(
"
JUGGLER_DETECTOR_VERSION
"
,
"
master
"
))
detector_path
=
str
(
os
.
environ
.
get
(
"
DETECTOR_PATH
"
,
"
.
"
))
# input arguments from calibration file
...
...
@@ -49,27 +52,41 @@ sim_colls = [
'
MCParticles
'
,
'
EcalBarrelHits
'
,
'
EcalBarrelHitsContributions
'
,
]
ecal_barrel_scfi_collections
=
[
'
EcalBarrelScFiHits
'
,
'
EcalBarrelScFiHitsContributions
'
,
'
EcalBarrelScFiHitsContributions
'
]
if
'
athena
'
in
detector_name
:
sim_colls
+=
ecal_barrel_scfi_collections
# list of algorithms
algorithms
=
[]
podin
=
PodioInput
(
'
PodioReader
'
,
collections
=
sim_colls
,
OutputLevel
=
DEBUG
)
podout
=
PodioOutput
(
'
podout
'
,
filename
=
kwargs
[
'
output
'
])
algorithms
.
append
(
podin
)
# use the same daq_setting for digi/reco pair
imcaldaq
=
dict
(
# Central Barrel Ecal
if
'
athena
'
in
detector_name
:
# Central ECAL Imaging Calorimeter
# use the same daq_setting for digi/reco pair
imcaldaq
=
dict
(
dynamicRangeADC
=
3
*
MeV
,
capacityADC
=
32767
,
pedestalMean
=
400
,
pedestalSigma
=
50
)
# 50/32767*3 MeV ~ 5 keV
imcaldigi
=
CalHitDigi
(
'
imcal_digi
'
,
imcaldigi
=
CalHitDigi
(
'
imcal_digi
'
,
OutputLevel
=
DEBUG
,
inputHitCollection
=
'
EcalBarrelHits
'
,
outputHitCollection
=
'
DigiEcalBarrelImagingHits
'
,
energyResolutions
=
[
0.
,
0.02
,
0.
],
**
imcaldaq
)
imcalreco
=
ImagingPixelReco
(
'
imcal_reco
'
,
algorithms
.
append
(
imcaldigi
)
imcalreco
=
ImagingPixelReco
(
'
imcal_reco
'
,
#OutputLevel=DEBUG,
inputHitCollection
=
imcaldigi
.
outputHitCollection
,
outputHitCollection
=
'
RecoEcalBarrelImagingHits
'
,
...
...
@@ -78,8 +95,9 @@ imcalreco = ImagingPixelReco('imcal_reco',
sectorField
=
'
module
'
,
samplingFraction
=
kwargs
[
'
img_sf
'
],
**
imcaldaq
)
algorithms
.
append
(
imcalreco
)
imcalcluster
=
ImagingTopoCluster
(
'
imcal_cluster
'
,
imcalcluster
=
ImagingTopoCluster
(
'
imcal_cluster
'
,
#OutputLevel=DEBUG,
inputHitCollection
=
imcalreco
.
outputHitCollection
,
outputProtoClusterCollection
=
'
EcalBarrelImagingProtoClusters
'
,
...
...
@@ -88,26 +106,30 @@ imcalcluster = ImagingTopoCluster('imcal_cluster',
neighbourLayersRange
=
2
,
minClusterEdep
=
0.5
*
MeV
/
kwargs
[
'
img_sf
'
],
sectorDist
=
3.
*
cm
)
clusterreco
=
ImagingClusterReco
(
'
imcal_clreco
'
,
algorithms
.
append
(
imcalcluster
)
clusterreco
=
ImagingClusterReco
(
'
imcal_clreco
'
,
#OutputLevel=DEBUG,
inputProtoClusters
=
imcalcluster
.
outputProtoClusterCollection
,
outputLayers
=
'
EcalBarrelImagingClustersLayers
'
,
outputClusters
=
'
EcalBarrelImagingClusters
'
,
mcHits
=
"
EcalBarrelHits
"
)
algorithms
.
append
(
clusterreco
)
# scfi layers
scfi_barrel_daq
=
dict
(
# scfi layers
scfi_barrel_daq
=
dict
(
dynamicRangeADC
=
50.
*
MeV
,
capacityADC
=
32768
,
pedestalMean
=
400
,
pedestalSigma
=
10
)
scfi_barrel_digi
=
CalHitDigi
(
"
scfi_barrel_digi
"
,
scfi_barrel_digi
=
CalHitDigi
(
"
scfi_barrel_digi
"
,
inputHitCollection
=
"
EcalBarrelScFiHits
"
,
outputHitCollection
=
"
EcalBarrelScFiHitsDigi
"
,
**
scfi_barrel_daq
)
algorithms
.
append
(
scfi_barrel_digi
)
scfi_barrel_reco
=
CalHitReco
(
"
scfi_barrel_reco
"
,
scfi_barrel_reco
=
CalHitReco
(
"
scfi_barrel_reco
"
,
inputHitCollection
=
scfi_barrel_digi
.
outputHitCollection
,
outputHitCollection
=
"
EcalBarrelScFiHitsReco
"
,
thresholdFactor
=
5.0
,
...
...
@@ -117,17 +139,19 @@ scfi_barrel_reco = CalHitReco("scfi_barrel_reco",
localDetFields
=
[
"
system
"
,
"
module
"
],
# use local coordinates in each module (stave)
samplingFraction
=
kwargs
[
'
scfi_sf
'
],
**
scfi_barrel_daq
)
algorithms
.
append
(
scfi_barrel_reco
)
# merge hits in different layer (projection to local x-y plane)
scfi_barrel_merger
=
CalHitsMerger
(
"
scfi_barrel_merger
"
,
# merge hits in different layer (projection to local x-y plane)
scfi_barrel_merger
=
CalHitsMerger
(
"
scfi_barrel_merger
"
,
#OutputLevel=DEBUG,
inputHitCollection
=
scfi_barrel_reco
.
outputHitCollection
,
outputHitCollection
=
"
EcalBarrelScFiGridReco
"
,
fields
=
[
"
fiber
"
],
fieldRefNumbers
=
[
1
],
readoutClass
=
"
EcalBarrelScFiHits
"
)
algorithms
.
append
(
scfi_barrel_merger
)
scfi_barrel_cl
=
IslandCluster
(
"
scfi_barrel_cl
"
,
scfi_barrel_cl
=
IslandCluster
(
"
scfi_barrel_cl
"
,
#OutputLevel=DEBUG,
inputHitCollection
=
scfi_barrel_merger
.
outputHitCollection
,
outputProtoClusterCollection
=
"
EcalBarrelScFiProtoClusters
"
,
...
...
@@ -135,14 +159,59 @@ scfi_barrel_cl = IslandCluster("scfi_barrel_cl",
minClusterCenterEdep
=
10.
*
MeV
,
localDistXZ
=
[
30
*
mm
,
30
*
mm
],
sectorDist
=
5.
*
cm
)
algorithms
.
append
(
scfi_barrel_cl
)
scfi_barrel_clreco
=
RecoCoG
(
"
scfi_barrel_clreco
"
,
inputProtoClusterCollection
=
scfi_barrel_cl
.
outputProtoClusterCollection
,
outputClusterCollection
=
"
EcalBarrelScFiClusters
"
,
logWeightBase
=
6.2
)
algorithms
.
append
(
scfi_barrel_clreco
)
else
:
# SciGlass calorimeter
sciglass_ecal_daq
=
dict
(
dynamicRangeADC
=
5.
*
GeV
,
capacityADC
=
32768
,
pedestalMean
=
400
,
pedestalSigma
=
3
)
sciglass_ecal_digi
=
CalHitDigi
(
"
sciglass_ecal_digi
"
,
inputHitCollection
=
"
EcalBarrelHits
"
,
outputHitCollection
=
"
EcalBarrelHitsDigi
"
,
energyResolutions
=
[
0.
,
0.02
,
0.
],
# 2% flat resolution
**
sciglass_ecal_daq
)
algorithms
.
append
(
sciglass_ecal_digi
)
sciglass_ecal_reco
=
CalHitReco
(
"
sciglass_ecal_reco
"
,
inputHitCollection
=
sciglass_ecal_digi
.
outputHitCollection
,
outputHitCollection
=
"
EcalBarrelHitsReco
"
,
thresholdFactor
=
3
,
# about 20 keV
readoutClass
=
"
EcalBarrelHits
"
,
# readout class
sectorField
=
"
sector
"
,
# field to get sector id
samplingFraction
=
0.998
,
# this accounts for a small fraction of leakage
**
sciglass_ecal_daq
)
algorithms
.
append
(
sciglass_ecal_reco
)
sciglass_ecal_cl
=
IslandCluster
(
"
sciglass_ecal_cl
"
,
inputHitCollection
=
sciglass_ecal_reco
.
outputHitCollection
,
outputProtoClusterCollection
=
"
EcalBarrelProtoClusters
"
,
splitCluster
=
False
,
minClusterHitEdep
=
1.0
*
MeV
,
# discard low energy hits
minClusterCenterEdep
=
30
*
MeV
,
sectorDist
=
5.0
*
cm
)
algorithms
.
append
(
sciglass_ecal_cl
)
sciglass_ecal_clreco
=
ImagingClusterReco
(
"
sciglass_ecal_clreco
"
,
inputProtoClusters
=
sciglass_ecal_cl
.
outputProtoClusterCollection
,
mcHits
=
"
EcalBarrelHits
"
,
outputClusters
=
"
EcalBarrelClusters
"
,
outputLayers
=
"
EcalBarrelLayers
"
)
algorithms
.
append
(
sciglass_ecal_clreco
)
scfi_barrel_clreco
=
RecoCoG
(
"
scfi_barrel_clreco
"
,
inputProtoClusterCollection
=
scfi_barrel_cl
.
outputProtoClusterCollection
,
outputClusterCollection
=
"
EcalBarrelScFiClusters
"
,
logWeightBase
=
6.2
)
# TODO: merge two types of clusters
podout
=
PodioOutput
(
'
podout
'
,
filename
=
kwargs
[
'
output
'
])
podout
.
outputCommands
=
[
'
drop *
'
,
'
keep MCParticles
'
,
'
keep *Reco*
'
,
...
...
@@ -150,12 +219,10 @@ podout.outputCommands = ['drop *',
'
keep *Cluster*
'
,
'
keep *Layer*
'
,
]
algorithms
.
append
(
podout
)
ApplicationMgr
(
TopAlg
=
[
podin
,
imcaldigi
,
imcalreco
,
imcalcluster
,
clusterreco
,
scfi_barrel_digi
,
scfi_barrel_reco
,
scfi_barrel_merger
,
scfi_barrel_cl
,
scfi_barrel_clreco
,
podout
],
TopAlg
=
algorithms
,
EvtSel
=
'
NONE
'
,
EvtMax
=
kwargs
[
'
nev
'
],
ExtSvc
=
[
podioevent
],
...
...
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