A picture is worth a thousand words.
Ideally the data processing task is broken down into manageable steps.
Currently implemented by a script called peaksearch.py. This depends on the connectedpixels compiled extension for using a disjoint set algorithm for finding connected intensity above a threshold level. The script also applies a spatial distortion correction according to a fit2d spline file using the compiled extension _splines called from bisplev.py and implemented in blobcorrector.py.
This script relies on the opendata.py module for reading images. A sometimes useful script bgmaker.py will take a series of images and find the minimum value in each pixel to use as a dark currect for background subtraction.
Alternative implementations are planned. For example, fit2d includes a peak search in the online crystallography menu. Also such information could be dumped from imagepro.
Generated file (usually .out) contains all header information from the images plus a list of peak positions in fairly self explanatory ascii format.
Useful jobs to do include getting more accurate peak positions and intensities by fitting a peak. Also extending the algorithm to 3 dimensions. Extend the opendata.py script to handle other image formats. Also extend the threshold to depend where you are in the image - so it is adjusted according to the expected strength of the peaks.
Ideally this task is carried out within the peaksearch.py script by reading angle information from image headers. Can also be done using the recoveromega.py script.
Generated file (usually .out) is same as for step 1. but Omega header values are interpreted as the vertical rotation angle in the second hutch. Pixel size values might or might not be read from the headers later.
Useful jobs to do include extending this information to a generalised geometry for arbitrary diffractometers (and handling all that later!).
The first menu in the ImageD11_gui.py currently carries out this task. Peaks on adjacent images within a tolerence of 2 pixels are considered to be the same peak and averaged. Mostly implemented in guipeaksearch.py, needs to split into a gui and action script.
Filtering has to be carried out manually by expert users, or not at all by beginners (sorry). Eventually we should be able to filter on peak shape, peak intensity, peak position (radial, azimuthal/x/y) etc.
Generated file (usually .flt) contains header lines beginning with "#" and then list of peaks which have at least the properties xc, yc and omega. Other useful information (peak shape, intensity etc) can also be propagated, I hope.
Useful jobs to do make a graphical method of filtering which is an interface to a range of filtering functionality. Plot things like histograms of property (eg intensity) to decide on thresholds. Certainly need a lorentz factor filter which is not currently present.
The second menu in the ImageD11_gui.py script carries out this task. Mostly implemented in guitransformer.py and transform.py.
Radial and azimuthal angles are computed for each peak using the sample to detector distance, pixel size, beam centre and detector tilts. These are converted to g-vectors according to the rotation angle (omega) and the axis tilt (wedge).
The g-vectors can be written to a file that might be suited for input into the GRAINDEX [link] software.
Generated file (usually .gve) contains the unit cell, the wavelength, a long and pointless list of possible hkl values (will disappear in later versions of the program) and then the g-vectors and propagated information.
Useful jobs to do Extend the geometry to a generalised n-axis case. Allow for crystal translations with respect to the centre of rotation when making computations.
The indexing menu in the gui, ImageD11_gui.py presents the only implementation of a separated gui and useful code so far. The indexing work is done by the script indexing.py and the interface is in the script guiindexer.py. This module depends on a compiled extension closest for finding searching arrays for the best agreeing cosines and also scoring orientations (just dot products and looping).
Generated file (usually .idx) gives a lot of output of which peaks are indexed by which grain and how well they are indexed.
Generated file (usually .ubi) gives a list of orientation matrices if you want to go searching for the same grains in other data.
Useful jobs to do Read in orientation matrices from ubi files to test out grains against new data. Refine collections of grains including crystal translations.
The program doesn't do that yet. Please make it do that!
Good luck