RSWrapperBase is a base wrapper class for holding all RangeSearch types supported by RSModel. More...
Public Member Functions | |
RSWrapperBase () | |
Create the RSWrapperBase object. More... | |
virtual | ~RSWrapperBase () |
Destruct the RSWrapperBase (nothing to do). More... | |
virtual RSWrapperBase * | Clone () const =0 |
Create a new RSWrapperBase that is the same as this one. More... | |
virtual const arma::mat & | Dataset () const =0 |
Get the dataset. More... | |
virtual bool | Naive () const =0 |
Get whether naive search is being used. More... | |
virtual bool & | Naive ()=0 |
Modify whether naive search is being used. More... | |
virtual void | Search (util::Timers &timers, arma::mat &&querySet, const math::Range &range, std::vector< std::vector< size_t >> &neighbors, std::vector< std::vector< double >> &distances, const size_t leafSize)=0 |
Perform bichromatic range search (i.e. More... | |
virtual void | Search (util::Timers &timers, const math::Range &range, std::vector< std::vector< size_t >> &neighbors, std::vector< std::vector< double >> &distances)=0 |
Perform monochromatic range search (i.e. More... | |
virtual bool | SingleMode () const =0 |
Get whether single-tree search is being used. More... | |
virtual bool & | SingleMode ()=0 |
Modify whether single-tree search is being used. More... | |
virtual void | Train (util::Timers &timers, arma::mat &&referenceSet, const size_t leafSize)=0 |
Train the model (build the reference tree if needed). More... | |
RSWrapperBase is a base wrapper class for holding all RangeSearch types supported by RSModel.
All RangeSearch type wrappers inherit from this class, allowing a simple interface via inheritance for all the different types we want to support.
Definition at line 34 of file rs_model.hpp.
|
inline |
Create the RSWrapperBase object.
The base class does not hold anything, so this constructor does nothing.
Definition at line 39 of file rs_model.hpp.
References RSWrapperBase::Clone().
|
inlinevirtual |
Destruct the RSWrapperBase (nothing to do).
Definition at line 46 of file rs_model.hpp.
References RSWrapperBase::Dataset(), RSWrapperBase::Naive(), RSWrapperBase::Search(), RSWrapperBase::SingleMode(), and RSWrapperBase::Train().
|
pure virtual |
Create a new RSWrapperBase that is the same as this one.
This function will properly handle polymorphism.
Implemented in LeafSizeRSWrapper< TreeType >, and RSWrapper< TreeType >.
Referenced by RSWrapperBase::RSWrapperBase().
|
pure virtual |
Get the dataset.
Implemented in RSWrapper< TreeType >.
Referenced by RSWrapperBase::~RSWrapperBase().
|
pure virtual |
Get whether naive search is being used.
Implemented in RSWrapper< TreeType >.
Referenced by RSWrapperBase::~RSWrapperBase().
|
pure virtual |
Modify whether naive search is being used.
Implemented in RSWrapper< TreeType >.
|
pure virtual |
Perform bichromatic range search (i.e.
a search with a separate query set).
Implemented in LeafSizeRSWrapper< TreeType >, and RSWrapper< TreeType >.
Referenced by LeafSizeRSWrapper< TreeType >::Clone(), RSWrapper< TreeType >::Naive(), RSModel::RandomBasis(), and RSWrapperBase::~RSWrapperBase().
|
pure virtual |
Perform monochromatic range search (i.e.
a search with the reference set as the query set).
Implemented in RSWrapper< TreeType >.
|
pure virtual |
Get whether single-tree search is being used.
Implemented in RSWrapper< TreeType >.
Referenced by RSWrapperBase::~RSWrapperBase().
|
pure virtual |
Modify whether single-tree search is being used.
Implemented in RSWrapper< TreeType >.
|
pure virtual |
Train the model (build the reference tree if needed).
Implemented in LeafSizeRSWrapper< TreeType >, and RSWrapper< TreeType >.
Referenced by LeafSizeRSWrapper< TreeType >::Clone(), RSWrapper< TreeType >::Naive(), and RSWrapperBase::~RSWrapperBase().