10 #ifndef _PIXELDETECTORCALIBRATION_H_
11 #define _PIXELDETECTORCALIBRATION_H_
168 const size_t sizeOfImage);
185 const size_t sizeOfImage);
storage_t::const_iterator const_iterator
a const iterator on the storage
bool _write
flag to tell whether the calibration should be written
std::vector< statistic_t > statistics_t
defintion of the statistics
size_t _aveOffset
offset to the average part
float _autoNoiseSNR
the signal to noise ratio that determines the noise boundaries in case of automatically determining t...
Event to store all LCLS Data.
char mask_t
define the output mask type
pp332(const name_t &)
constructor.
float _snr
the value above which outliers are removed from the distribution
pp333(const name_t &)
constructor.
std::tr1::function< float(result_t::const_iterator, result_t::const_iterator)> _calcCommonmode
the function that calculates the commond mode level
std::string _filename
the filename that is used to save the calibration
pp331(const name_t &)
constructor.
uint32_t _lastwritten
the time_t value of the last time the calibration was written
pp334(const name_t &)
constructor.
void movingUpdate(result_t::const_iterator image, result_t::iterator meanAr, result_t::iterator stdvAr, result_t::iterator nValsAr, const size_t sizeOfImage)
a moving exponential average and variance calculation
virtual void loadSettings(size_t)
load the settings of this pp
void loadCalibration()
write the calibration data to file
int _nFrames
the number of frames after which the gain map is calculted
virtual void loadSettings(size_t)
load the settings of this pp
float _autoNoiseSNRStat
the signal to noise ratio that determines which values will be taken into account when automatically ...
pp330(const name_t &)
constructor.
pixel detector gain calibrations
bool _write
flag to tell whether the calibration should be written
float _NoiseLowerBound
the lower noise boundary when determining bad pixels
std::vector< result_t::shared_pointer > _trainstorage
the storage for the training images
shared_pointer _image
the raw image
float _maxADUVal
the maximum allowed adu value
virtual void processCommand(std::string command)
receive commands from the gui
size_t _countOffset
offset to the counts part
std::pair< float, float > range_t
define the range type
std::string _filename
the filename that is used to save the calibration
virtual void loadSettings(size_t)
load the settings of this pp
std::tr1::function< void(result_t::const_iterator, result_t::iterator, result_t::iterator, result_t::iterator, const size_t)> updateFunc_t
define the function
void writeCalibration()
write the calibration data to file
size_t _bPixBeginOffset
the offset to the first point of the bad pixels array in the result
float _snr
the signal to noise ratio in case one uses the mean calculator
std::pair< size_t, double > statistic_t
definition of the statistic
int _updatePeriod
the period after which the data should be autosaved
size_t _stdvBeginOffset
the offset to the first point of the stdv array in the result
bool _train
flag telling whether training is needed
virtual void process(const CASSEvent &, result_t &)
overwrite default behaviour don't do anything
size_t _minTrainImages
the minimum nbr of images necessary for training
uint32_t _updateWritePeriod
the update time period in s
pixel detector hot pixel detection
std::string _infilename
the filename that is used to load the calibration
virtual void process(const CASSEvent &, result_t &)
overwrite default behaviour don't do anything
virtual void process(const CASSEvent &, result_t &)
overwrite default behaviour don't do anything
int _counter
counter to count how many times this has been called
base class for processors.
size_t _width
the number of times a pixel is high before masking it as hot pixel
float _constGain
the gain value that will be assinged to the pixel that one could not calculate the gain for ...
size_t _meanEndOffset
the offset to one beyond the last point of the mean array in the result
virtual void loadSettings(size_t)
load the settings of this pp
pixel detector common mode background calculation
size_t _sizeOfImage
the size of the input image
float _minNbrPixels
minimum number of pixels in the trainig set that are part of the distribution
void calculateGainMap(result_t &gainmap)
write the calibration data to file
shared_pointer _image
the image to create the hotpixel map from
size_t _counter
counter to count the total amount of images
void cummulativeUpdate(result_t::const_iterator image, result_t::iterator meanAr, result_t::iterator stdvAr, result_t::iterator nValsAr, const size_t sizeOfImage)
a cummulative average and variance calculation
virtual void aboutToQuit()
write the calibrations before quitting
float meanCalc(result_t::const_iterator begin, result_t::const_iterator end)
function to calulate the common mode level as mean value
range_t _aduRange
the range of adu that indicates whether a pixel is hot
statistics_t _statistics
the statistics for each pixel
float _alpha
the alpha value for the moving average and stdv
void writeHotPixelMap()
write the calibration data to file
shared_pointer _image
the image to create the hotpixel map from
bool _isPnCCDNoCTE
flag to tell whether its a pnCCD we are not interested in correction the cte
void loadCalibration()
write the calibration data to file
file contains processors baseclass declaration
updateFunc_t _updateStatistics
the function that will update the statistics
size_t _nValBeginOffset
the offset to the first point of the counts array in the result
range_t _aduRange
the range of adu that indicates whether a pixel contains a photon
size_t _minPhotonCount
the number of photons that a pixel should have seen before calculating the gain
size_t _maxConsecutiveCount
the number of times a pixel is high before masking it as hot pixel
size_t _bPixEndOffset
the offset to one beyond the last point of the bad pixels array in the result
virtual void process(const CASSEvent &, result_t &)
overwrite default behaviour don't do anything
virtual void aboutToQuit()
write the calibrations before quitting
virtual void loadSettings(size_t)
load the settings of this pp
pixel detector common mode background calculation
size_t _stdvEndOffset
the offset to one beyond the last point of the stdv array in the result
storage_t::iterator iterator
a iterator on the storage
contains declarations of statistic calculators
float _OffsetLowerBound
the lower offset boundary when determining bad pixels
float _NoiseUpperBound
the upper noise boundary when determining bad pixels
float _autoOffsetSNR
the signal to noise ratio that determines the offset boundaries in case of automatically determining ...
std::pair< float, float > range_t
define the range type
int _counter
counter to count how many times this has been called
bool _update
flag to tell whether the calibration should be updated after the training has completed.
virtual void processCommand(std::string command)
react on when the gui clients tell this to start the calibration
float medianCalc(result_t::const_iterator begin, result_t::const_iterator end)
function to calulate the common mode level via the median value
void writeCalibration()
write the calibration data to file
an accumulating processor
float _autoOffsetSNRStat
the signal to noise ratio that determines which values will be taken into account when automatically ...
pixel detector calibrations
size_t _gainOffset
offset to the gain part
size_t _meanBeginOffset
the offset to the first point of the mean array in the result
virtual void process(const CASSEvent &, result_t &)
overwrite default behaviour don't do anything
float _maxDist
the maximum distance between the value of the unbonded pxiels and the hist
int _nFrames
the number of frames after which the gain map is calculted
std::string name_t
define the name type
bool _resetBadPixel
flag to tell when the bad pixel should be reset
float _OffsetUpperBound
the upper offset boundary when determining bad pixels
std::tr1::shared_ptr< Processor > shared_pointer
a shared pointer of this
float _width
the number of times a pixel is high before masking it as hot pixel
size_t _nValEndOffset
the offset to the first point of the counts array in the result
bool _write
flag to tell whether the calibration should be written
std::string _filename
the filename that is used to save the calibration
bool _checks
enable output that allow to check the parameters
shared_pointer _image
the raw image
virtual void aboutToQuit()
write the calibrations before quitting
void setBadPixMap()
set up the bad pixel map
void loadHotPixelMap()
write the calibration data to file
shared_pointer _image
the image to create the hotpixel map from