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
267f4eec
Commit
267f4eec
authored
3 years ago
by
Jihee Kim
Browse files
Options
Downloads
Patches
Plain Diff
fixed warning message and reading mcparticles info
parent
58e6dda3
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
benchmarks/imaging_ecal/scripts/draw_cluster.py
+6
-2
6 additions, 2 deletions
benchmarks/imaging_ecal/scripts/draw_cluster.py
benchmarks/imaging_ecal/scripts/utils.py
+1
-1
1 addition, 1 deletion
benchmarks/imaging_ecal/scripts/utils.py
with
7 additions
and
3 deletions
benchmarks/imaging_ecal/scripts/draw_cluster.py
+
6
−
2
View file @
267f4eec
...
...
@@ -5,6 +5,10 @@
Author: Chao Peng (ANL)
Date: 04/30/2021
Added true decaying particles on eta-phi plane projection plot
Author: Jihee Kim (ANL)
Data: 08/06/2021
'''
import
os
...
...
@@ -144,10 +148,10 @@ if __name__ == '__main__':
df
[
'
eta
'
]
=
-
np
.
log
(
np
.
tan
(
df
[
'
theta
'
].
values
/
1000.
/
2.
))
# Read all mc particles
########################
dfallmcp
=
get_all_mcp
(
args
.
file
,
args
.
iev
,
'
mcparticles2
'
)
# Select decaying particles
dfdecaymcp
=
dfallmcp
[
dfallmcp
[
'
g4Parent
'
]
==
1.0
]
dftemp
=
dfallmcp
[
dfallmcp
[
'
g4Parent
'
]
==
1.0
]
dfdecaymcp
=
dftemp
.
copy
()
pdgbase
=
ROOT
.
TDatabasePDG
()
for
iptl
in
[
0
,
len
(
dfdecaymcp
)
-
1
]:
infoptl
=
pdgbase
.
GetParticle
(
int
(
dfdecaymcp
[
'
pid
'
].
iloc
[
iptl
]))
...
...
This diff is collapsed.
Click to expand it.
benchmarks/imaging_ecal/scripts/utils.py
+
1
−
1
View file @
267f4eec
...
...
@@ -104,7 +104,7 @@ def get_all_mcp(path, evnums=None, branch='mcparticles2'):
events
.
GetEntry
(
iev
)
# extract mc particle data
for
ptl
in
getattr
(
events
,
branch
):
dbuf
[
idb
]
=
(
iev
,
ptl
.
psx
,
ptl
.
psy
,
ptl
.
psz
,
ptl
.
pdgID
,
ptl
.
status
,
ptl
.
g4Parent
,
ptl
.
vex
,
ptl
.
vey
,
ptl
.
vez
)
dbuf
[
idb
]
=
(
iev
,
ptl
.
ps
.
x
,
ptl
.
ps
.
y
,
ptl
.
ps
.
z
,
ptl
.
pdgID
,
ptl
.
status
,
ptl
.
g4Parent
,
ptl
.
ve
.
x
,
ptl
.
ve
.
y
,
ptl
.
ve
.
z
)
idb
+=
1
return
pd
.
DataFrame
(
data
=
dbuf
[:
idb
],
columns
=
[
'
event
'
,
'
px
'
,
'
py
'
,
'
pz
'
,
'
pid
'
,
'
status
'
,
'
g4Parent
'
,
'
vex
'
,
'
vey
'
,
'
vez
'
])
...
...
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