CFEL - ASG Software Suite  2.5.0
CASS
Public Types | Public Member Functions | Private Attributes | List of all members
cass::pixeldetector::AdvancedDetector Class Reference

An Advanced Pixel Detector. More...

#include <advanced_pixeldetector.h>

+ Collaboration diagram for cass::pixeldetector::AdvancedDetector:

Public Types

typedef std::vector< Hithits_t
 define the list of coalesced pixels More...
 
typedef std::vector< Pixelpixels_t
 

Public Member Functions

 AdvancedDetector (const std::string &name)
 constructor More...
 
void associate (const CASSEvent &evt)
 associate the detector with a simple Pixel Detector within a CASSEvent More...
 
void loadSettings (CASSSettings &s)
 load the settings of this More...
 
const Frameframe ()
 retrieve the frame More...
 
const pixels_tpixels ()
 retrieve the pixellist More...
 
const hits_thits ()
 retrieve the hits/ More...
 

Private Attributes

std::tr1::shared_ptr< CommonData_common
 container for data common for all detectors with this name More...
 
Frame _frame
 the frame of the detector More...
 
bool _frameExtracted
 flag to tell whether the frame has been extracted already More...
 
std::tr1::shared_ptr< FrameProcessorBase_process
 functor to extract the frame from the CASSEvent More...
 
pixels_t _pixels
 the list of pixels More...
 
bool _pixellistCreated
 flag to tell whether the pixel list has been created More...
 
std::tr1::shared_ptr< PixelFinderBase_find
 functor to extract the pixel list More...
 
hits_t _hits
 hits on the detector More...
 
bool _hitListCreated
 flag whether hit list has been created already More...
 
std::tr1::shared_ptr< CoalescingBase_coalesce
 functor that will do the coalescing More...
 
std::string _name
 the name of this detector More...
 
int32_t _detector
 the detector within the device More...
 

Detailed Description

An Advanced Pixel Detector.

This class describes a pixel detector which has all the opertors to analyse and extract the additional information internally.

User definable Parameters:

PixelDetectors/%name%/{Detector}
The detector that contains the ccd image. Default is 0. Options are:

  • 0: Front pnCCD
  • 1: Rear pnCCD
  • 2: 1st commercial CCD in AMO
  • 3: 2nd commercial CCD in AMO
  • 4: 3rd commercial CCD in AMO
  • 6: 4th commercial CCD in AMO
  • 5: 1st commercial CCD in XPP
  • 7: Front CsPad in CXI
  • 8: Rear CsPad in CXI

PixelDetectors/%name%/{FrameProcessorType}
Functor for processing the frame. Default is "none". Options are:

  • "none": No processing is done to the frame, just the raw frame will be returned
  • "hll": The type of processing that the semiconductor lab applies to their frame data. see cass::pixeldetector::HLLProcessor

PixelDetectors/%name%/{PixelFinderType}
Functor for finding pixels of interest in the frame. The pixels will be found after the frame processor has processed the frame. Default is "aboveNoise". Options are:

PixelDetectors/%name%/{CoalescingFunctionType}
Functor to coalesce the pixels into hits. Default is "simple". Options are:

there are more settings for the common data. Please see cass::pixeldetector::CommonData for details on what to set.

Author
Lutz Foucar

Definition at line 159 of file advanced_pixeldetector.h.

Member Typedef Documentation

define the list of coalesced pixels

Definition at line 163 of file advanced_pixeldetector.h.

Definition at line 165 of file advanced_pixeldetector.h.

Constructor & Destructor Documentation

AdvancedDetector::AdvancedDetector ( const std::string &  name)

constructor

Parameters
namethe name of this detector

Definition at line 27 of file advanced_pixeldetector.cpp.

Member Function Documentation

void AdvancedDetector::associate ( const CASSEvent evt)

associate the detector with a simple Pixel Detector within a CASSEvent

resets the flags indicating whether the frame, the pixel list and the hit list have been created. Copies the Frame data the info about the columns and rows to the _frame object of this class. The _frame object is then passed to the _common object. This should then build up the necessary Maps for correcting. See CommonData for details

Parameters
evtThe CASSEvent that contains the PixelDetector that this container is responsible for.

validate the detector data

Definition at line 70 of file advanced_pixeldetector.cpp.

References _common, _detector, _frame, _frameExtracted, _hitListCreated, _hits, _pixellistCreated, _pixels, cass::pixeldetector::Frame::columns, cass::pixeldetector::Detector::columns(), cass::pixeldetector::Frame::data, cass::pixeldetector::Device::dets(), cass::CASSEvent::devices(), cass::pixeldetector::Detector::frame(), cass::CASSEvent::id(), cass::pixeldetector::Detector::id(), cass::CASSEvent::PixelDetectors, cass::pixeldetector::Frame::rows, cass::pixeldetector::Detector::rows(), and cass::toString().

