Compress and store a SubIndex. More...
#include <FloatIndex.h>
Public Member Functions | |
FloatIndex (int indexLength, int listLength, BlockStats *stats, FileName *filename) | |
Initialise the class with the given index length and list length, and a storage file. | |
virtual bool | calculateRow (int currentRealWord)=0 |
Calculate the row and return TRUE if it should be stored. | |
virtual int | listRealPosition (int position)=0 |
Return the real list position (based on the initial index). | |
virtual int | indexRealPosition (int position)=0 |
Return the real index position (based in the initial index). | |
virtual const char * | elementName (int elementNumber) |
Return the element name. | |
void | createFloatIndex (int processedWords, int storedWords) |
Create and store the given data. | |
void | printTripleList (void) |
Print the current list of elements to the screen. | |
Protected Member Functions | |
void | checkRowBounds (int element) |
Recompute the maximum and minimum positive elements for quantisation. | |
void | pnCheckRowBounds (int element) |
Recompute the maximum and minimum positive and negative elements for quantisation. | |
virtual Quantise * | createQuantiser (float lower, float upper)=0 |
Assign a quantiser to convert floats to ints. | |
Protected Attributes | |
float * | _rowBuffer |
The current row of data being processed. | |
const int | _listLength |
The maximum lenght of a list. |
Compress and store a SubIndex.
This class is a base class for storing index and thesaurus like structures of various types. Virtual methods are defined to allow the user to implement how the stored structures are created and how they should be stored.