Versions Compared

Key

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

...

The algorithm performance was tested for CSPad images. This algorithm consumes up to 15 ms/event on psana0205 , for full CSPad (1650x1650) window size. For smaller window consumed time is negligible, comparing to the image reconstruction time, which is ~70 ms/event (for cspad_mod.CsPadCalib and CSPadPixCoords::CSPadImageProducer) on psana0205.

...

  • source (default: "DetInfo(:Cspad)") – source of data
  • key (default: "Image2D") – key for input image data
  • threshold (default: 10) – minimal threshold on pixel amplitude
  • numPixMin (default: 100) – minimal number of pixels with amplitude above the threshold
  • filterIsOn (default: true) – On/Off the filter
  • xmin (default: 0) – minimal row column number
  • xmax (default: 100000) – maximal row column number
  • ymin (default: 0) – minimal column row number
  • ymax (default: 100000) – maximal column row number
    Remarks:
  • The default key ("Image2D") stands for the CSPadPixCoords::Image2D<double> image object. Other key names work for the ndarray<double,2> image object.
  • The xmin, xmax, ymin, ymax (in pixels) defines the window in the image for pixel counting. Default values means the entire image range.
  • The threshold, numPixMin, and the window extents have to be adjusted for particular experiment.

Module ImgAlgos::ImgPeakFinder.cpp

(Development in progress)
This algorithm was motivated by users of amo42112:
1. select the pixels in the window xmin, xmax, ymin, ymax
with amplitudes above the threshold_low.
2. smear image for selected pixels, using 2-d Gaussian weights over pixels
from -smear_radius to +smear_radius around each smeared pixel amplitude.
Gaussian widths is defined by its sigma value.
3. find peaks as pixels with absolute-maximal amplitude in the center of the matrix
-peak_radius to +peak_radius. The peak amplitude should exceed the threshold_high. (There might be a requirement on number of non-zero amplitude pixels in the matrix around the peak position.)

Module configuration parameters:

  • source (default: "DetInfo()") – source of data
  • key (default: "") – key for input image data
  • threshold_low (default: 150) – low threshold on pixel amplitude
  • threshold_high (default: 250) – high threshold on pixel amplitude
  • sigma (default: 1.5) – width of the Gaussian for smearing
  • smear_radius (default: 2) – radius in pixel for smearing
  • peak_radius (default: 3) – radius in pixel for peak finding
  • xmin (default: 0) – minimal column number
  • xmax (default: 100000) – maximal column number
  • ymin (default: 0) – minimal row number
  • ymax (default: 100000) – maximal row number
  • filterIsOn (default: true) – On/Off algorithm
  • event (default: 0) – event number to save images

Remarks:
This algorithm consumes ~25 ms/event on psana0205 for full Opal1000 (1024x1024) camera image.

Image on different stages of this algorithm;

  1. raw image,
  2. image in the window with amplitudes above the threshold_low (few peaks were discarded by the window limits),
  3. smeared image.
    Image AddedImage AddedImage Added