const Frame & AdvancedDetector::frame ( )

retrieve the frame

the frame from the cass event is treated with the frame processor _process before it is returned, but only when it has not yet been treated. For all available options see this classes cass settings information.

Definition at line 35 of file advanced_pixeldetector.cpp.

References _frame, _frameExtracted, and _process.

Referenced by pixels().

const AdvancedDetector::hits_t & AdvancedDetector::hits ( )

retrieve the hits/

Hits are defined as particles or photons that hit the detector. Those hits can potentially not only be detected by just one pixel. Therefore one has to find the pixels that belong to one hit on the detector. This is done by the coalsecing functions available to this class (for a complete list of all available finding procedures please refer to the description of this class). The coalsecing functions work on the pixellist that is created from the processed frame.

Definition at line 58 of file advanced_pixeldetector.cpp.

References _coalesce, _frame, _hitListCreated, _hits, _pixels, cass::pixeldetector::coalesce(), and pixels().

void AdvancedDetector::loadSettings ( CASSSettings s)

load the settings of this

loads which FrameProcessorBase functor should be used, get an instance of the right type and load its settings. loads which PixelFinderBase functor should be used, get an instance of the right type and load its settings. loads which CoalescingBase functor should be used, get an instance of the right type and load its settings. the loads the seetings for the common data. See CommonData for details.

Parameters
sthe CASSSettings object to read the information from

Definition at line 101 of file advanced_pixeldetector.cpp.

References _coalesce, _common, _detector, _find, _name, _process, QSettings::beginGroup(), QSettings::endGroup(), QString::fromStdString(), cass::pixeldetector::FrameProcessorBase::instance(), cass::pixeldetector::CoalescingBase::instance(), cass::pixeldetector::PixelFinderBase::instance(), cass::pixeldetector::CommonData::instance(), and QSettings::value().

const AdvancedDetector::pixels_t & AdvancedDetector::pixels ( )

retrieve the pixellist

the pixels list contains all pixels that fullfill a certain criteria. They are found in the processed frame using different finding functions. For a list of all available finding procedures please refer to the description of this class.

Definition at line 46 of file advanced_pixeldetector.cpp.

References _find, _frame, _pixellistCreated, _pixels, and frame().

Referenced by hits().

Member Data Documentation

std::tr1::shared_ptr<CoalescingBase> cass::pixeldetector::AdvancedDetector::_coalesce
private

functor that will do the coalescing

Definition at line 258 of file advanced_pixeldetector.h.

Referenced by hits(), and loadSettings().

std::tr1::shared_ptr<CommonData> cass::pixeldetector::AdvancedDetector::_common
private

container for data common for all detectors with this name

Definition at line 231 of file advanced_pixeldetector.h.

Referenced by associate(), and loadSettings().

int32_t cass::pixeldetector::AdvancedDetector::_detector
private

the detector within the device

Definition at line 264 of file advanced_pixeldetector.h.

Referenced by associate(), and loadSettings().

std::tr1::shared_ptr<PixelFinderBase> cass::pixeldetector::AdvancedDetector::_find
private

functor to extract the pixel list

Definition at line 249 of file advanced_pixeldetector.h.

Referenced by loadSettings(), and pixels().

Frame cass::pixeldetector::AdvancedDetector::_frame
private

the frame of the detector

Definition at line 234 of file advanced_pixeldetector.h.

Referenced by associate(), frame(), hits(), and pixels().

bool cass::pixeldetector::AdvancedDetector::_frameExtracted
private

flag to tell whether the frame has been extracted already

Definition at line 237 of file advanced_pixeldetector.h.

Referenced by associate(), and frame().

bool cass::pixeldetector::AdvancedDetector::_hitListCreated
private

flag whether hit list has been created already

Definition at line 255 of file advanced_pixeldetector.h.

Referenced by associate(), and hits().

hits_t cass::pixeldetector::AdvancedDetector::_hits
private

hits on the detector

Definition at line 252 of file advanced_pixeldetector.h.

Referenced by associate(), and hits().

std::string cass::pixeldetector::AdvancedDetector::_name
private

the name of this detector

Definition at line 261 of file advanced_pixeldetector.h.

Referenced by loadSettings().

bool cass::pixeldetector::AdvancedDetector::_pixellistCreated
private

flag to tell whether the pixel list has been created

Definition at line 246 of file advanced_pixeldetector.h.

Referenced by associate(), and pixels().

pixels_t cass::pixeldetector::AdvancedDetector::_pixels
private

the list of pixels

Definition at line 243 of file advanced_pixeldetector.h.

Referenced by associate(), hits(), and pixels().

std::tr1::shared_ptr<FrameProcessorBase> cass::pixeldetector::AdvancedDetector::_process
private

functor to extract the frame from the CASSEvent

Definition at line 240 of file advanced_pixeldetector.h.

Referenced by frame(), and loadSettings().


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