mimas::pgh Class Reference

Pairwise geometric histograms. More...

#include <pgh.h>

Inheritance diagram for mimas::pgh:

Inheritance graph
[legend]
Collaboration diagram for mimas::pgh:

Collaboration graph
[legend]
List of all members.

Public Types

typedef boost::numeric::ublas::vector<
double
Vector
 < ??

Public Member Functions

 pgh (void)
 ~pgh (void)
void initialise (pgh_type newpairs_type, double newdbin_max, double newdbin_size, double newdist_ramp, int newnum_abin, double newangle_sigma)
void initialise (void)
void describeLine (const line &ref_line, const line_ptr_list &l)
void init_pairs_entry (void)
bool adjust_for_distance_ramp (double *weight, double *min_d, double *max_d, double dbin_min, double dist_ramp)
void build_normalized_pairwise (const line &ref_line, const line_ptr_list &geom)
void compare_lines (const line &refline, const line &line)
void compare_lines_mirror (const line &l1, const line &l2)
void make_entry_mirror (double min_d, double max_d, double angle, double weight)
void make_entry_rotate (double min_d, double max_d, double angle, double weight)
void compare_lines_rotate (const line &l1, const line &l2)
void make_entry_directed (double min_d, double max_d, double angle, double weight)
void make_entry_direct (double min_d, double max_d, double angle, double weight)
void compare_lines_directed (const line &l1, const line &l2)
Vector dir_vec (const Vector &isct, const Vector &p1, const Vector &p2)
void get_pdist (double *pdist, double pdmin, double pdmax, double bin_width, double ramp, int *low_bin, int *high_bin)
void sqr_root_and_normalize (void)

Protected Attributes

pgh_type pairs_type
 specifies the encoding used to create the histogram
double dbin_max
double dbin_min
 distance range which the histogram spans
double dbin_size
double dist_ramp
 range of each histogram bin wrt distance, number of angle bins in hist
int num_abin
double angle_sigma
double abin_size
 range of each angle bin, sigma= angle m'ment error estimate
doublepair_dist
doublereal_pair_dist
 ??
doublepair_angle
doublereal_pair_angle

Detailed Description

Pairwise geometric histograms.

Pairwise geometric histograms. see the many papers by Evans,Thacker,Ashbrook and Caparrelli This flaky implementation by stuart meikle 22.02.2000, based on original Tina tool source code.

A pairwise geometric histogram is a special kind of hough transform. Much of the code here was taken from Tina, and modified to cope with the new base classes. Its easy enough to use, just do

    pgh my_pgh;
    my_pgh.initialise(); my_pgh.describeLine( ref_line, set_of_lines );
which will create a pgh for that line. You should add extra code to set the parameters used during creation. There probably shouldn't be an erf array allocated for every Pgh ! oops. To fix this make the variable instance a static so that only one is used for all instances of pgh. Also please note that the 'directed' kind of histogram is now formed correctly unlike in Tina. Also i think there should be a warning somewher ein the creation process to say : Hang about mate, you've given me an object which is 500x500 and you want me to use histograms with a max distance axis of 50? Ie the histogram should scale with the model. Because the pgh is an image type, to do a bhattacharyya comparison between two do:
    pgh p1,p2;
    // ... enter values into p1 and p2 ...
    p1.sqr_root_and_normalize(); 
    p2.sqr_root_and_normalize(); 
    result =p1.dotProduct(p2);

Definition at line 58 of file pgh.h.


Member Typedef Documentation

typedef boost::numeric::ublas::vector< double > mimas::pgh::Vector

< ??

Reimplemented from mimas::hough_transform.

Definition at line 79 of file pgh.h.


Constructor & Destructor Documentation

mimas::pgh::pgh ( void   ) 

mimas::pgh::~pgh ( void   ) 


Member Function Documentation

void mimas::pgh::initialise ( pgh_type  newpairs_type,
double  newdbin_max,
double  newdbin_size,
double  newdist_ramp,
int  newnum_abin,
double  newangle_sigma 
)

void mimas::pgh::initialise ( void   ) 

void mimas::pgh::describeLine ( const line ref_line,
const line_ptr_list l 
)

void mimas::pgh::init_pairs_entry ( void   ) 

bool mimas::pgh::adjust_for_distance_ramp ( double weight,
double min_d,
double max_d,
double  dbin_min,
double  dist_ramp 
)

void mimas::pgh::build_normalized_pairwise ( const line ref_line,
const line_ptr_list geom 
)

void mimas::pgh::compare_lines ( const line refline,
const line line 
)

void mimas::pgh::compare_lines_mirror ( const line l1,
const line l2 
)

void mimas::pgh::make_entry_mirror ( double  min_d,
double  max_d,
double  angle,
double  weight 
)

void mimas::pgh::make_entry_rotate ( double  min_d,
double  max_d,
double  angle,
double  weight 
)

void mimas::pgh::compare_lines_rotate ( const line l1,
const line l2 
)

void mimas::pgh::make_entry_directed ( double  min_d,
double  max_d,
double  angle,
double  weight 
)

void mimas::pgh::make_entry_direct ( double  min_d,
double  max_d,
double  angle,
double  weight 
)

void mimas::pgh::compare_lines_directed ( const line l1,
const line l2 
)

Vector mimas::pgh::dir_vec ( const Vector isct,
const Vector p1,
const Vector p2 
)

void mimas::pgh::get_pdist ( double pdist,
double  pdmin,
double  pdmax,
double  bin_width,
double  ramp,
int low_bin,
int high_bin 
)

void mimas::pgh::sqr_root_and_normalize ( void   ) 


Member Data Documentation

pgh_type mimas::pgh::pairs_type [protected]

specifies the encoding used to create the histogram

Definition at line 69 of file pgh.h.

double mimas::pgh::dbin_max [protected]

Definition at line 70 of file pgh.h.

double mimas::pgh::dbin_min [protected]

distance range which the histogram spans

Definition at line 70 of file pgh.h.

double mimas::pgh::dbin_size [protected]

Definition at line 71 of file pgh.h.

double mimas::pgh::dist_ramp [protected]

range of each histogram bin wrt distance, number of angle bins in hist

Definition at line 71 of file pgh.h.

int mimas::pgh::num_abin [protected]

Definition at line 72 of file pgh.h.

double mimas::pgh::angle_sigma [protected]

Definition at line 73 of file pgh.h.

double mimas::pgh::abin_size [protected]

range of each angle bin, sigma= angle m'ment error estimate

Definition at line 73 of file pgh.h.

double* mimas::pgh::pair_dist [protected]

Definition at line 74 of file pgh.h.

double * mimas::pgh::real_pair_dist [protected]

??

Definition at line 74 of file pgh.h.

double* mimas::pgh::pair_angle [protected]

Definition at line 75 of file pgh.h.

double * mimas::pgh::real_pair_angle [protected]

Definition at line 75 of file pgh.h.


The documentation for this class was generated from the following file:
[GNU/Linux] [Qt] [Mesa] [STL] [Lapack] [Boost] [Magick++] [Xalan-C and Xerces-C] [doxygen] [graphviz] [FFTW] [popt] [xine] [Gnuplot] [gnu-arch] [gcc] [gstreamer] [autoconf/automake/make] [freshmeat.net] [opensource.org] [sourceforge.net] [MMVL]
mimas 2.1 - Copyright Mon Oct 30 11:31:41 2006, Bala Amavasai, Stuart Meikle, Arul Selvan, Fabio Caparrelli, Jan Wedekind, Manuel Boissenin, ...