Classes | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
Solver Class Reference
Inheritance diagram for Solver:
Inheritance graph
[legend]

Classes

struct  SolutionInfo
 

Public Member Functions

void Solve (int l, const QMatrix &Q, const double *p_, const schar *y_, double *alpha_, double Cp, double Cn, double eps, SolutionInfo *si, int shrinking)
 
 Solver ()
 
virtual ~Solver ()
 

Protected Types

enum  { LOWER_BOUND, UPPER_BOUND, FREE }
 

Protected Member Functions

virtual double calculate_rho ()
 
virtual void do_shrinking ()
 
double get_C (int i)
 
bool is_free (int i)
 
bool is_lower_bound (int i)
 
bool is_upper_bound (int i)
 
void reconstruct_gradient ()
 
virtual int select_working_set (int &i, int &j)
 
void swap_index (int i, int j)
 
void update_alpha_status (int i)
 

Protected Attributes

int * active_set
 
int active_size
 
double * alpha
 
char * alpha_status
 
double Cn
 
double Cp
 
double eps
 
double * G
 
double * G_bar
 
int l
 
double * p
 
const QMatrixQ
 
const double * QD
 
bool unshrink
 
schary
 

Private Member Functions

bool be_shrunk (int i, double Gmax1, double Gmax2)
 

Detailed Description

Definition at line 406 of file svm.cpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protected
Enumerator
LOWER_BOUND 
UPPER_BOUND 
FREE 

Definition at line 428 of file svm.cpp.

Constructor & Destructor Documentation

◆ Solver()

Solver::Solver ( )
inline

Definition at line 409 of file svm.cpp.

◆ ~Solver()

virtual Solver::~Solver ( )
inlinevirtual

Definition at line 410 of file svm.cpp.

Member Function Documentation

◆ be_shrunk()

bool Solver::be_shrunk ( int  i,
double  Gmax1,
double  Gmax2 
)
private

Definition at line 909 of file svm.cpp.

◆ calculate_rho()

double Solver::calculate_rho ( )
protectedvirtual

Reimplemented in Solver_NU.

Definition at line 990 of file svm.cpp.

◆ do_shrinking()

void Solver::do_shrinking ( )
protectedvirtual

Reimplemented in Solver_NU.

Definition at line 929 of file svm.cpp.

◆ get_C()

double Solver::get_C ( int  i)
inlineprotected

Definition at line 441 of file svm.cpp.

◆ is_free()

bool Solver::is_free ( int  i)
inlineprotected

Definition at line 461 of file svm.cpp.

◆ is_lower_bound()

bool Solver::is_lower_bound ( int  i)
inlineprotected

Definition at line 457 of file svm.cpp.

◆ is_upper_bound()

bool Solver::is_upper_bound ( int  i)
inlineprotected

Definition at line 453 of file svm.cpp.

◆ reconstruct_gradient()

void Solver::reconstruct_gradient ( )
protected

Definition at line 486 of file svm.cpp.

◆ select_working_set()

int Solver::select_working_set ( int &  i,
int &  j 
)
protectedvirtual

Reimplemented in Solver_NU.

Definition at line 810 of file svm.cpp.

◆ Solve()

void Solver::Solve ( int  l,
const QMatrix Q,
const double *  p_,
const schar y_,
double *  alpha_,
double  Cp,
double  Cn,
double  eps,
SolutionInfo si,
int  shrinking 
)

Definition at line 528 of file svm.cpp.

◆ swap_index()

void Solver::swap_index ( int  i,
int  j 
)
protected

Definition at line 474 of file svm.cpp.

◆ update_alpha_status()

void Solver::update_alpha_status ( int  i)
inlineprotected

Definition at line 445 of file svm.cpp.

Member Data Documentation

◆ active_set

int* Solver::active_set
protected

Definition at line 436 of file svm.cpp.

◆ active_size

int Solver::active_size
protected

Definition at line 425 of file svm.cpp.

◆ alpha

double* Solver::alpha
protected

Definition at line 430 of file svm.cpp.

◆ alpha_status

char* Solver::alpha_status
protected

Definition at line 429 of file svm.cpp.

◆ Cn

double Solver::Cn
protected

Definition at line 434 of file svm.cpp.

◆ Cp

double Solver::Cp
protected

Definition at line 434 of file svm.cpp.

◆ eps

double Solver::eps
protected

Definition at line 433 of file svm.cpp.

◆ G

double* Solver::G
protected

Definition at line 427 of file svm.cpp.

◆ G_bar

double* Solver::G_bar
protected

Definition at line 437 of file svm.cpp.

◆ l

int Solver::l
protected

Definition at line 438 of file svm.cpp.

◆ p

double* Solver::p
protected

Definition at line 435 of file svm.cpp.

◆ Q

const QMatrix* Solver::Q
protected

Definition at line 431 of file svm.cpp.

◆ QD

const double* Solver::QD
protected

Definition at line 432 of file svm.cpp.

◆ unshrink

bool Solver::unshrink
protected

Definition at line 439 of file svm.cpp.

◆ y

schar* Solver::y
protected

Definition at line 426 of file svm.cpp.


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


ml_classifiers
Author(s): Scott Niekum , Joshua Whitley
autogenerated on Mon Feb 28 2022 22:46:49