Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The only difference in interface of this module from previous is in the default name for the source parameter and the output file name.

parameter

default value

description

source

"DetInfo(SxrBeamline.0:Opal1000.1)"

source of data for Opal camera

or:

parameter

default value

description

source

"DetInfo(:Princeton)"

source of data for Princeton camera

See also Example for Package ImgPixSpectra.

...

This module measures the time interval for entire job and for each dn events and prints the rate info as requested by the print_bits parameter.Module configuration parameters:

parameter

default value

description

dn

...

100

number of events between printout

print_bits

...

2

filter verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - start notice and summary at stop

...

  • +4 - instant rate performance after each dn events

...

  • +8 - print summary parameters for parser in log file

...

See also Example for Module ImgAlgos::Tahometer.

...

This module passes only the events if their time stamp is in the requested range.
The range of allowed time stamps is defined by the configuration parameters.

Module configuration parameters:

...

parameter

default value

description

tsinterval

"1970-01-01 00:00:00.000000000 / 2100-01-01 00:00:00.000000000"

...

time-stamp interval string

tstamp_min

...

"1970-01-01 00:00:00.000000000"

...

minimal time-stamp string

tstamp_max

...

"2100-01-01 00:00:00.000000000"

...

maximal time-stamp string

filterIsOn

...

true

On/Off the filter

print_bits

...

0

filter verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - summary

...

  • +4 - event ID

...

  • +8 - time stamp variables for selected event

...

The time-stamp string is accepted in various formats:

...

Note

The unique parameter associated with the event is a time-stamp. The event number is not defined in the xtc file and is not a recommended to use parameter. The events are counted locally inside this filter from the beginning of job starting from 0. Be cautious of using this filter in consecutive jobs for different runs! For example, this filter returns different subsets of events for the files with raw and selected events.

Module configuration parameters:

...

parameter

default value

description

filterIsOn

true

On/Off filter

...

first

...

0

the first event from the beginning of job, starting from 0

...

last

...

1<<31

the last event from the beginning of job

...

evtstring

...

 

the string of events of intervals from the beginning of job

...

print_bits

...

0

filter verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - summary

...

  • +4 - selected event number and ID

...

There are two modes of operation of this filter.

...

  • gets the pnccd data from the event, based on specified source and inkey parameters,
  • puts the ndarray<double,2> object with pnccd 1024x1024 image in the event using specified outimgkey parameter.

...

parameter

default value

description

source

...

"DetInfo(:pnCCD)"

...

source of data

...

inkey

...

 

key for input data

...

outimgkey

...

"pnccdimg"

...

output key for image saved in event

...

print_bits

...

0

verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - initial portion of pnccd array

...

  • +4 - configuration pars

...

See also Example for Module ImgAlgos::PnccdImageProducer.

...

  • gets any camera image data from the event, based on specified source and key_in parameters,
  • puts the ndarray<double,2> object with camera image in the event using specified key_out parameter.

Module configuration parameters:

...

parameter

default value

description

source

"DetInfo(:Opal1000)"

...

source of data

...

key_in

...

 

key for input data

...

key_out

...

"pnccdimg"

...

output key for image saved in event

...

subtract_offset

...

true

on/off the amplitude offset using configuration data

print_bits

...

0

verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - time stamp for each event

...

  • +4 - summary at the endJob

...

  • +8 - details about data format conversion and applied offset

...

See also Example for Module ImgAlgos::CameraImageProducer.

...

  • gets the Princeton camera image data from the event, based on specified source and key_in parameters,
  • puts the ndarray<uint16_t,2> object with image in the event using specified key_out parameter.

Module configuration parameters:

...

parameter

default value

description

source

"DetInfo(:Princeton)"

...

source of data

...

key_in

...

 

key for input data

...

key_out

...

"image"

...

output key for image saved in event

...

print_bits

...

0

verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - record for each event

...

  • +4 - summary at the endJob

...

  • +8 - first 10 elements of the data array

...

  • +16 - configuration info for each beginCalibCycle(...)

...

See also Example for Module ImgAlgos::PrincetonImageProducer.

...

  • 0-stage: the pixel amplitudes are averaged without any constrains for events from 0 to evts_stage1, the preliminary averaged and rms values are defined for each pixel at the end of this stage.
  • 1-stage: starting from event evts_stage1 the pixel data are collected only for abs(amplitude-average0) < gate_width1. At the end of this stage the preliminary averaged and rms values are defined for each pixel.
  • 2-stage: starting from the event evts_stage1 + evts_stage2 the pixel data are collected only for abs(amplitude-average1) < gate_width2. At the end of this stage the preliminary averaged and rms values are defined for each pixel and saved in the files specified by the avefile and rmsfile parameters, respectively.
    This 3-stage averaging algorithm eliminates large statistical fluctuations in the pixel amplitude spectrum.

Module configuration parameters:

...

parameter

