#include <rgrl_weighter_indiv_scale.h>
Public Member Functions | |
rgrl_weighter_indiv_scale (vcl_auto_ptr< rrel_m_est_obj > m_est, bool use_signature_error, bool use_precomputed_signature_wgt=false) | |
constructor takes a pointer to M estimator objective function. | |
~rgrl_weighter_indiv_scale () | |
virtual void | compute_weights (rgrl_scale const &scale, rgrl_match_set &match_set) const |
based on the scales, compute the weights for the matches. | |
rgrl_type_macro (rgrl_weighter_indiv_scale, rgrl_weighter_m_est) | |
virtual double | aux_sum_rho_values (rgrl_scale const &scale, rgrl_match_set &match_set, rgrl_transformation const &xform) |
void | set_weight_more_on_distinct_match (bool flag) |
set true if desires to weight more on distinct match. | |
rgrl_type_macro (rgrl_weighter_m_est, rgrl_weighter) | |
rgrl_type_macro (rgrl_weighter, rgrl_object) | |
virtual double | aux_sum_weighted_residuals (rgrl_scale const &scale, rgrl_match_set &match_set, rgrl_transformation const &xform) |
virtual double | aux_neg_log_likelihood (rgrl_scale const &scale, rgrl_match_set &match_set, rgrl_transformation const &xform) |
virtual double | aux_avg_neg_log_likelihood (rgrl_scale const &scale, rgrl_match_set &match_set, rgrl_transformation const &xform) |
virtual bool | is_type (const vcl_type_info &type) const |
void | set_debug_flag (unsigned int debugFlag) const |
Set the value of the debug flag. A non-zero value turns debugging on. | |
unsigned int | debug_flag () const |
Get the value of the debug flag. | |
void | set_warning (bool) const |
Set the flag for warning messages. | |
bool | warning () const |
Get the warning flag. | |
unsigned int | add_observer (rgrl_event_sptr event, rgrl_command_sptr) |
Allow people to add/remove/invoke observers (callbacks) to any rgrl object. | |
rgrl_command_sptr | get_command (unsigned int tag) |
Get the command associated with the given tag. | |
void | invoke_event (const rgrl_event &) |
Call execute(.) on all the rgrl_commands observing this event id. | |
void | invoke_event (const rgrl_event &) const |
Call execute(.) on all the rgrl_commands observing this event id. | |
void | remove_observer (unsigned int tag) |
Remove the observer with this tag value. | |
bool | has_observer (const rgrl_event &event) const |
Return true if an observer is registered for this event. | |
void | ref () |
void | unref () |
int | get_references () const |
bool | is_referenced () const |
Static Public Member Functions | |
static const vcl_type_info & | type_id () |
Protected Attributes | |
vcl_auto_ptr< rrel_m_est_obj > | m_est_ |
bool | use_signature_error_ |
bool | signature_precomputed_ |
bool | weight_more_on_distinct_match_ |
Definition at line 22 of file rgrl_weighter_indiv_scale.h.
rgrl_weighter_indiv_scale::rgrl_weighter_indiv_scale | ( | vcl_auto_ptr< rrel_m_est_obj > | m_est, |
bool | use_signature_error, | ||
bool | use_precomputed_signature_wgt = false |
||
) |
constructor takes a pointer to M estimator objective function.
Definition at line 17 of file rgrl_weighter_indiv_scale.cxx.
rgrl_weighter_indiv_scale::~rgrl_weighter_indiv_scale | ( | ) |
Definition at line 26 of file rgrl_weighter_indiv_scale.cxx.
unsigned int rgrl_object::add_observer | ( | rgrl_event_sptr | event, |
rgrl_command_sptr | cmd | ||
) | [inherited] |
Allow people to add/remove/invoke observers (callbacks) to any rgrl object.
This is an implementation of the subject/observer design pattern. An observer is added by specifying an event to respond to and an rgrl_command to execute. It returns an unsigned long tag which can be used later to remove the event or retrieve the command.
Definition at line 47 of file rgrl_object.cxx.
double rgrl_weighter_m_est::aux_avg_neg_log_likelihood | ( | rgrl_scale const & | scale, |
rgrl_match_set & | match_set, | ||
rgrl_transformation const & | xform | ||
) | [virtual, inherited] |
Reimplemented from rgrl_weighter.
Definition at line 238 of file rgrl_weighter_m_est.cxx.
double rgrl_weighter_m_est::aux_neg_log_likelihood | ( | rgrl_scale const & | scale, |
rgrl_match_set & | match_set, | ||
rgrl_transformation const & | xform | ||
) | [virtual, inherited] |
Reimplemented from rgrl_weighter.
Definition at line 215 of file rgrl_weighter_m_est.cxx.
double rgrl_weighter_indiv_scale::aux_sum_rho_values | ( | rgrl_scale const & | scale, |
rgrl_match_set & | match_set, | ||
rgrl_transformation const & | xform | ||
) | [virtual] |
Reimplemented from rgrl_weighter_m_est.
Definition at line 133 of file rgrl_weighter_indiv_scale.cxx.
double rgrl_weighter_m_est::aux_sum_weighted_residuals | ( | rgrl_scale const & | scale, |
rgrl_match_set & | match_set, | ||
rgrl_transformation const & | xform | ||
) | [virtual, inherited] |
Reimplemented from rgrl_weighter.
Definition at line 133 of file rgrl_weighter_m_est.cxx.
void rgrl_weighter_indiv_scale::compute_weights | ( | rgrl_scale const & | scales, |
rgrl_match_set & | match_set | ||
) | const [virtual] |
based on the scales, compute the weights for the matches.
The resulting weights will be stored in the match_set structure.
Reimplemented from rgrl_weighter_m_est.
Definition at line 33 of file rgrl_weighter_indiv_scale.cxx.
unsigned int rgrl_object::debug_flag | ( | ) | const [inherited] |
Get the value of the debug flag.
Definition at line 26 of file rgrl_object.cxx.
rgrl_command_sptr rgrl_object::get_command | ( | unsigned int | tag | ) | [inherited] |
Get the command associated with the given tag.
Definition at line 57 of file rgrl_object.cxx.
bool rgrl_object::has_observer | ( | const rgrl_event & | event | ) | const [inherited] |
Return true if an observer is registered for this event.
Definition at line 107 of file rgrl_object.cxx.
void rgrl_object::invoke_event | ( | const rgrl_event & | event | ) | [inherited] |
Call execute(.) on all the rgrl_commands observing this event id.
Definition at line 69 of file rgrl_object.cxx.
void rgrl_object::invoke_event | ( | const rgrl_event & | event | ) | const [inherited] |
Call execute(.) on all the rgrl_commands observing this event id.
The actions triggered by this call doesn't modify this object.
Definition at line 83 of file rgrl_object.cxx.
virtual bool rgrl_object::is_type | ( | const vcl_type_info & | type | ) | const [inline, virtual, inherited] |
Reimplemented in rgrl_scale_estimator.
Definition at line 66 of file rgrl_object.h.
void rgrl_object::remove_observer | ( | unsigned int | tag | ) | [inherited] |
Remove the observer with this tag value.
Definition at line 97 of file rgrl_object.cxx.
rgrl_weighter::rgrl_type_macro | ( | rgrl_weighter | , |
rgrl_object | |||
) | [inherited] |
rgrl_weighter_indiv_scale::rgrl_type_macro | ( | rgrl_weighter_indiv_scale | , |
rgrl_weighter_m_est | |||
) |
rgrl_weighter_m_est::rgrl_type_macro | ( | rgrl_weighter_m_est | , |
rgrl_weighter | |||
) | [inherited] |
void rgrl_object::set_debug_flag | ( | unsigned int | debugFlag | ) | const [inherited] |
Set the value of the debug flag. A non-zero value turns debugging on.
Definition at line 19 of file rgrl_object.cxx.
void rgrl_object::set_warning | ( | bool | flag | ) | const [inherited] |
Set the flag for warning messages.
Definition at line 33 of file rgrl_object.cxx.
void rgrl_weighter_m_est::set_weight_more_on_distinct_match | ( | bool | flag | ) | [inline, inherited] |
set true if desires to weight more on distinct match.
Definition at line 41 of file rgrl_weighter_m_est.h.
static const vcl_type_info& rgrl_object::type_id | ( | ) | [inline, static, inherited] |
Reimplemented in rgrl_scale_estimator.
Definition at line 63 of file rgrl_object.h.
bool rgrl_object::warning | ( | ) | const [inherited] |
Get the warning flag.
Definition at line 40 of file rgrl_object.cxx.
vcl_auto_ptr<rrel_m_est_obj> rgrl_weighter_m_est::m_est_ [protected, inherited] |
Definition at line 76 of file rgrl_weighter_m_est.h.
bool rgrl_weighter_m_est::signature_precomputed_ [protected, inherited] |
Definition at line 78 of file rgrl_weighter_m_est.h.
bool rgrl_weighter_m_est::use_signature_error_ [protected, inherited] |
Definition at line 77 of file rgrl_weighter_m_est.h.
bool rgrl_weighter_m_est::weight_more_on_distinct_match_ [protected, inherited] |
Definition at line 79 of file rgrl_weighter_m_est.h.