short test module to demonstrate the readout of the CDC trigger
Definition at line 98 of file trgcdcReadout.py.
◆ event()
print output values of the different stages in the CDC trigger
Definition at line 103 of file trgcdcReadout.py.
105 print output values of the different stages in the CDC trigger
107 print(
"CDC trigger readout")
113 listnames = [
"2D finder",
"2D fitter",
"3D fitter",
"Neurotrigger"]
114 for i, tracks
in enumerate([tracks2Dfinder, tracks2Dfitter,
115 tracks3Dfitter, tracks3Dneuro]):
116 print(listnames[i],
"has", len(tracks),
"tracks.")
118 print(
"phi0[deg] = %.2f" % (track.getPhi0() * 180. / np.pi),
119 "pt[GeV] = %.3f" % track.getTransverseMomentum(1.5),
120 "charge = %d" % track.getChargeSign(),
121 "theta[deg] = %.2f" % (np.arctan2(1., track.getCotTheta()) * 180. / np.pi),
122 "z[cm] = %.2f" % track.getZ0())
125 print(
"phi0[deg] = %.2f" % (particle.getMomentum().Phi() * 180. / np.pi),
126 "pt[GeV] = %.3f" % particle.getMomentum().Pt(),
127 "charge = %d" % particle.getCharge(),
128 "theta[deg] = %.2f" % (particle.getMomentum().Theta() * 180. / np.pi),
129 "z[cm] = %.2f" % particle.getProductionVertex().Z())
132 main.add_module(TestModule())
138 print(basf2.statistics)
A (simplified) python wrapper for StoreArray.
a (simplified) python wrapper for StoreObjPtr.
The documentation for this class was generated from the following file: