The Gaudi Framework  v36r1 (3e2fb5a8)
TupleEx2.TupleEx2 Class Reference
Inheritance diagram for TupleEx2.TupleEx2:
Collaboration diagram for TupleEx2.TupleEx2:

Public Member Functions

def __init__ (self, name='TupleEx2')
 
def execute (self)
 

Detailed Description

Simple algorithm for advanced N-Tuple columns

Definition at line 51 of file TupleEx2.py.

Constructor & Destructor Documentation

◆ __init__()

def TupleEx2.TupleEx2.__init__ (   self,
  name = 'TupleEx2' 
)
Constructor 

Definition at line 57 of file TupleEx2.py.

57  def __init__(self, name='TupleEx2'):
58  """ Constructor """
59  TupleAlgo.__init__(self, name)
60 

Member Function Documentation

◆ execute()

def TupleEx2.TupleEx2.execute (   self)
The major method 'execute', it is invoked for each event 

Definition at line 62 of file TupleEx2.py.

62  def execute(self):
63  """ The major method 'execute', it is invoked for each event """
64 
65  gauss = Rndm.Numbers(self.randSvc(), Rndm.Gauss(0.0, 1.0))
66  flat = Rndm.Numbers(self.randSvc(), Rndm.Flat(-10, 10))
67  breit = Rndm.Numbers(self.randSvc(), Rndm.BreitWigner(0.0, 1.0))
68 
69  # N-tuple with 4D-vectors
70  tup = self.nTuple('Vectors-4D', 'N-tuple with 4D-vectors')
71  for i in range(0, 100):
72 
73  lv1 = Math.PxPyPzEVector()
74 
75  lv1.SetPx(gauss())
76  lv1.SetPy(gauss())
77  lv1.SetPz(gauss())
78  lv1.SetE(gauss())
79 
80  tup.column('lv1', lv1)
81 
82  tup.write()
83 
84  # N-tuple with 3D-vectors
85  tup = self.nTuple('Vectors-3D', 'N-tuple with 3D-vectors')
86  for i in range(0, 100):
87 
88  v1 = Math.XYZVector()
89  v1.SetX(gauss())
90  v1.SetY(gauss())
91  v1.SetZ(gauss())
92 
93  tup.column("v1", v1)
94 
95  tup.write()
96 
97  # N-tuple with 3D-points
98  tup = self.nTuple('Points-3D', 'N-tuple with 3D-points')
99  for i in range(0, 100):
100 
101  p1 = Math.XYZPoint()
102  p1.SetX(gauss())
103  p1.SetY(gauss())
104  p1.SetZ(gauss())
105 
106  tup.column("p1", p1)
107 
108  tup.write()
109 
110  return SUCCESS
111 
112 
113 # =============================================================================
114 # job configuration
115 #
116 # @author Vanya BELYAEV ibelyaev@physics.syr.edu
117 # @date 2006-11-26
118 
119 

The documentation for this class was generated from the following file:
Rndm::Flat
Parameters for the flat random number generation within boundaries [minimum, maximum].
Definition: RndmGenerators.h:253
Rndm::Gauss
Parameters for the Gauss random number generation.
Definition: RndmGenerators.h:32
Rndm::Numbers
Random number accessor This small class encapsulates the use of the random number generator.
Definition: RndmGenerators.h:359
GaudiPython.Pythonizations.execute
execute
Definition: Pythonizations.py:566
Rndm::BreitWigner
Parameters for the BreitWigner distributed random number generation.
Definition: RndmGenerators.h:94
HistoUtilsEx.gauss
gauss
Definition: HistoUtilsEx.py:66
Gaudi::Functional::details::zip::range
decltype(auto) range(Args &&... args)
Zips multiple containers together to form a single range.
Definition: FunctionalDetails.h:97