Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

brip_para_cvrg Class Reference

#include <brip_para_cvrg.h>

Inheritance diagram for brip_para_cvrg:

Inheritance graph
[legend]
List of all members.

Detailed Description

Definition at line 36 of file brip_para_cvrg.h.

Public Member Functions

 brip_para_cvrg (float sigma=1.0, float low=6, float gauss_tail=.05, int proj_width=7, int proj_height=1, int sup_radius=1, bool verbose=true)
 Constructor s.
 brip_para_cvrg (brip_para_cvrg_params &pdp)
 ~brip_para_cvrg ()
 Destructor.
void do_coverage (vil1_image const &image)
vil1_memory_image_of< float > get_float_detection_image (const float max=255)
 Get the float image of detections. Scale onto [0, max].
vil1_memory_image_of< unsigned
char > 
get_detection_image ()
 Get the unsigned char image of detections.
vil1_memory_image_of< unsigned
char > 
get_dir_image ()
 Get the direction image (unsigned char).
vil1_memory_image_of< vil1_rgb<
unsigned char > > 
get_combined_image ()
 Get the combination of coverage and direction as a color image.
bool SanityCheck ()
 Checks that parameters are within acceptable bounds.

Public Attributes

float sigma_
 Standard deviation of the smoothing kernel.
float thresh_
 Low hysteresis threshold.
float gauss_tail_
 Used in determining the convolution kernel.
int proj_width_
 1/2 the projection region width
int proj_height_
 1/2 the projection region height
int sup_radius_
 The non_maximum suppression kernel width.
bool verbose_
 output debug messages

Private Member Functions

void init (vil1_image const &image)
 Image Initialization.
void init_variables ()
 Variable Initialization.
float ** make_float_image (int m, int n)
 Returns an m*n array of floats. Private.
void free_float_image (float **image)
 Frees an m*n array of floats. Private.
float * make_float_vector (int size)
 Returns a vector of floats length m. Private.
void set_float_vector (float *vector, int size, float val)
 Sets a floating point image to val. Private.
void set_float_image (float **, float)
 Sets a floating point image to val. Private.
void copy_image (float **, float **)
 Copies float image1 to image2. Private.
void set_kernel ()
void smooth_image ()
 Convolves the image with the smoothing kernel. Private.
void avg (int x, int y, vil1_memory_image_of< float > const &smooth, float **avg)
 Compute the average value in the 7x7 window.
void grad0 (int x, int y, vil1_memory_image_of< float > const &smooth, float **grad0)
 Compute a gradient operator at x,y along the x axis.
void grad45 (int x, int y, vil1_memory_image_of< float > const &smooth, float **grad45)
 Compute a gradient operator at x,y at 45 degrees.
void grad90 (int x, int y, vil1_memory_image_of< float > const &smooth, float **grad90)
 Compute a gradient operator at x,y at 90 degrees.
void grad135 (int x, int y, vil1_memory_image_of< float > const &smooth, float **grad135)
 Compute a gradient operator at x,y at 135 degrees.
void compute_gradients ()
 Convolves with the kernel in the x direction, to compute the local derivative in that direction. Private.
float project (int x, int y, int dir, float *projection)
 Project the gradient magnitude along a given direction.
void remove_flat_peaks (int n, float *array)
 Prune any sequences of more than one maximum value.
void non_maximum_supress (float *array, float *sup_array)
 Find locally maximum peaks in the input array.
float parallel_coverage (float *sup_array)
 Find the amount of overlapping parallel coverage.
void compute_parallel_coverage ()
 Find the direction with maximum parallel coverage. Return the normalized coverage value.
void compute_image (float **data, vil1_memory_image_of< unsigned char > &image)
 Compute a 8-bit image from the projected gradients.

Private Attributes

int proj_n_
int width_
int k_size_
float * kernel_
int xstart_
int ystart_
int xsize_
int ysize_
vil1_memory_image_of< float > smooth_
float ** avg_
float ** grad0_
float ** grad45_
float ** grad90_
float ** grad135_
float ** det_
float ** dir_
vil1_memory_image_of< unsigned
char > 
det_image_
vil1_memory_image_of< unsigned
char > 
dir_image_
vil1_memory_image_of< float > image_
float * sup_proj_
float * proj_0_
float * proj_45_
float * proj_90_
float * proj_135_


Constructor & Destructor Documentation

brip_para_cvrg::brip_para_cvrg float  sigma = 1.0,
float  low = 6,
float  gauss_tail = .05,
int  proj_width = 7,
int  proj_height = 1,
int  sup_radius = 1,
bool  verbose = true
 

Constructor s.

Definition at line 55 of file brip_para_cvrg.cxx.

brip_para_cvrg::brip_para_cvrg brip_para_cvrg_params pdp  ) 
 

Definition at line 65 of file brip_para_cvrg.cxx.

brip_para_cvrg::~brip_para_cvrg  ) 
 

Destructor.

Definition at line 75 of file brip_para_cvrg.cxx.


Member Function Documentation

void brip_para_cvrg::avg int  x,
int  y,
vil1_memory_image_of< float > const &  smooth,
float **  avg
[private]
 

Compute the average value in the 7x7 window.

Definition at line 204 of file brip_para_cvrg.cxx.

void brip_para_cvrg::compute_gradients  )  [private]
 

Convolves with the kernel in the x direction, to compute the local derivative in that direction. Private.

Definition at line 272 of file brip_para_cvrg.cxx.

void brip_para_cvrg::compute_image float **  data,
vil1_memory_image_of< unsigned char > &  image
[private]
 

Compute a 8-bit image from the projected gradients.

Definition at line 531 of file brip_para_cvrg.cxx.

void brip_para_cvrg::compute_parallel_coverage  )  [private]
 

Find the direction with maximum parallel coverage. Return the normalized coverage value.

Definition at line 470 of file brip_para_cvrg.cxx.

void brip_para_cvrg::copy_image float **  ,
float ** 
[private]
 

Copies float image1 to image2. Private.

Definition at line 178 of file brip_para_cvrg.cxx.

void brip_para_cvrg::do_coverage vil1_image const &  image  ) 
 

Definition at line 554 of file brip_para_cvrg.cxx.

void brip_para_cvrg::free_float_image float **  image  )  [private]
 

Frees an m*n array of floats. Private.

Definition at line 115 of file brip_para_cvrg.cxx.

vil1_memory_image_of< vil1_rgb< unsigned char > > brip_para_cvrg::get_combined_image  ) 
 

Get the combination of coverage and direction as a color image.

Definition at line 612 of file brip_para_cvrg.cxx.

vil1_memory_image_of< unsigned char > brip_para_cvrg::get_detection_image  ) 
 

Get the unsigned char image of detections.

Definition at line 590 of file brip_para_cvrg.cxx.

vil1_memory_image_of< unsigned char > brip_para_cvrg::get_dir_image  ) 
 

Get the direction image (unsigned char).

Definition at line 601 of file brip_para_cvrg.cxx.

vil1_memory_image_of< float > brip_para_cvrg::get_float_detection_image const float  max = 255  ) 
 

Get the float image of detections. Scale onto [0, max].

Definition at line 567 of file brip_para_cvrg.cxx.

void brip_para_cvrg::grad0 int  x,
int  y,
vil1_memory_image_of< float > const &  smooth,
float **  grad0
[private]
 

Compute a gradient operator at x,y along the x axis.

Definition at line 219 of file brip_para_cvrg.cxx.

void brip_para_cvrg::grad135 int  x,
int  y,
vil1_memory_image_of< float > const &  smooth,
float **  grad135
[private]
 

Compute a gradient operator at x,y at 135 degrees.

Definition at line 257 of file brip_para_cvrg.cxx.

void brip_para_cvrg::grad45 int  x,
int  y,
vil1_memory_image_of< float > const &  smooth,
float **  grad45
[private]
 

Compute a gradient operator at x,y at 45 degrees.

Definition at line 232 of file brip_para_cvrg.cxx.

void brip_para_cvrg::grad90 int  x,
int  y,
vil1_memory_image_of< float > const &  smooth,
float **  grad90
[private]
 

Compute a gradient operator at x,y at 90 degrees.

Definition at line 245 of file brip_para_cvrg.cxx.

void brip_para_cvrg::init vil1_image const &  image  )  [private]
 

Image Initialization.

Definition at line 26 of file brip_para_cvrg.cxx.

void brip_para_cvrg::init_variables  )  [private]
 

Variable Initialization.

Definition at line 12 of file brip_para_cvrg.cxx.

float ** brip_para_cvrg::make_float_image int  m,
int  n
[private]
 

Returns an m*n array of floats. Private.

Definition at line 99 of file brip_para_cvrg.cxx.

float * brip_para_cvrg::make_float_vector int  size  )  [private]
 

Returns a vector of floats length m. Private.

Definition at line 127 of file brip_para_cvrg.cxx.

void brip_para_cvrg::non_maximum_supress float *  array,
float *  sup_array
[private]
 

Find locally maximum peaks in the input array.

Definition at line 417 of file brip_para_cvrg.cxx.

float brip_para_cvrg::parallel_coverage float *  sup_array  )  [private]
 

Find the amount of overlapping parallel coverage.

Definition at line 450 of file brip_para_cvrg.cxx.

float brip_para_cvrg::project int  x,
int  y,
int  dir,
float *  projection
[private]
 

Project the gradient magnitude along a given direction.

The result is a 1-d projection plot.

                       .
                      *  .
                     ^  *  .
                   /   ^  *  .
                    \    ^  *  .
                           ^  *  \ .
     2*proj_width_+1   x     ^  x-----2*proj_height_+1
                          \ / \ .
   

Definition at line 307 of file brip_para_cvrg.cxx.

void brip_para_cvrg::remove_flat_peaks int  n,
float *  array
[private]
 

Prune any sequences of more than one maximum value.

That is, it is possible to have a "flat" top peak with an arbitrarily long sequence of equal, but maximum values.

