Terrier IR Platform
2.2.1

uk.ac.gla.terrier.structures.indexing.singlepass
Class Inverted2DirectIndexBuilder

java.lang.Object
  extended by uk.ac.gla.terrier.structures.indexing.singlepass.Inverted2DirectIndexBuilder
Direct Known Subclasses:
BlockInverted2DirectIndexBuilder

public class Inverted2DirectIndexBuilder
extends java.lang.Object

Create a direct index from an InvertedIndex. The algorithm is similar to that followed by InvertedIndexBuilder. To summarise, InvertedIndexBuilder builds an InvertedIndex from a DirectIndex. This class does the opposite, building a DirectIndex from an InvertedIndex.

Algorithm:
For a selection of document ids  (Scan the inverted index looking for postings with these document ids)  For each term in the inverted index   Select required postings from all the postings of that term   Add these to posting objects that represents each document &nsbp;For each posting object   Write out the postings for that document

Notes:
This algorithm assumes that termids start at 0 and are strictly increasing. This assumption holds true only for inverted indices generated by the single pass indexing method.

Properties:

  1. inverted2direct.processtokens - total number of tokens to attempt each iteration. Defaults to 100000000. Memory usage would more likely be linked to the number of pointers, however as the document index does not contain the number of unique terms in each document, the pointers calculation is impossible to make.

Since:
2.0
Version:
$Revision: 1.8 $
Author:
Craig Macdonald

Constructor Summary
Inverted2DirectIndexBuilder(Index i)
          Construct a new instance of this builder class
 
Method Summary
 void createDirectIndex()
          create the direct index when the collection contains an existing inverted index
static void main(java.lang.String[] args)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Inverted2DirectIndexBuilder

public Inverted2DirectIndexBuilder(Index i)
Construct a new instance of this builder class

Method Detail

createDirectIndex

public void createDirectIndex()
create the direct index when the collection contains an existing inverted index


main

public static void main(java.lang.String[] args)

Terrier IR Platform
2.2.1

Terrier Information Retrieval Platform 2.2.1. Copyright 2004-2008 University of Glasgow