Belle II Software  release-08-01-10
PXDPixelMasker Class Reference

Singleton class for managing pixel masking for the PXD. More...

#include <PXDPixelMasker.h>

Collaboration diagram for PXDPixelMasker:

Public Member Functions

void initialize ()
 Initialize the PXDPixelMasker.
 
void setMaskedPixels ()
 Set masked pixels from DB.
 
void setDeadPixels ()
 Set dead pixels from DB.
 
void maskSinglePixel (VxdID id, unsigned int uid, unsigned int vid)
 Mask single pixel. More...
 
bool pixelOK (VxdID id, unsigned int uid, unsigned int vid) const
 Check whether a pixel on a given sensor is OK or not. More...
 
bool pixelDead (VxdID id, unsigned int uid, unsigned int vid) const
 Check whether a pixel on a given sensor is dead or not. More...
 
const PXDMaskedPixelPargetMaskedPixelParameters () const
 Return masked pixel payload.
 
const PXDDeadPixelPargetDeadPixelParameters () const
 Return dead pixel payload.
 

Static Public Member Functions

static PXDPixelMaskergetInstance ()
 Main (and only) way to access the PXDPixelMasker.
 

Private Member Functions

 PXDPixelMasker ()
 Singleton class, hidden constructor.
 
 PXDPixelMasker (const PXDPixelMasker &)=delete
 Singleton class, forbidden copy constructor.
 
PXDPixelMaskeroperator= (const PXDPixelMasker &)=delete
 Singleton class, forbidden assignment operator.
 

Private Attributes

std::unique_ptr< DBObjPtr< PXDMaskedPixelPar > > m_maskedPixelsFromDB
 Masked pixels retrieved from DB.
 
std::unique_ptr< DBObjPtr< PXDDeadPixelPar > > m_deadPixelsFromDB
 Dead pixels retrieved from DB.
 
PXDMaskedPixelPar m_maskedPixels
 List of masked pixels.
 
PXDDeadPixelPar m_deadPixels
 List of masked pixels.
 

Detailed Description

Singleton class for managing pixel masking for the PXD.

Definition at line 27 of file PXDPixelMasker.h.

Member Function Documentation

◆ maskSinglePixel()

void maskSinglePixel ( Belle2::VxdID  id,
unsigned int  uid,
unsigned int  vid 
)

Mask single pixel.

Parameters
idVxdID of the required sensor
uiduCell of single pixel to mask
vidvCell of single pixel to mask

Definition at line 42 of file PXDPixelMasker.cc.

43 {
44  auto vCells = Belle2::VXD::GeoCache::getInstance().get(id).getVCells();
45  m_maskedPixels.maskSinglePixel(id.getID(), uid * vCells + vid);
46 }
void maskSinglePixel(unsigned short sensorID, unsigned int pixID)
Mask single pixel.
PXDMaskedPixelPar m_maskedPixels
List of masked pixels.
static GeoCache & getInstance()
Return a reference to the singleton instance.
Definition: GeoCache.cc:214
static const SensorInfoBase & get(Belle2::VxdID id)
Return a reference to the SensorInfo of a given SensorID.
Definition: GeoCache.h:139
int getVCells() const
Return number of pixel/strips in v direction.
int getID(const std::vector< double > &breaks, double t)
get id of the time point t
Definition: calibTools.h:60

◆ pixelDead()

bool pixelDead ( Belle2::VxdID  id,
unsigned int  uid,
unsigned int  vid 
) const

Check whether a pixel on a given sensor is dead or not.

Parameters
idVxdID of the sensor
uiduCell of single pixel
vidvCell of single pixel
Returns
true if pixel DEAD, otherwise false.

Definition at line 56 of file PXDPixelMasker.cc.

◆ pixelOK()

bool pixelOK ( Belle2::VxdID  id,
unsigned int  uid,
unsigned int  vid 
) const

Check whether a pixel on a given sensor is OK or not.

Parameters
idVxdID of the sensor
uiduCell of single pixel
vidvCell of single pixel
Returns
true if pixel is OK, otherwise false.

Definition at line 50 of file PXDPixelMasker.cc.


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