Definition at line 347 of file brip_para_cvrg.cxx.

bool brip_para_cvrg_params::SanityCheck  )  [inherited]
 

Checks that parameters are within acceptable bounds.

Definition at line 11 of file brip_para_cvrg_params.cxx.

void brip_para_cvrg::set_float_image float **  ,
float 
[private]
 

Sets a floating point image to val. Private.

Definition at line 146 of file brip_para_cvrg.cxx.

void brip_para_cvrg::set_float_vector float *  vector,
int  size,
float  val
[private]
 

Sets a floating point image to val. Private.

Definition at line 166 of file brip_para_cvrg.cxx.

void brip_para_cvrg::set_kernel  )  [private]
 

void brip_para_cvrg::smooth_image  )  [private]
 

Convolves the image with the smoothing kernel. Private.

Definition at line 194 of file brip_para_cvrg.cxx.


Member Data Documentation

float** brip_para_cvrg::avg_ [private]
 

Definition at line 92 of file brip_para_cvrg.h.

float** brip_para_cvrg::det_ [private]
 

Definition at line 97 of file brip_para_cvrg.h.

vil1_memory_image_of<unsigned char> brip_para_cvrg::det_image_ [private]
 

Definition at line 100 of file brip_para_cvrg.h.

float** brip_para_cvrg::dir_ [private]
 

Definition at line 98 of file brip_para_cvrg.h.

vil1_memory_image_of<unsigned char> brip_para_cvrg::dir_image_ [private]
 

Definition at line 102 of file brip_para_cvrg.h.

float brip_para_cvrg_params::gauss_tail_ [inherited]
 

Used in determining the convolution kernel.

Definition at line 39 of file brip_para_cvrg_params.h.

float** brip_para_cvrg::grad0_ [private]
 

Definition at line 93 of file brip_para_cvrg.h.

float** brip_para_cvrg::grad135_ [private]
 

Definition at line 96 of file brip_para_cvrg.h.

float** brip_para_cvrg::grad45_ [private]
 

Definition at line 94 of file brip_para_cvrg.h.

float** brip_para_cvrg::grad90_ [private]
 

Definition at line 95 of file brip_para_cvrg.h.

vil1_memory_image_of<float> brip_para_cvrg::image_ [private]
 

Definition at line 103 of file brip_para_cvrg.h.

int brip_para_cvrg::k_size_ [private]
 

Definition at line 86 of file brip_para_cvrg.h.

float* brip_para_cvrg::kernel_ [private]
 

Definition at line 87 of file brip_para_cvrg.h.

float* brip_para_cvrg::proj_0_ [private]
 

Definition at line 105 of file brip_para_cvrg.h.

float* brip_para_cvrg::proj_135_ [private]
 

Definition at line 108 of file brip_para_cvrg.h.

float* brip_para_cvrg::proj_45_ [private]
 

Definition at line 106 of file brip_para_cvrg.h.

float* brip_para_cvrg::proj_90_ [private]
 

Definition at line 107 of file brip_para_cvrg.h.

int brip_para_cvrg_params::proj_height_ [inherited]
 

1/2 the projection region height

Definition at line 41 of file brip_para_cvrg_params.h.

int brip_para_cvrg::proj_n_ [private]
 

Definition at line 84 of file brip_para_cvrg.h.

int brip_para_cvrg_params::proj_width_ [inherited]
 

1/2 the projection region width

Definition at line 40 of file brip_para_cvrg_params.h.

float brip_para_cvrg_params::sigma_ [inherited]
 

Standard deviation of the smoothing kernel.

Definition at line 37 of file brip_para_cvrg_params.h.

vil1_memory_image_of<float> brip_para_cvrg::smooth_ [private]
 

Definition at line 91 of file brip_para_cvrg.h.

float* brip_para_cvrg::sup_proj_ [private]
 

Definition at line 104 of file brip_para_cvrg.h.

int brip_para_cvrg_params::sup_radius_ [inherited]
 

The non_maximum suppression kernel width.

Definition at line 42 of file brip_para_cvrg_params.h.

float brip_para_cvrg_params::thresh_ [inherited]
 

Low hysteresis threshold.

Definition at line 38 of file brip_para_cvrg_params.h.

bool brip_para_cvrg_params::verbose_ [inherited]
 

output debug messages

Definition at line 43 of file brip_para_cvrg_params.h.

int brip_para_cvrg::width_ [private]
 

Definition at line 85 of file brip_para_cvrg.h.

int brip_para_cvrg::xsize_ [private]
 

Definition at line 90 of file brip_para_cvrg.h.

int brip_para_cvrg::xstart_ [private]
 

Definition at line 89 of file brip_para_cvrg.h.

int brip_para_cvrg::ysize_ [private]
 

Definition at line 90 of file brip_para_cvrg.h.

int brip_para_cvrg::ystart_ [private]
 

Definition at line 89 of file brip_para_cvrg.h.


The documentation for this class was generated from the following files:
Generated on Thu Jan 10 14:52:31 2008 for contrib/brl/bseg/brip by  doxygen 1.4.4