#include <bsta_joint_histogram.h>
Public Types | |
enum | bsta_joint_hist_type { HIST_TYPE_UNKNOWN = 0, HIST_TYPE_FLOAT = 1, HIST_TYPE_DOUBLE = 2, HIST_TYPE_END = 3 } |
Public Member Functions | |
bsta_joint_histogram () | |
bsta_joint_histogram (const T range, const unsigned int nbins, const T min_prob=0.0) | |
bsta_joint_histogram (const T range_a, const unsigned int nbins_a, const T range_b, const unsigned int nbins_b, const T min_prob=0.0) | |
bsta_joint_histogram (const T min_a, const T max_a, const unsigned int nbins_a, const T min_b, const T max_b, const unsigned int nbins_b, const T min_prob=0.0) | |
More general constructor defining a signed value range. | |
~bsta_joint_histogram () | |
unsigned int | nbins () const |
legacy use where a and b have the same bin granularity. | |
unsigned int | nbins_a () const |
number of bins for variable a. | |
unsigned int | nbins_b () const |
number of bins for variable b. | |
T | range () const |
legacy use where a and b have the same range. | |
T | range_a () const |
range for variable a. | |
T | range_b () const |
range for variable b. | |
T | min_a () const |
min value for variable a. | |
T | max_a () const |
max value for variable a. | |
T | min_b () const |
min value for variable b. | |
T | max_b () const |
max value for variable b. | |
T | delta_a () const |
delta value for variable a. | |
T | delta_b () const |
delta value for variable b. | |
T | min_prob () const |
vbl_array_2d< T > | counts () const |
void | upcount (T a, T mag_a, T b, T mag_b) |
void | parzen (const T sigma) |
T | p (unsigned int a, unsigned int b) const |
access by bin index. | |
T | p (T a, T b) const |
access by value. | |
T | volume () const |
T | entropy () const |
T | mutual_information () const |
T | renyi_entropy () const |
T | entropy_marginal_a () const |
void | print (vcl_ostream &os=vcl_cout) const |
bool | avg_and_variance_bin_for_row_a (const unsigned int a, T &avg, T &var) const |
The average and variance bin value for row a using counts to compute probs. | |
void | set_count (unsigned r, unsigned c, T cnt) |
T | get_count (unsigned r, unsigned c) const |
access by index. | |
T | get_count (T a, T b) const |
access by value. | |
void | print_to_vrml (vcl_ostream &os) const |
void | print_to_m (vcl_ostream &os) const |
void | print_to_text (vcl_ostream &os) const |
void | clear () |
restore to default constructor state. | |
void | ref () |
void | unref () |
int | get_references () const |
bool | is_referenced () const |
Public Attributes | |
bsta_joint_hist_type | type_ |
Private Member Functions | |
void | compute_volume () const |
Private Attributes | |
bool | volume_valid_ |
T | volume_ |
unsigned int | nbins_a_ |
unsigned int | nbins_b_ |
T | range_a_ |
T | range_b_ |
T | delta_a_ |
T | delta_b_ |
T | min_a_ |
T | max_a_ |
T | min_b_ |
T | max_b_ |
T | min_prob_ |
vbl_array_2d< T > | counts_ |
Definition at line 24 of file bsta_joint_histogram.h.
enum bsta_joint_histogram_base::bsta_joint_hist_type [inherited] |
Definition at line 17 of file bsta_joint_histogram_base.h.
bsta_joint_histogram< T >::bsta_joint_histogram | ( | ) |
Definition at line 12 of file bsta_joint_histogram.txx.
bsta_joint_histogram< T >::bsta_joint_histogram | ( | const T | range, |
const unsigned int | nbins, | ||
const T | min_prob = 0.0 |
||
) |
Definition at line 26 of file bsta_joint_histogram.txx.
bsta_joint_histogram< T >::bsta_joint_histogram | ( | const T | range_a, |
const unsigned int | nbins_a, | ||
const T | range_b, | ||
const unsigned int | nbins_b, | ||
const T | min_prob = 0.0 |
||
) |
Definition at line 43 of file bsta_joint_histogram.txx.
bsta_joint_histogram< T >::bsta_joint_histogram | ( | const T | min_a, |
const T | max_a, | ||
const unsigned int | nbins_a, | ||
const T | min_b, | ||
const T | max_b, | ||
const unsigned int | nbins_b, | ||
const T | min_prob = 0.0 |
||
) |
More general constructor defining a signed value range.
Definition at line 62 of file bsta_joint_histogram.txx.
bsta_joint_histogram< T >::~bsta_joint_histogram | ( | ) | [inline] |
Definition at line 42 of file bsta_joint_histogram.h.
bool bsta_joint_histogram< T >::avg_and_variance_bin_for_row_a | ( | const unsigned int | a, |
T & | avg, | ||
T & | var | ||
) | const |
The average and variance bin value for row a using counts to compute probs.
T avg_and_variance_bin_for_row_a(const unsigned int a) const;
Definition at line 176 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::clear | ( | ) |
restore to default constructor state.
Definition at line 315 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::compute_volume | ( | ) | const [private] |
Definition at line 118 of file bsta_joint_histogram.txx.
vbl_array_2d<T> bsta_joint_histogram< T >::counts | ( | ) | const [inline] |
Definition at line 74 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::delta_a | ( | ) | const [inline] |
delta value for variable a.
Definition at line 68 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::delta_b | ( | ) | const [inline] |
delta value for variable b.
Definition at line 70 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::entropy | ( | ) | const |
Definition at line 210 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::entropy_marginal_a | ( | ) | const |
Definition at line 266 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::get_count | ( | unsigned | r, |
unsigned | c | ||
) | const [inline] |
access by index.
Definition at line 104 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::get_count | ( | T | a, |
T | b | ||
) | const |
access by value.
Definition at line 306 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::max_a | ( | ) | const [inline] |
max value for variable a.
Definition at line 62 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::max_b | ( | ) | const [inline] |
max value for variable b.
Definition at line 66 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_a | ( | ) | const [inline] |
min value for variable a.
Definition at line 60 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_b | ( | ) | const [inline] |
min value for variable b.
Definition at line 64 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_prob | ( | ) | const [inline] |
Definition at line 72 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::mutual_information | ( | ) | const |
Definition at line 225 of file bsta_joint_histogram.txx.
unsigned int bsta_joint_histogram< T >::nbins | ( | ) | const [inline] |
legacy use where a and b have the same bin granularity.
Definition at line 45 of file bsta_joint_histogram.h.
unsigned int bsta_joint_histogram< T >::nbins_a | ( | ) | const [inline] |
number of bins for variable a.
Definition at line 48 of file bsta_joint_histogram.h.
unsigned int bsta_joint_histogram< T >::nbins_b | ( | ) | const [inline] |
number of bins for variable b.
Definition at line 50 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::p | ( | unsigned int | a, |
unsigned int | b | ||
) | const |
access by bin index.
Definition at line 128 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::p | ( | T | a, |
T | b | ||
) | const |
access by value.
Definition at line 143 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::parzen | ( | const T | sigma | ) |
Definition at line 288 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::print | ( | vcl_ostream & | os = vcl_cout | ) | const |
Definition at line 323 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::print_to_m | ( | vcl_ostream & | os | ) | const |
Definition at line 417 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::print_to_text | ( | vcl_ostream & | os | ) | const |
Definition at line 434 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::print_to_vrml | ( | vcl_ostream & | os | ) | const |
Definition at line 332 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::range | ( | ) | const [inline] |
legacy use where a and b have the same range.
Definition at line 53 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::range_a | ( | ) | const [inline] |
range for variable a.
Definition at line 56 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::range_b | ( | ) | const [inline] |
range for variable b.
Definition at line 58 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::renyi_entropy | ( | ) | const |
Definition at line 251 of file bsta_joint_histogram.txx.
void bsta_joint_histogram< T >::set_count | ( | unsigned | r, |
unsigned | c, | ||
T | cnt | ||
) | [inline] |
Definition at line 97 of file bsta_joint_histogram.h.
void bsta_joint_histogram< T >::upcount | ( | T | a, |
T | mag_a, | ||
T | b, | ||
T | mag_b | ||
) |
Definition at line 91 of file bsta_joint_histogram.txx.
T bsta_joint_histogram< T >::volume | ( | ) | const |
Definition at line 202 of file bsta_joint_histogram.txx.
vbl_array_2d<T> bsta_joint_histogram< T >::counts_ [private] |
Definition at line 131 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::delta_a_ [private] |
Definition at line 127 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::delta_b_ [private] |
Definition at line 127 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::max_a_ [private] |
Definition at line 128 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::max_b_ [private] |
Definition at line 129 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_a_ [private] |
Definition at line 128 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_b_ [private] |
Definition at line 129 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::min_prob_ [private] |
Definition at line 130 of file bsta_joint_histogram.h.
unsigned int bsta_joint_histogram< T >::nbins_a_ [private] |
Definition at line 125 of file bsta_joint_histogram.h.
unsigned int bsta_joint_histogram< T >::nbins_b_ [private] |
Definition at line 125 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::range_a_ [private] |
Definition at line 126 of file bsta_joint_histogram.h.
T bsta_joint_histogram< T >::range_b_ [private] |
Definition at line 126 of file bsta_joint_histogram.h.
bsta_joint_hist_type bsta_joint_histogram_base::type_ [inherited] |
Definition at line 27 of file bsta_joint_histogram_base.h.
T bsta_joint_histogram< T >::volume_ [mutable, private] |
Definition at line 124 of file bsta_joint_histogram.h.
bool bsta_joint_histogram< T >::volume_valid_ [mutable, private] |
Definition at line 123 of file bsta_joint_histogram.h.