Belle II Software development
ReassignedSecondaryMap Class Reference
Inheritance diagram for ReassignedSecondaryMap:
CDCHitColorMap

Public Member Functions

def __call__ (self, iCDCHit, cdcHit)
 

Detailed Description

CDCHit to color map indicating the reassignment to a different MCParticle.

Definition at line 398 of file attributemaps.py.

Member Function Documentation

◆ __call__()

def __call__ (   self,
  iCDCHit,
  cdcHit 
)
Function call to map the CDCHit id and object to a color.

Reimplemented from CDCHitColorMap.

Definition at line 404 of file attributemaps.py.

404 def __call__(self, iCDCHit, cdcHit):
405 """
406 Function call to map the CDCHit id and object to a color.
407 """
408
409 relatedMCParticles = cdcHit.getRelationsWith('MCParticles')
410 if relatedMCParticles.size() == 0:
411 return self.bkgHitColor
412 else:
413 mcRelationWeight = relatedMCParticles.weight(0)
414 if mcRelationWeight > 0:
415 return 'green'
416 else:
417 return 'red'
418
419

The documentation for this class was generated from the following file: