Public Member Functions | Public Attributes | Protected Member Functions | Private Attributes
clsfy_quad_regulariser Class Reference

Simple quadratic term used to regularise functions. More...

#include <clsfy_logit_loss_function.h>

Inheritance diagram for clsfy_quad_regulariser:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 clsfy_quad_regulariser (double alpha=1e-6)
virtual double f (vnl_vector< double > const &v)
 The main function: Compute f(v).
virtual void gradf (vnl_vector< double > const &v, vnl_vector< double > &gradient)
 Calculate the gradient of f at parameter vector v.
vnl_vector< double > gradf (vnl_vector< double > const &x)
virtual void compute (vnl_vector< double > const &x, double *f, vnl_vector< double > *g)
int get_number_of_unknowns () const
void fdgradf (vnl_vector< double > const &x, vnl_vector< double > &gradient, double stepsize=1e-5)
vnl_vector< double > fdgradf (vnl_vector< double > const &x)
virtual double reported_error (double f_value)
virtual double get_range_min () const
virtual double get_range_max () const
virtual vnl_unary_function
< double, vnl_vector< double > > * 
Copy () const

Public Attributes

int dim

Protected Member Functions

void set_number_of_unknowns (int number_of_unknowns)

Private Attributes

double alpha_
 Scaling factor.

Detailed Description

Simple quadratic term used to regularise functions.

For vector v' = (b w') (ie b=y[0], w=(y[1]...y[n])), computes f(v) = alpha*|w|^2 (ie ignores first element, which is bias of linear classifier)

Definition at line 56 of file clsfy_logit_loss_function.h.


Constructor & Destructor Documentation

clsfy_quad_regulariser::clsfy_quad_regulariser ( double  alpha = 1e-6)

Definition at line 122 of file clsfy_logit_loss_function.cxx.


Member Function Documentation

double clsfy_quad_regulariser::f ( vnl_vector< double > const &  v) [virtual]

The main function: Compute f(v).

Reimplemented from vnl_cost_function.

Definition at line 128 of file clsfy_logit_loss_function.cxx.

void clsfy_quad_regulariser::gradf ( vnl_vector< double > const &  v,
vnl_vector< double > &  gradient 
) [virtual]

Calculate the gradient of f at parameter vector v.

Reimplemented from vnl_cost_function.

Definition at line 136 of file clsfy_logit_loss_function.cxx.


Member Data Documentation

Scaling factor.

Definition at line 60 of file clsfy_logit_loss_function.h.


The documentation for this class was generated from the following files: