Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation needed for the newer peaksearching / segmentation #359

Open
1 task
jonwright opened this issue Dec 5, 2024 · 0 comments
Open
1 task

Documentation needed for the newer peaksearching / segmentation #359

jonwright opened this issue Dec 5, 2024 · 0 comments

Comments

@jonwright
Copy link
Member

We are missing some documentation since the peaksearching/segmentation was overhauled in recent years.

The traditional code is described here:. There is an incantation to run the traditional peaksearch code described in com_guide with the new hdf5 data formats, as an alternative to the hdf5scan.py shim that is in sandbox:

peaksearch.py -n SiliconWaferXrotyCalib_att10.h5::1.1/measurement/eiger -f 0 -l 3600 -t 10 -p Y -F "" --ndigits=0 -o /tmp/test.spt

This is not obvious and still misses a mask option. For ID03 and finterlaced I guess you need --interlaced and --iflip too.

The newer code in ImageD11/sinograms/lima_segmenter is taking a 2D frame and segmenting to create sparse arrays (e.g. saving pixels in peaks). This is similar to pyFAI's sparsify bragg method.

There are currently two pixel to peak labelling methods in C code, for both sparse and dense images. A simple connected components and and also an uphill assignment (localmaxlabel). These are not exposed in most of the user facing code. There are a few different places where there is code for collecting peak moments from labeled images. There is also code to compare in scipy.ndimage or skimage, etc.

  • we miss any function to "fit a peak" into a 2D (or 3D stack). This is mainly interesting for overlapping peaks.

For merging peaks across frames we have:

  • 3D: peaksearch.py has peaks merged if there are common pixels overlapping
  • 3D: very old code in ImageD11.peakmerger and newer code in frelon_peaksearch that merges based on centroids
  • 3D + 4D sinograms: recent code based on overlapping pixels

There is an open issues for the 4D merging code

There are GUI things in the old tkinter code, in ImageD11/silxGuis, and in the existing Orange code in Julia's project for ID06:

https://gitlab.esrf.fr/julia.garriga/3DXRD/-/blob/master/imaged11_julia/peakSearchWidget.py?ref_type=heads

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant