Skip to content
Snippets Groups Projects
Commit 35503c92 authored by Savannah Rose Shively's avatar Savannah Rose Shively
Browse files

sg fix

parent 5629f0b7
No related branches found
No related tags found
No related merge requests found
......@@ -24,11 +24,23 @@ StatusCode SimHitAlg::initialize()
// initialize data handle keys
ATH_CHECK( m_mcEventKey.initialize() );
ATH_CHECK( m_faserSiHitKey.initialize() );
ATH_CHECK( m_scintHitKey.initialize() );
//Sav things
ATH_CHECK( m_preshowerHitKey.initialize() );
ATH_CHECK( m_triggerHitKey.initialize() );
ATH_CHECK( m_vetoHitKey.initialize() );
ATH_MSG_INFO( "Using GenEvent collection with key " << m_mcEventKey.key());
ATH_MSG_INFO( "Using Faser SiHit collection with key " << m_faserSiHitKey.key());
ATH_MSG_INFO( "Using ScintHit collection with key " << m_scintHitKey.key());
ATH_MSG_INFO( "Using ScintHit collection with key " << m_preshowerHitKey.key());
ATH_MSG_INFO( "Using ScintHit collection with key " << m_triggerHitKey.key());
ATH_MSG_INFO( "Using ScintHit collection with key " << m_vetoHitKey.key());
return StatusCode::SUCCESS;
}
StatusCode SimHitAlg::execute()
......@@ -41,8 +53,13 @@ StatusCode SimHitAlg::execute()
SG::ReadHandle<FaserSiHitCollection> h_siHits(m_faserSiHitKey);
ATH_MSG_INFO("Read FaserSiHitCollection with " << h_siHits->size() << " hits");
SG::ReadHandle<ScintHitCollection> h_scintHits(m_scintHitKey);
ATH_MSG_INFO("Read ScintHitCollection with " << h_scintHits->size() << " hits");
SG::ReadHandle<ScintHitCollection> h_preshowerHits(m_preshowerHitKey);
ATH_MSG_INFO("Read ScintHitCollection with " << h_preshowerHits->size() << " hits");
SG::ReadHandle<ScintHitCollection> h_triggerHits(m_triggerHitKey);
ATH_MSG_INFO("Read ScintHitCollection with " << h_triggerHits->size() << " hits");
SG::ReadHandle<ScintHitCollection> h_vetoHits(m_vetoHitKey);
ATH_MSG_INFO("Read ScintHitCollection with " << h_vetoHits->size() << " hits");
// Since we have no pile-up, there should always be a single GenEvent in the container
const HepMC::GenEvent* ev = (*h_mcEvents)[0];
......@@ -76,7 +93,7 @@ StatusCode SimHitAlg::execute()
if (h_scintHits->size()!=0){
/*if (h_scintHits->size()!=0){
for (const ScintHit& hit : *h_scintHits)
{
hit.print();
......@@ -89,10 +106,10 @@ StatusCode SimHitAlg::execute()
else
{
m_moduleSide2->Fill( hit.getModule(), hit.getRow());
}*/
}//
}
}
}*/
return StatusCode::SUCCESS;
}
......
......@@ -32,5 +32,10 @@ class SimHitAlg : public AthHistogramAlgorithm
// Note the key names ("GEN_EVENT" or "SCT_Hits") are Gaudi properties and can be configured at run-time
SG::ReadHandleKey<McEventCollection> m_mcEventKey { this, "McEventCollection", "GEN_EVENT" };
SG::ReadHandleKey<FaserSiHitCollection> m_faserSiHitKey { this, "FaserSiHitCollection", "SCT_Hits" };
SG::ReadHandleKey<ScintHitCollection> m_scintHitKey { this, "ScintHitCollection", "Scint_Hits" };
//PreshowerHits, TriggerHits, VetoHits Sav new stuff
SG::ReadHandleKey<ScintHitCollection> m_scintHitKey { this, "ScintHitCollection", "Scint_Hits" }; //template. remove later
SG::ReadHandleKey<ScintHitCollection> m_preshowerHitKey { this, "ScintHitCollection", "PreshowerHits" };
SG::ReadHandleKey<ScintHitCollection> m_triggerHitKey { this, "ScintHitCollection", "TriggerHits" };
SG::ReadHandleKey<ScintHitCollection> m_vetoHitKey { this, "ScintHitCollection", "VetoHits" };
};
\ No newline at end of file
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