CVB++ 14.0
PredictorBase Class Reference

Base class for Polimago predictors. More...

#include <cvb/polimago/predictor_base.hpp>

Inherits PolimagoFactoryCreatedObject.

Inherited by PredictorBaseEx, and SearchPredictor.

Public Member Functions

bool IsCompatible (const Image &img, Point2D< int > pos) const
 Verify the compatibility of a CVB image with this classifier. More...
 
bool IsCompatible (const Image &img) const
 Verify the compatibility of a CVB image with this classifier. More...
 
- Public Member Functions inherited from PolimagoFactoryCreatedObject
void * Handle () const noexcept
 Classic API Polimago handle. More...
 
String FileName () const
 Name of the file the object has been loaded from (or empty string if the object was not loaded). More...
 
void Save (const String &fileName) const
 Save this object into a file. More...
 
double Lambda () const noexcept
 Regularization value that has been used for generating this object. More...
 
double Offset () const noexcept
 Intercept weight that has been used for generating this object. More...
 
InterpolationType Interpolation () const noexcept
 Interpolation setting used for generating this object. More...
 
int ImagePlanes () const noexcept
 The plane count of the images that have been used for generating this classifier. Image on which this classifier is to be used will need to have the same plane count. More...
 
Rect< int > FeatureWindowExtent () const noexcept
 The feature window extent that has been used during classifier training. More...
 
Size2D< int > RetinaSize () const noexcept
 Size of the 'Retina' in pixels. The retina is the set of paxels onto which the input image is projected using the preprocessing code prior to application/training of the classifier. More...
 
Point2D< double > Correction () const noexcept
 Correction factors in X and Y direction required to rescale the input images for projection onto the retina. More...
 
String Preprocessing () const
 Preprocessing code with which this object was generated. More...
 

Detailed Description

Base class for Polimago predictors.

Member Function Documentation

◆ IsCompatible() [1/2]

bool IsCompatible ( const Image img) const
inline

Verify the compatibility of a CVB image with this classifier.

Parameters
[in]imgImage to be verified.
Returns
True if the image is compatible with this classifier. Note that even if the classifier is basically compatible with the image, not all positions in the image are usable for classification.
Exceptions
Anyexception derived from std::exception including CvbException.

◆ IsCompatible() [2/2]

bool IsCompatible ( const Image img,
Point2D< int >  pos 
) const
inline

Verify the compatibility of a CVB image with this classifier.

Parameters
[in]imgImage to be verified.
[in]posPosition in the image to be processed.
Returns
True if the image is compatible with this classifier and the position indicated by the pos parameter can be used for evaluation.
Exceptions
Anyexception derived from std::exception including CvbException.