default value

description

source

"DetInfo(:Opal1000")

...

input source of data

key

...

 

key for input data, for example, it might be "calibrated"

avefile

...

"img-ave.dat"

...

out file with averaged amplitudes

rmsfile

...

"img-rms.dat"

...

out file with rms

hotpix_mask

...

 

out file with hot pixel mask, saved if the name is not empty

hotpix_thr_adu

...

"10000."

...

threshold on rms (in ADU); if rms exceeds this threshold - pixel is hot

...

evts_stage1

...

1000000

number of events before stage 1

evts_stage2

...

0

additional number of events before stage 2

gate_width1

...

0

gate_width for stage 1

gate_width2

...

0

gate_width for stage 2

print_bits

...

0

module verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - event record

...

  • +4 - beginning of 3 stages

...

  • +8 - processed statistics at the end of each stage

...

  • +16 - output in files

...

Default parameters are set for regular single-stage averaging without any constrains.
See also Example for Module ImgAlgos::ImgAverage.

...

The S/N is estimated by averaging over neigbouring pixels.

Module configuration parameters:

...

parameter

default value

description

source

"DetInfo(:Opal1000")

...

input source of data

...

key

...

 

key for input data, for example, it might be "calibrated"

...

file_mask_satu

...

"img-mask-satu.dat"

...

out file with saturated mask

...

file_mask_nois

...

"img-mask-nois.dat"

...

out file with noise mask

...

file_mask_comb

...

"img-mask-comb.dat"

...

out file with combined mask

...

file_frac_satu

...

"img-frac-satu.dat"

...

out file with fraction of saturated events

...

file_frac_nois

...

"img-frac-nois.dat"

...

out file with fraction of noisy events

...

thre_satu

...

1000000

saturation-threshold (in ADU if the gain correction was not applied to image)

...

frac_satu

...

0

allowed fraction of saturated events

...

dr_SoN_ave

...

1

radial size of the area for S/N evaluation

thre_SoN

...

3

noise-threshold ( in ADU if the gain correction was not applied to image)

...

frac_nois

...

0.5

...

allowed fraction of noisy events

...

print_bits

...

0

module verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - event record

...

  • +4 - vector of indexes for SoN evaluation

...

  • +8 - processed statistics at the end of job

...

  • +16 - output in files

...

See also Example for Module ImgAlgos::ImgMaskEvaluation.

...

  • All files with input calibration parameters should have the same shape as image and formatted as regular text file containing 2d matrix (table) of float (or integer) values, with columns separated by space(s), ' ', and rows(lines) terminated by the '\n'.
  • Background normalization is performed in window defined by the parameters bkgd_row_min, bkgd_row_max, bkgd_col_min, and bkgd_col_max. Normalization factor N is evaluated for pixel amplitudes in this window as:
    N = sum(A_raw - pedestal) / sum(A_bkgd).
  • Masking algorithm assumes that good pixels in the fname_mask file should be marked by '1' (ones) and bad pixels – by '0' (zeros). Mask is applied as a last correction. The bad masked pixel amplitudes are substituted by the masked_value.

Module configuration parameters:

...

parameter

default value

description

source

"DetInfo(:Camera)"

...

source of data

...

key_in

...

 

key for input image

...

key_out

...

"calibrated"

...

output key for calibrated image saved in event

...

fname_peds

...

 

input file name for pedestals, applied if the file name is specified

...

fname_bkgd

...

 

input file name for background, applied if the file name is specified

...

fname_gain

...

 

input file name for gain, applied if the file name is specified

...

fname_mask

...

 

input file name for mask, applied if the file name is specified

...

fname_nrms

...

 

input file name for RMS, applied if the file name is specified

...

masked_value

...

0.

...

amplitude value (in ADU) substituted for masked pixels

...

threshold_nrms

...

3.

...

threshold as a number of sigmas from file fname_nrms

...

threshold

...

0.

...

constant low level threshold in ADU

...

below_thre_value

...

0.

...

the amplitude substituted in pixels below threshold

...

do_threshold

...

false

if true - low level threshold in ADU is applied

...

bkgd_row_min

...

0

the window in image, which is used for background normalization

...

bkgd_row_max

...

10

the window in image, which is used for background normalization

...

bkgd_col_min

...

0

the window in image, which is used for background normalization

...

bkgd_col_max

...

10

the window in image, which is used for background normalization

...

print_bits

...

0

verbosity:

  • =0 - print nothing

...

  • +1 - input pars

...

  • +2 - time stamp for each event

...

  • +4 - detailed info about input files for pedestals, mask, background, and gain

...

  • +8 - first 10 elements of the raw image data
  • +16 - first 10 elements of the calibrated image data

The pedestal, background, gain, mask, and N*RMS corrections are applied if associated file name is specified.
The constant low level threshold is applied if do_threshold is true.
Corrections are not applied by default or with empty file names.

...