Linear Collider Forum

Home » Analysis and Reconstruction » Reconstruction » MC association
Re: MC association [message #476 is a reply to message #475] Fri, 19 May 2006 06:16 Go to previous messageGo to previous message
Messages: 47
Registered: May 2004
Location: DeKalb, IL, USA
Hi Fabio,

At this point it is unlikely that you are using DigiSim upstream of your analysis code. Without DigiSim, there are no RawCalHits. If this is the case, all you need to do is to cast the CalorimeterHit* to a SimCalorimeterHit* and take it from there:

// loop over all Reco Cluster Hits
for( std::vector<CalorimeterHit*>::const_iterator ch = RecoCaloHits.begin(); ch != RecoCaloHits.end(); ch++){
// LCObject* CSimhit = (*ch)->getRawHit();
SimCalorimeterHit* simHit = dynamic_cast<SimCalorimeterHit*>(*ch) ;
int nMCcont = simHit->getNMCParticles();
//... and so on...

Please let us know if this does not work.

Good luck,
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic:Problem with Marlin 0.9.4
Next Topic:org.lcsim Tracking Examples
Goto Forum:

Current Time: Sun Dec 15 00:02:58 Pacific Standard Time 2019
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.1.
Copyright ©2001-2010 FUDforum Bulletin Board Software