#include <ProximityMeasure.h>
Inheritance diagram for prapi::ProximityAdder< T >:

It may be used in scaling the measured values.
Example:
//Memory autorelease mode - no need to store a pointer to the //new EuclideanDiscance object ProximityAdder<double> adder(new EuclideanDistance<double>, -1.0); //No memory autorelease EuclideanDistance<double> dist; ProximityAdder<double> adder(dist, -1.0); //Absolutely wrong! The local variable would be automatically //deleted. Your program will most likely dump core. EuclideanDistance<double> dist; ProximityAdder<double> adder(&dist, -1.0); //One extra '&'.This measure comes in handy when you have multiple feature vectors in each sample and need to scale the proximities.
Public Methods | |
| ProximityAdder (ProximityMeasure< T > *measure, double value) | |
| Create a new Adder that uses the given proximity measure. | |
| ProximityAdder (ProximityMeasure< T > &measure, double value) | |
| Create a new Adder that uses the given proximity measure. | |
| virtual | ~ProximityAdder () |
| double | getProximity (const util::List< T > &sample, const util::List< T > &model, double stopAfter) const throw (ProximityException&) |
| Proximity between two lists. | |
|
||||||||||||||||
|
Create a new Adder that uses the given proximity measure. Note that if you use this constructor, the memory pointed by measure is automatically released upon the deletion of the Adder.
|
|
||||||||||||||||
|
Create a new Adder that uses the given proximity measure.
|
|
||||||||||||||||||||
|
Proximity between two lists.
Implements prapi::ProximityMeasure< T >. |