Belle II Software  release-05-01-25
Belle2::PXD Namespace Reference

Namespace to encapsulate code needed for simulation and reconstrucion of the PXD. More...

Classes

class  ActivatePXDClusterPositionEstimatorModule
 The ActivatePXDClusterPositionEstimator module. More...
 
class  ActivatePXDGainCalibratorModule
 The ActivatePXDGainCalibrator module. More...
 
class  ActivatePXDPixelMaskerModule
 The ActivatePXDPixelMasker module. More...
 
struct  Cluster_t
 Struct to hold variables for PXD clusters. More...
 
class  ClusterCache
 Class to remember recently assigned clusters This class will remember the current and the last pixel row to allow fast finding of the correct cluster a pixel belongs to. More...
 
class  ClusterCandidate
 Class representing a possible cluster during clustering of the PXD It supports merging of different clusters and keeps track of the highest charge inside the cluster. More...
 
class  ClusterProjection
 Helper struct to collect information about the 1D projection of a Pixel cluster. More...
 
struct  dhc_commode_frame
 DHH common mode frame data struct. More...
 
struct  dhc_dhe_end_frame
 DHE End frame data struct. More...
 
struct  dhc_dhe_start_frame
 DHH start frame data struct. More...
 
struct  dhc_direct_readout_frame
 DHC direct readout frame data struct. More...
 
struct  dhc_direct_readout_frame_raw
 DHC RAW direct readout frame data struct. More...
 
struct  dhc_direct_readout_frame_zsd
 DHC Zero supressed direct readout frame data struct. More...
 
struct  dhc_end_frame
 DHC End frame data struct. More...
 
struct  dhc_frame_header_word0
 DHC frame header word data struct. More...
 
class  dhc_frames
 DHC frame wrapper class. More...
 
struct  dhc_ghost_frame
 DHC Ghost frame data struct. More...
 
struct  dhc_onsen_roi_frame
 ONSEN (debug) ROI frame data struct. More...
 
struct  dhc_onsen_trigger_frame
 ONSEN Trigger frame data struct. More...
 
struct  dhc_start_frame
 DHC start frame data struct. More...
 
class  Digit
 Class to represent the coordinates of one pixel. More...
 
class  DigitValue
 Class representing the charge and particle contributions for one pixel. More...
 
class  GeoPXDCreator
 The creator for the PXD geometry of the Belle II detector. More...
 
class  NoiseMap
 Base Class to represent pixel dependent Noise Map. More...
 
class  Pixel
 Class to represent one pixel, used in clustering for fast access. More...
 
class  PXDBackgroundModule
 PXD Background module. More...
 
class  PXDBadSensorTagModule
 The PXD bad sensor tagger module. More...
 
class  PXDBeamBackHitFilterModule
 The PXDBeamBackHitFilter module. More...
 
class  PXDBgTupleProducerModule
 PXD Background Tuple Producer. More...
 
class  PXDClusterCheckModule
 The PXDClusterCheck module. More...
 
class  PXDClusterizerModule
 The PXDClusterizer module. More...
 
class  PXDClusterPositionEstimator
 Singleton class that estimates cluster positions taking into account the estimated track incidence angles into the sensor. More...
 
class  PXDClusterShape
 Class to correct estimation of cluster error and position base on its shape. More...
 
class  PXDDAQDQMModule
 The PXD DAQ DQM module. More...
 
class  PXDDigitizerModule
 The PXD Digitizer module. More...
 
class  PXDDigitSorterModule
 The PXDDigitSorter module. More...
 
class  PXDEventPlotModule
 Plot each event with ROI and Pixels. More...
 
class  PXDGainCalibrator
 Singleton class for managing gain corrections for the PXD. More...
 
class  PXDGatedDHCDQMModule
 The PXD Gatint after Injection DQM module. More...
 
class  PXDGatedInfoFillerModule
 PXD Gates Mode infromation on readout gate basis. More...
 
class  PXDGatedModeDQMModule
 The PXD for GatedMode DQM module. More...
 
