STIR  6.2.0
Functions
find_maxima_in_image.cxx File Reference

List coordinates of maxima in the image to stdout. More...

#include "stir/shared_ptr.h"
#include "stir/DiscretisedDensity.h"
#include "stir/DiscretisedDensityOnCartesianGrid.h"
#include "stir/IO/read_from_file.h"
#include "stir/warning.h"
#include <iostream>
#include <iomanip>
#include <algorithm>

Functions

int main (int argc, char *argv[])
 

Detailed Description

List coordinates of maxima in the image to stdout.

If more than 1 maximum is asked for, repeat the following:

find the current maximum, and then

mask the neighbourhood (specified as a box) out

go to step 1

Author
Sanida Mustafovic
Kris Thielemans
Usage:
find_maxima_in_image filename [num_maxima [ half_mask_size_xy [half_mask_size z]] ]
Parameters
num_maximadefaults to 1
half_mask_size_xydefaults to 1 (giving a 3x3 mask in the plane)
half_mask_size_zdefaults to half_mask_size_xy