An accessor to an inverted file. More...
#include <CAcInvertedFileAbstraction.h>
Public Member Functions | |
| virtual bool | operator() () const =0 |
| for testing if the inverted file is correctly constructed | |
| CAcInvertedFileAbstraction (const CXMLElement &inCollectionElement) | |
| This opens an exsisting inverted file, and then inits this structure. More... | |
| ~CAcInvertedFileAbstraction () | |
| Destructor. | |
| virtual string | IDToURL (TID inID) const =0 |
| <HIER-WIRDS-INTERESSANT-> More... | |
| virtual TID | URLToID (const string &inURL) const =0 |
| Translate an URL to its document ID. | |
| virtual list< TID > * | getAllFeatureIDs () const =0 |
| Getting a list of all features contained in this. More... | |
The proper inverted file access | |
| virtual CDocumentFrequencyList * | FeatureToList (TFeatureID inFID) const =0 |
| Give the List of documents containing the feature inFID. More... | |
| virtual CDocumentFrequencyList * | URLToFeatureList (string inURL) const =0 |
| List of features contained by a document with URL inURL. | |
| virtual CDocumentFrequencyList * | DIDToFeatureList (TID inDID) const =0 |
| List of features contained by a document with ID inDID. | |
Accessing information about features | |
</HIER-WIRDS-INTERESSANT-> For drawing random sets mainly a translation of getRandomURLs CORNELIA: IM MOMENT KOENNEN WIR DIESE FUNKTION VERGESSEN virtual void getRandomRLLs(list<string>&, list<string>::size_type)const; | |
| virtual double | FeatureToCollectionFrequency (TFeatureID) const =0 |
| Collection frequency for a given feature. | |
| virtual unsigned int | getFeatureDescription (TID inFeatureID) const =0 |
| What kind of feature is the feature with ID inFeatureID? | |
Accessing additional document information | |
| virtual double | DIDToMaxDocumentFrequency (TID) const =0 |
| returns the maximum document frequency for one document ID | |
| virtual double | DIDToDFSquareSum (TID) const =0 |
| Returns the document-frequency square sum for a given document ID. | |
| virtual double | DIDToSquareDFLogICFSum (TID) const =0 |
| Returns this function for a given document ID. | |
| virtual bool | generateInvertedFile ()=0 |
| Generating an inverted File, if there is none. | |
| virtual bool | checkConsistency ()=0 |
| Check the consistency of the inverted file system accessed by this accessor. More... | |
An accessor to an inverted file.
This access is done "by hand" at present this not really efficient, however we plan to move to memory mapped files.
| CAcInvertedFileAbstraction::CAcInvertedFileAbstraction | ( | const CXMLElement & | inCollectionElement | ) |
This opens an exsisting inverted file, and then inits this structure.
After that it is fully usable
As a paramter it takes an XMLElement which contains a "collection" element and its content.
If the attribute vi-generate-inverted-file is true, then a new inverted file will be generated using the parameters given in inCollectionElement. you will NOT be able to use *this afterwards.
The REAL constructor.
|
pure virtual |
Check the consistency of the inverted file system accessed by this accessor.
|
pure virtual |
Give the List of documents containing the feature inFID.
CORNELIA: CDocumentFrequencyList ist nichts anderes als eine liste von
int,float paaren:
struct{ int mID, float mFrequency; }
|
pure virtual |
Getting a list of all features contained in this.
This function is necessary, because in the present system only about 50 percent of the features are really used.
A feature is considered used if it arises in at least one image
|
pure virtual |
<HIER-WIRDS-INTERESSANT->
Translate a DocumentID to a URL (for output)