class  PXDInjectionDQMModule
 The PXD Occupancy after Injection DQM module. More...
 
class  PXDMappingLookup
 Class to make the mapping between u/v cell ID of pixels back to DCD drain lines, pixel row/col, DCD and Switcher IDs Details: Belle Note: BELLE2-NOTE-TE-2015-01 "The vertex detector numbering scheme" https://docs.belle2.org/record/243/files/Belle%20II%20note%200010.pdf PXD WhiteBook 3.1.3 Sensor Design and Appendix #3 https://confluence.desy.de/display/BI/PXD+WebHome?preview=/34029260/56330158/PXDwb.pdf. More...
 
class  PXDMCBgTupleProducerModule
 PXD MC Background Tuple Producer. More...
 
class  PXDPackerErrModule
 The PXDPackerErr module. More...
 
class  PXDPackerModule
 The PXDPacker module. More...
 
class  PXDPixelMasker
 Singleton class for managing pixel masking for the PXD. More...
 
class  PXDPostErrorCheckerModule
 The PXD DAQ Post Unpacking Error Check. More...
 
class  PXDRawDQMChipsModule
 The raw PXD DQM module. More...
 
class  PXDRawDQMModule
 The raw PXD DQM module. More...
 
class  PXDRawDumperModule
 Dump Raw PXD/ ONSEN event data. More...
 
class  PXDRawHitMaskingModule
 The PXDRawHitMasking module. More...
 
class  PXDRawHitSorterModule
 The PXDRawHitSorter module. More...
 
class  PXDReadRawBonnDAQMatchedModule
 Module to Load BonnDAQ file and store it as RawPXD in Data Store This is meant for lab use (standalone testing, debugging) without an event builder. More...
 
class  PXDReadRawBonnDAQModule
 Module to Load Raw PXD Data from DHH network-dump file and store it as RawPXD in Data Store This is meant for lab use (standalone testing, debugging) without an event builder. More...
 
class  PXDReadRawONSENModule
 A class definition of an input module for Sequential ROOT I/O. More...
 
class  PXDROIDQMModule
 The raw PXD DQM module. More...
 
class  PXDROIPlotModule
 Plot each event with ROI and Pixels. More...
 
class  PXDUnpackerModule
 The PXDUnpacker module. More...
 
class  PXDUnpackerOTModule
 The PXDUnpackerOT module. More...
 
class  SensorInfo
 Specific implementation of SensorInfo for PXD Sensors which provides additional pixel specific information. More...
 
struct  TrackBase_t
 Struct to hold variables from a track which contains a vector of data type like TrackCluster. More...
 
struct  TrackCluster_t
 
struct  TrackPoint_t
 Struct to hold variables for intersection points. More...
 

Typedefs

typedef std::map< Digit, DigitValueSensor
 Map of all hits in one Sensor.
 
typedef std::map< VxdID, SensorSensors
 Map of all hits in all Sensors.
 
typedef std::map< pxdClusterShapeType, std::string > pxdClusterShapeDescr
 Type specifies cluster shape type description.
 
typedef VXD::SensitiveDetector< PXDSimHit, PXDTrueHitSensitiveDetector
 The PXD Sensitive Detector class.
 
typedef boost::crc_optimal< 32, 0x04C11DB7, 0, 0, false, false > dhc_crc_32_type
 define our CRC function
 
typedef TrackBase_t< TrackCluster_tTrack_t
 
typedef genfit::MeasuredStateOnPlane TrackState
 Helper function to get a track state on a module. More...
 

Enumerations

enum  pxdClusterShapeType {
  no_shape_set = 0,
  shape_1,
  shape_2_u,
  shape_2_v,
  shape_2_uv_diag,
  shape_2_uv_antidiag,
  shape_N1,
  shape_1M,
  shape_N2,
  shape_2M,
  shape_4,
  shape_3_L,
  shape_3_L_mirr_u,
  shape_3_L_mirr_v,
  shape_3_L_mirr_uv,
  shape_large
}
 Type specifies cluster shape type.
 
