Skip to content
Snippets Groups Projects

Reordering to get rid of empty waveform containers

Merged Noshin Tarannum requested to merge (removed):master into master
2 files
+ 8
12
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -42,12 +42,6 @@ PseudoCaloHitToWaveformRecAlg::execute(const EventContext& ctx) const {
@@ -42,12 +42,6 @@ PseudoCaloHitToWaveformRecAlg::execute(const EventContext& ctx) const {
ATH_CHECK( caloHitHandle.isValid() );
ATH_CHECK( caloHitHandle.isValid() );
ATH_MSG_DEBUG("Found ReadHandle for CaloHitCollection " << m_caloHitContainerKey);
ATH_MSG_DEBUG("Found ReadHandle for CaloHitCollection " << m_caloHitContainerKey);
if (caloHitHandle->size() == 0) {
ATH_MSG_DEBUG("CaloHitCollection found with zero length!");
return StatusCode::SUCCESS;
}
// Find the output waveform container
// Find the output waveform container
SG::WriteHandle<xAOD::WaveformHitContainer> waveformHitContainerHandle(m_waveformHitContainerKey, ctx);
SG::WriteHandle<xAOD::WaveformHitContainer> waveformHitContainerHandle(m_waveformHitContainerKey, ctx);
ATH_CHECK( waveformHitContainerHandle.record( std::make_unique<xAOD::WaveformHitContainer>(),
ATH_CHECK( waveformHitContainerHandle.record( std::make_unique<xAOD::WaveformHitContainer>(),
@@ -55,6 +49,10 @@ PseudoCaloHitToWaveformRecAlg::execute(const EventContext& ctx) const {
@@ -55,6 +49,10 @@ PseudoCaloHitToWaveformRecAlg::execute(const EventContext& ctx) const {
ATH_MSG_DEBUG("WaveformsHitContainer '" << waveformHitContainerHandle.name() << "' initialized");
ATH_MSG_DEBUG("WaveformsHitContainer '" << waveformHitContainerHandle.name() << "' initialized");
 
if (caloHitHandle->size() == 0) {
 
ATH_MSG_DEBUG("CaloHitCollection found with zero length!");
 
return StatusCode::SUCCESS;
 
}
// "Reconstruct" the hits
// "Reconstruct" the hits
CHECK( m_recoTool->reconstruct<CaloHitCollection>(caloHitHandle.ptr(),
CHECK( m_recoTool->reconstruct<CaloHitCollection>(caloHitHandle.ptr(),
Loading