Belle II Software light-2609-luna
_SetDstarVetoDefaults Class Reference
Inheritance diagram for _SetDstarVetoDefaults:
Collaboration diagram for _SetDstarVetoDefaults:

Public Member Functions

 __init__ (self, particle_lists, keys)
 
 event (self)
 

Protected Attributes

 _particle_lists = particle_lists
 Particle list names to iterate over.
 
 _keys = keys
 ExtraInfo key names to set to NaN if missing.
 

Detailed Description

Set missing D* veto ExtraInfo keys to NaN on all B candidates.

This ensures every B candidate has Dstp_deltaMassDiff and Dst0_deltaMassDiff
set (even when the corresponding D* type is not its first daughter and no veto
candidate is reconstructed).

Definition at line 31 of file dstarVeto.py.

Constructor & Destructor Documentation

◆ __init__()

__init__ ( self,
particle_lists,
keys )
Set up with lists of particle list names and ExtraInfo key names.

Definition at line 39 of file dstarVeto.py.

39 def __init__(self, particle_lists, keys):
40 """Set up with lists of particle list names and ExtraInfo key names."""
41 super().__init__()
42
43 self._particle_lists = particle_lists
44
45 self._keys = keys
46

Member Function Documentation

◆ event()

event ( self)
Set missing ExtraInfo keys to NaN for every candidate in each list.

Definition at line 47 of file dstarVeto.py.

47 def event(self):
48 """Set missing ExtraInfo keys to NaN for every candidate in each list."""
49 for list_name in self._particle_lists:
50 plist = Belle2.PyStoreObj(list_name)
51 if not plist.isValid():
52 continue
53 for i in range(plist.obj().getListSize()):
54 p = plist.obj().getParticle(i)
55 for key in self._keys:
56 if not p.hasExtraInfo(key):
57 p.addExtraInfo(key, math.nan)
58
59
a (simplified) python wrapper for StoreObjPtr.
Definition PyStoreObj.h:67

Member Data Documentation

◆ _keys

_keys = keys
protected

ExtraInfo key names to set to NaN if missing.

Definition at line 45 of file dstarVeto.py.

◆ _particle_lists

_particle_lists = particle_lists
protected

Particle list names to iterate over.

Definition at line 43 of file dstarVeto.py.


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