Skip to content

Commit

Permalink
fix: Root simhit reader event range (#2430)
Browse files Browse the repository at this point in the history
I think in my last refactor of this, I introduced a bug, the reader reported the wrong event range. This fixes it.
  • Loading branch information
benjaminhuth committed Sep 6, 2023
1 parent acc222e commit e1fbe73
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Examples/Io/Root/src/RootSimHitReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,13 @@ ActsExamples::RootSimHitReader::RootSimHitReader(

// Re-Enable all branches
m_inputChain->SetBranchStatus("*", true);
ACTS_DEBUG("Event range: " << availableEvents().first << " - "
<< availableEvents().second);
}

std::pair<size_t, size_t> ActsExamples::RootSimHitReader::availableEvents()
const {
return {std::get<0>(m_eventMap.front()), std::get<0>(m_eventMap.back())};
return {std::get<0>(m_eventMap.front()), std::get<0>(m_eventMap.back()) + 1};
}

ActsExamples::ProcessCode ActsExamples::RootSimHitReader::read(
Expand Down

0 comments on commit e1fbe73

Please sign in to comment.