enum  EDHPFrameHeaderDataType {
  c_RAW = 0x0,
  c_ZSD = 0x5
}
 Enums for DHP data modes in the DHP header. More...
 
enum  EDHCFrameHeaderDataType {
  c_DHP_RAW = 0x0,
  c_DHP_ZSD = 0x5,
  c_FCE_RAW = 0x1,
  c_COMMODE = 0x6,
  c_GHOST = 0x2,
  c_DHE_START = 0x3,
  c_DHE_END = 0x4,
  c_DHC_START = 0xB,
  c_DHC_END = 0xC,
  c_ONSEN_DHP = 0xD,
  c_ONSEN_FCE = 0x9,
  c_ONSEN_ROI = 0xF,
  c_ONSEN_TRG = 0xE,
  c_UNUSED_7 = 0x7,
  c_UNUSED_8 = 0x8,
  c_UNUSED_A = 0xA
}
 Enums for DHC data frame types. More...
 
enum  EDHEStateMachineError {
  c_DHESM_NO_ERROR = 0x0,
  c_DHESM_MISS_DHP_FRM = 0x1,
  c_DHESM_TIMEOUT = 0x2,
  c_DHESM_DHP_LINKDOWN = 0x3,
  c_DHESM_DHP_MASKED = 0x4,
  c_DHESM_EVTNR_MM = 0x5,
  c_DHESM_DHP_SIZE_OVERFLOW = 0x6
}
 Enums for DHE DHP StateMachine Error States. More...
 

Functions

void getNumberOfBins (const std::shared_ptr< TH1I > &histo_ptr, unsigned short &nBinsU, unsigned short &nBinsV)
 Helper function to extract number of bins along u side and v side from counter histogram labels.
 
unsigned short getNumberOfSensors (const std::shared_ptr< TH1I > &histo_ptr)
 Helper function to extract number of sensors from counter histogram labels.
 
double CalculateMedian (std::vector< double > &signals)
 Helper function to calculate a median from unsorted signal vector. More...
 
double CalculateMedian (TH1 *hist)
 Helper function to calculate a median from 1D histogram.
 
double FitLandau (TH1 *hist)
 Helper function to estimate MPV from 1D histogram.
 
double FitLandau (std::vector< double > &signals)
 Helper function to calculate MPV from a vector. More...
 
 TEST (ClusterCache, FindNeighbours)
 Check that we cluster to hits next to each other but not if one is in between. More...
 
 TEST (ClusterCache, Merging)
 Test that clusters get merged if they are found to have a common pixel. More...
 
 TEST (ClusterCache, Empty)
 Check if the cluster cache is empty.
 
 TEST (ClusterCache, OutOfRange)
 Check that out_of_range exceptions are raised if the pixel is out of range.
 
double xiBeta2_L (const int Z=Z_Si, const double A=A_Si, const double rho=rho_Si, const int z=1)
 xi = (K/2)*(Z/A)*z*z*(rho*L)/beta2 in MeV More...
 
double hbarWp (const int Z=Z_Si, const double A=A_Si, const double rho=rho_Si)
 hbarWp = sqrt(rho*Z/A)*28.816 in eV More...
 
double getDeltaP (const double mom, const double length, const double mass=Const::electronMass)
 helper function to estimate the most probable energy loss for a given track length. More...
 
unsigned short getPXDModuleID (const VxdID &sensorID)
 Helper function to get DHE id like module id from VxdID.
 
VxdID getVxdIDFromPXDModuleID (const unsigned short &id)
 Helper function to get VxdID from DHE id like module iid.
 
std::shared_ptr< TrackStategetTrackStateOnModule (const VXD::SensorInfoBase &pxdSensorInfo, RecoTrack &recoTrack, double lambda=0.0)
 

Variables

geometry::CreatorFactory< GeoPXDCreatorGeoPXDFactory ("PXDCreator")
 Register the creator.
 
const int Z_Si = 14
 Const and Const expressions Only valid when g_mol is the default unit. More...
 
