Medial Code Documentation
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
PredictiveModel Class Referenceabstract

Predictive Model is abstract class of predictor model which has parameters for GD or SGD uses it also has function to retrieve direct sub-gradients for the loss function of the model. More...

#include <PredictiveModel.h>

Inheritance diagram for PredictiveModel:
MedLinearModel

Public Member Functions

 PredictiveModel (string name)
 The name of the model.
 
virtual double predict (const vector< float > &input) const =0
 
virtual subGradientFunction getSubGradients ()
 Subgradient function to calc directly the gradient descent.
 
virtual void predict (const vector< vector< float > > &inputs, vector< double > &preds) const
 virtual to allow more efficeint implemention
 
virtual void print (const vector< string > &signalNames) const =0
 print model to stdout
 
virtual PredictiveModelclone () const =0
 copy model
 

Data Fields

vector< double > model_params
 model parameters
 
string model_name
 model name
 

Detailed Description

Predictive Model is abstract class of predictor model which has parameters for GD or SGD uses it also has function to retrieve direct sub-gradients for the loss function of the model.

Member Function Documentation

◆ clone()

virtual PredictiveModel * PredictiveModel::clone ( ) const
pure virtual

copy model

Implemented in MedLinearModel.

◆ getSubGradients()

subGradientFunction PredictiveModel::getSubGradients ( )
virtual

Subgradient function to calc directly the gradient descent.

Reimplemented in MedLinearModel.

◆ predict()

void PredictiveModel::predict ( const vector< vector< float > > &  inputs,
vector< double > &  preds 
) const
virtual

virtual to allow more efficeint implemention

Reimplemented in MedLinearModel.

◆ print()

virtual void PredictiveModel::print ( const vector< string > &  signalNames) const
pure virtual

print model to stdout

Implemented in MedLinearModel.


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