Skip to content
Snippets Groups Projects
Commit b083b422 authored by Christopher Rob Jones's avatar Christopher Rob Jones
Browse files

Minor cleanup to RichMCSIMDPhotonCherenkovAngles

parent ab025078
No related branches found
No related tags found
1 merge request!2502Add MC Rich Optical Photon Checker
......@@ -28,6 +28,7 @@
#include "GaudiAlg/Consumer.h"
// Event Model
#include "Event/MCRichDigitSummary.h"
#include "RichFutureRecEvent/RichRecCherenkovAngles.h"
#include "RichFutureRecEvent/RichRecCherenkovPhotons.h"
#include "RichFutureRecEvent/RichRecPhotonPredictedPixelSignals.h"
......@@ -40,9 +41,6 @@
#include "RichUtils/RichTrackSegment.h"
#include "RichUtils/ZipRange.h"
// Event model
#include "Event/MCRichDigitSummary.h"
// Relations
#include "RichFutureMCUtils/RichRecMCHelper.h"
......@@ -304,7 +302,7 @@ void SIMDPhotonCherenkovAngles::operator()( const Summary::Track::Vector&
const LHCb::MCRichDigitSummarys& digitSums ) const {
// Make a local MC helper object
Helper mcHelper( tkrels, digitSums );
const Helper mcHelper( tkrels, digitSums );
// the lock
std::lock_guard lock( m_updateLock );
......@@ -323,6 +321,9 @@ void SIMDPhotonCherenkovAngles::operator()( const Summary::Track::Vector&
// loop over the photon info
for ( const auto&& [sumTk, tk] : Ranges::ConstZip( sumTracks, tracks ) ) {
// Get the MCParticles for this track
const auto mcPs = mcHelper.mcParticles( *tk, true, 0.5 );
// loop over photons for this track
for ( const auto photIn : sumTk.photonIndices() ) {
......@@ -346,9 +347,6 @@ void SIMDPhotonCherenkovAngles::operator()( const Summary::Track::Vector&
// Segment momentum
const auto pTot = seg.bestMomentumMag();
// Get the MCParticles for this track
const auto mcPs = mcHelper.mcParticles( *tk, true, 0.5 );
// Weight per MCP
const auto mcPW = ( !mcPs.empty() ? 1.0 / (double)mcPs.size() : 1.0 );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment