Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
On Thursday, 7th July from 1 to 3 pm there will be a maintenance with a short downtime of GitLab.
Open sidebar
Ievgen Vovk
ctapipe_io_magic
Commits
ebadbcd1
Commit
ebadbcd1
authored
Jan 29, 2020
by
Ievgen Vovk
Browse files
Handling of empty event lists in MarsRun._find_mono_events() .
parent
fe5c9c78
Pipeline
#68143
failed with stage
in 9 minutes and 14 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
ctapipe_io_magic/__init__.py
View file @
ebadbcd1
...
...
@@ -1071,10 +1071,12 @@ class MarsRun:
# shortcut if only single file is loaded:
if
n_m1_events
==
0
:
mono_ids
[
'M2'
]
=
np
.
arange
(
0
,
n_m2_events
)[
m2_data_condition
]
if
n_m2_events
>
0
:
mono_ids
[
'M2'
]
=
np
.
arange
(
0
,
n_m2_events
)[
m2_data_condition
]
return
mono_ids
if
n_m2_events
==
0
:
mono_ids
[
'M1'
]
=
np
.
arange
(
0
,
n_m1_events
)[
m1_data_condition
]
if
n_m1_events
>
0
:
mono_ids
[
'M1'
]
=
np
.
arange
(
0
,
n_m1_events
)[
m1_data_condition
]
return
mono_ids
for
m1_id
in
range
(
0
,
n_m1_events
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment