aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/man/indexamajig.19
-rw-r--r--src/indexamajig.c9
-rw-r--r--src/process_image.c2
-rw-r--r--src/process_image.h1
4 files changed, 4 insertions, 17 deletions
diff --git a/doc/man/indexamajig.1 b/doc/man/indexamajig.1
index 495abfa2..1d19bfad 100644
--- a/doc/man/indexamajig.1
+++ b/doc/man/indexamajig.1
@@ -51,7 +51,7 @@ If you use \fB--peaks=zaef\fR, indexamajig will use a simple gradient search aft
If you instead use \fB--peaks=peakfinder8\fR, indexamajig will use the "peakfinder8" peak finding algorithm describerd in Barty et al. (2014). Pixels above a radius-dependent intensity threshold are considered as candidate peaks (although the user sets an absolute minimum threshold for candidate peaks). Peaks are then only accepted if their signal to noise level over the local background is sufficiently high. Peaks can include multiple pixels and the user can reject a peak if it includes too many or too few. The distance of a peak from the center of the detector can also be used as a filtering criterion. Note that the peakfinder8 will not report more than 2048 peaks for each panel: any additional peak is ignored.
-If you instead use \fB--peaks=peakfinder9\fR, indexamajig will use the "peakfinder9" peak finding algorithm described in the master thesis "Real-time image analysis and data compression in high throughput X-ray diffraction experiments" by Gevorkov. Other than peakFinder8, peakFinder9 uses local background estimation based on border pixels in a specified radius (\fB--window-radius\fR). For being fast and precise, a hierarchy of conditions is used. First condition is only useful for speed consideration, it demands that a pixel that is the biggest pixel in a peak must be larger than every border pixel by a constant value (\fB--min-peak-over-neighbour\fR). Second condition ensures, that the pixel passing the previous condition is the highest pixel in the peak. It assumes, that peaks rise monotonically towards the biggest pixel. Third condition ensures, that the biggest pixel in the peak is significantly over the noise level (\fB--min-snr-biggest-pix\fR) by computing the local statistics from the border pixels in a specified radius. Fourth condition sums up all pixels belonging to the peak (\fB--min-snr-peak-pix\fR) and demands that the whole peak must be significantly over the noise level (\fB--min-snr\fR). Only if all conditions are passed, the peak is accepted.
+If you instead use \fB--peaks=peakfinder9\fR, indexamajig will use the "peakfinder9" peak finding algorithm described in the master thesis "Real-time image analysis and data compression in high throughput X-ray diffraction experiments" by Gevorkov. Other than peakFinder8, peakFinder9 uses local background estimation based on border pixels in a specified radius (\fB--local-bg-radius\fR). For being fast and precise, a hierarchy of conditions is used. First condition is only useful for speed consideration, it demands that a pixel that is the biggest pixel in a peak must be larger than every border pixel by a constant value (\fB--min-peak-over-neighbour\fR). Second condition ensures, that the pixel passing the previous condition is the highest pixel in the peak. It assumes, that peaks rise monotonically towards the biggest pixel. Third condition ensures, that the biggest pixel in the peak is significantly over the noise level (\fB--min-snr-biggest-pix\fR) by computing the local statistics from the border pixels in a specified radius. Fourth condition sums up all pixels belonging to the peak (\fB--min-snr-peak-pix\fR) and demands that the whole peak must be significantly over the noise level (\fB--min-snr\fR). Only if all conditions are passed, the peak is accepted.
You can suppress peak detection altogether for a panel in the geometry file by specifying the "no_index" value for the panel as non-zero.
@@ -260,11 +260,6 @@ Set the square of the gradient threshold for peak detection using \fB--peaks=zae
Set the minimum I/sigma(I) for peak detection when using \fB--peaks=zaef\fR, \fB--peaks=peakfinder8\fR or \fB--peaks=peakfinder9\fR. The default is \fB--min-snr=5\fR for \fB--peaks=zaef\fR and \fB--peaks=peakfinder8\fR, \fB--min-snr=9\fR for \fB--peaks=peakfinder9\fR.
.PD 0
-.IP \fB--window-radius=<n>\fR
-.PD
-(peakFinder9 only) defines the radius in which the local background is estimated. Should be > max radius of peak. Default is 3.
-
-.PD 0
.IP \fB--min-snr-biggest-pix=<n>\fR
.PD
(peakFinder9 only) min snr of the biggest pixel in the peak, given as a factor of the standard deviation. Default is 7.0.
@@ -297,7 +292,7 @@ Accepts peaks only if they include less than \fR\fIcnt\fR pixels, when using \fB
.PD 0
.IP \fB--local-bg-radius=\fR\fIr\fR
.PD
-Radius (in pixels) used for the estimation of the local background when using \fB--peaks=peakfinder8\fR. The default is \fB--local-bg-radius=3\fR.
+Radius (in pixels) used for the estimation of the local background when using \fB--peaks=peakfinder8 or --peaks=peakfinder9\fR. The default is \fB--local-bg-radius=3\fR.
.PD 0
.IP \fB--min-res=\fR\fIpx\fR
diff --git a/src/indexamajig.c b/src/indexamajig.c
index 97024b54..1b1545a9 100644
--- a/src/indexamajig.c
+++ b/src/indexamajig.c
@@ -105,13 +105,11 @@ static void show_help(const char *s)
" --max-pix-count=<n> Maximum number of pixels per peak\n"
" (peakfinder8 only) Default: 200\n"
" --local-bg-radius=<n> Radius (pixels) for local background estimation\n"
-" (peakfinder8 only) Default: 3\n"
+" (peakfinder8, peakfinder9 only) Default: 3\n"
" --min-res=<n> Minimum resolution for peak search (in pixels)\n"
" (peakfinder8 only) Default: 0\n"
" --max-res=<n> Maximum resolution for peak search (in pixels)\n"
" (peakfinder8 only) Default: 1200\n"
-" --window-radius=<n> (peakFinder9 only) defines the radius in which the "
-" local background is estimated\n"
" --min-snr-biggest-pix=<n> (peakFinder9 only) min snr of the biggest pixel in "
" the peak\n"
" --min-snr-peak-pix=<n> (peakFinder9 only) min snr of a peak pixel\n"
@@ -275,7 +273,6 @@ int main(int argc, char *argv[])
iargs.min_snr_whole_peak = 9.0;
iargs.min_sig = 11.0;
iargs.min_peak_over_neighbour = -INFINITY;
- iargs.window_radius = 3;
iargs.check_hdf5_snr = 0;
iargs.det = NULL;
iargs.peaks = PEAK_ZAEF;
@@ -425,7 +422,6 @@ int main(int argc, char *argv[])
{"min-snr-peak-pix" ,1, NULL,348},
{"min-sig" ,1, NULL,349},
{"min-peak-over-neighbour" ,1, NULL,350},
- {"window-radius" ,1, NULL,351},
{0, 0, NULL, 0}
};
@@ -769,9 +765,6 @@ int main(int argc, char *argv[])
iargs.min_peak_over_neighbour = strtof(optarg, NULL);
break;
- case 351:
- iargs.window_radius = atoi(optarg);
-
case 0 :
break;
diff --git a/src/process_image.c b/src/process_image.c
index e8bcd911..c12ec3b5 100644
--- a/src/process_image.c
+++ b/src/process_image.c
@@ -230,7 +230,7 @@ void process_image(const struct index_args *iargs, struct pattern_args *pargs,
iargs->min_snr_whole_peak,
iargs->min_sig,
iargs->min_peak_over_neighbour,
- iargs->window_radius) )
+ iargs->local_bg_radius) )
{
if ( image.event != NULL ) {
ERROR("Failed to find peaks in image %s"
diff --git a/src/process_image.h b/src/process_image.h
index 924b8ac4..7b050e83 100644
--- a/src/process_image.h
+++ b/src/process_image.h
@@ -90,7 +90,6 @@ struct index_args
float min_snr_whole_peak;
float min_sig;
float min_peak_over_neighbour;
- int window_radius;
struct imagefile_field_list *copyme;
int integrate_saturated;
int use_saturated;