Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
OrcaSong
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
Machine Learning
OrcaSong
Commits
392a0f50
Commit
392a0f50
authored
3 years ago
by
Daniel Guderian
Browse files
Options
Downloads
Patches
Plain Diff
just started working...
parent
28b5f26f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!19
Resolve "error when using new extractor"
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
orcasong/extractors.py
+21
-1
21 additions, 1 deletion
orcasong/extractors.py
with
21 additions
and
1 deletion
orcasong/extractors.py
+
21
−
1
View file @
392a0f50
...
...
@@ -193,6 +193,23 @@ def get_random_noise_mc_info_extr(input_file):
return
mc_info_extr
def
get_rec_types_in_file
(
file
):
"""
Checks rand returns which rec types are in the file and thus need to be present
in all best track and their fitinf information.
"""
#the known rec types
rec_type_names
=
[
"
best_jmuon
"
,
"
best_jshower
"
,
"
best_dusjshower
"
,
"
best_aashower
"
]
#all reco related in the file
reco_objects_in_file
=
file
[
"
reco
"
].
keys
()
#
rec_types_in_file
=
2
return
rec_types_in_file
def
get_neutrino_mc_info_extr
(
input_file
):
"""
...
...
@@ -215,7 +232,10 @@ def get_neutrino_mc_info_extr(input_file):
# check if std reco is present
f
=
File
(
input_file
,
"
r
"
)
has_std_reco
=
"
reco
"
in
f
.
keys
()
#also check, which rec types are present
#rec_types = get_rec_types_in_file(f)
# get the n_gen
header
=
HDF5Header
.
from_hdf5
(
input_file
)
n_gen
=
header
.
genvol
.
numberOfEvents
...
...
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