const double A_Si = 28.085
 Atomic mass of silicon in g mol^-1.
 
const double rho_Si = 2.3290 * Unit::g_cm3
 Silicon density in g cm^-3.
 

Detailed Description

Namespace to encapsulate code needed for simulation and reconstrucion of the PXD.

Typedef Documentation

◆ TrackState

Helper function to get a track state on a module.

Parameters
pxdSensorInfoof the PXD module intersecting with the track.
recoTrackthe recoTrack to be extrapolated.
lambdathe extrapolation length from track POCA.
Returns
the shared pointer of the intersection track state on the module.

Definition at line 108 of file PXDUtilities.h.

Enumeration Type Documentation

◆ EDHCFrameHeaderDataType

Enums for DHC data frame types.

4 bits value; found in the first header word of each frame. See Data format definitions [BELLE2-NOTE-TE-2016-009] on https://docs.belle2.org/

Definition at line 38 of file PXDRawDataDefinitions.h.

58  {
59  c_DHESM_NO_ERROR = 0x0, // no errors

◆ EDHEStateMachineError

Enums for DHE DHP StateMachine Error States.

4 bits value; Currently the same definitions as the ones encoded in ghost frame (new! but 3 bit only) See Data format definitions [BELLE2-NOTE-TE-2016-009] on https://docs.belle2.org/

Definition at line 66 of file PXDRawDataDefinitions.h.

◆ EDHPFrameHeaderDataType

Enums for DHP data modes in the DHP header.

DHP modes have the same value as for the DHC/DHE frame See Data format definitions [BELLE2-NOTE-TE-2016-009] on https://docs.belle2.org/

Definition at line 32 of file PXDRawDataDefinitions.h.

Function Documentation

◆ CalculateMedian()

double CalculateMedian ( std::vector< double > &  signals)

Helper function to calculate a median from unsorted signal vector.

The input vector gets sorted.

Definition at line 90 of file PXDCalibrationUtilities.cc.

91  {
92  auto size = signals.size();
93 
94  if (size == 0) {
95  return 0.0; // Undefined, really.
96  } else if (size <= 100) {
97  // sort() or partial_sort is in O(NlogN)
98  sort(signals.begin(), signals.end());
99  if (size % 2 == 0) {
100  return (signals[size / 2 - 1] + signals[size / 2]) / 2;
101  } else {
102  return signals[size / 2];
103  }
104  } else {
105  // nth_element or max_element in O(N) only
106  // All elements before the nth are guanranteed smaller
107  auto n = size / 2;
108  nth_element(signals.begin(), signals.begin() + n, signals.end());
109  auto med = signals[n];
110  if (!(size & 1)) { // if size is even
111  auto max_it = max_element(signals.begin(), signals.begin() + n);
112  med = (*max_it + med) / 2.0;
113  }
114  return med;
115  }
116  }

◆ FitLandau()

double FitLandau ( std::vector< double > &  signals)

Helper function to calculate MPV from a vector.

The input vector gets sorted.

Definition at line 159 of file PXDCalibrationUtilities.cc.

◆ getDeltaP()

double Belle2::PXD::getDeltaP ( const double  mom,
const double  length,
const double  mass = Const::electronMass 
)
inline

helper function to estimate the most probable energy loss for a given track length.

Parameters
momMagnitude of the momentum
lengthTrack path length
massMass of the incident particle, using e- as default
Returns
the most probable energy

Definition at line 79 of file PXDUtilities.h.

82  {
83  return sensorID.getLayerNumber() * 1000 +
84  sensorID.getLadderNumber() * 10 +
85  sensorID.getSensorNumber();
86  }

◆ hbarWp()

double Belle2::PXD::hbarWp ( const int  Z = Z_Si,
const double  A = A_Si,
const double  rho = rho_Si 
)
inline

hbarWp = sqrt(rho*Z/A)*28.816 in eV

Parameters
ZAtomic number of absorber
AAtomic mass of absorber in g*mol^{-1}
rhoDensity of the absorber in g*cm^{-3}
Returns
plasma energy

Definition at line 66 of file PXDUtilities.h.

◆ TEST() [1/2]

Belle2::PXD::TEST ( ClusterCache  ,
FindNeighbours   
)

Check that we cluster to hits next to each other but not if one is in between.

So we set a cluster at position (2,0) marked c and the findCluster should return this cluster for all positions marked 1. All other pixels should return NULL. We do not check (0,0) and (1,0) or a row above C since the cluster cache is meant to be used with ordered data so these should already be done once we set (2,0).

* u 0 1 2 3 4 5 6 7 8 9 →
* v┌─┬─┬─┬─┬─┬─┬─┬─┬─┬─┬─┐
* 0│ │ │C│1│0│ │ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 1│0│1│1│1│0│ │ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 3│0│0│0│0│0│ │ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 4│ │ │ │ │ │ │ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* ↓│ │ │ │ │ │ │ │ │ │ │ │
*  └─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┘
* 

Definition at line 47 of file ClusterCache.cc.

48  {
49  ClusterCache cache;
50  for (int v = 0; v < 4; ++v) {
51  for (int u = 0; u < 5; ++u) {
52  if (v == 0 && u <= 2) continue;
53  cache.clear();
54  ClusterCandidate& cls1 = cache.findCluster(2, 0);
55  if ((v == 0 && u == 3) || (v == 1 && u >= 1 && u <= 3)) {
56  //Check that neighboring pixels return the same cluster
57  EXPECT_EQ(&cls1, &cache.findCluster(u, v)) << "u: " << u << " v: " << v;
58  } else {
59  //And all other pixels return another cluster
60  EXPECT_NE(&cls1, &cache.findCluster(u, v)) << "u: " << u << " v: " << v;
61  }
62  }
63  }
64  }

◆ TEST() [2/2]

Belle2::PXD::TEST ( ClusterCache  ,
Merging   
)

Test that clusters get merged if they are found to have a common pixel.

If we have to clusters called 1 and 2 like shown below and we add a pixel at X than all occurences of 1 and 2 should be merged to one of those two. It does not matter who is merged to whom but after adding X the result must be

  • one of the two clusters is empty
  • the other cluster contains all pixels
  • all pointers for 1 and 2 should point to the same pixel so that when we add pixels Y and Z we get the same pointer as for X
* u 0 1 2 3 4 5 6 7 8 9 →
* v┌─┬─┬─┬─┬─┬─┬─┬─┬─┬─┬─┐
* 0│ │ │1│ │2│ │3│ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 1│4│ │ │X│ │ │5│ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 2│ │6│Y│ │7│Z│ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* 3│ │ │ │ │ │ │ │ │ │ │ │
*  ├─┼─┼─┼─┼─┼─┼─┼─┼─┼─┼─┤
* ↓│ │ │ │ │ │ │ │ │ │ │ │
*  └─┴─┴─┴─┴─┴─┴─┴─┴─┴─┴─┘
* 

Definition at line 92 of file ClusterCache.cc.

◆ xiBeta2_L()

double Belle2::PXD::xiBeta2_L ( const int  Z = Z_Si,
const double  A = A_Si,
const double  rho = rho_Si,
const int  z = 1 
)
inline

xi = (K/2)*(Z/A)*z*z*(rho*L)/beta2 in MeV

Parameters
ZAtomic number of absorber
AAtomic mass of absorber in g*mol^{-1}
rhoDensity of the absorber in g*cm^{-3}
zCharge number of incident particle
Returns
xi*beta^2/L in MeV/cm where L is track length

Definition at line 51 of file PXDUtilities.h.

Variable Documentation

◆ Z_Si

const int Z_Si = 14

Const and Const expressions Only valid when g_mol is the default unit.

Atomic number of silicon

Definition at line 40 of file PXDUtilities.h.

prepareAsicCrosstalkSimDB.u
u
merged u1 and u2
Definition: prepareAsicCrosstalkSimDB.py:46