org.terrier.applications
Class TRECIndexing

java.lang.Object
  extended by org.terrier.applications.TRECIndexing

public class TRECIndexing
extends java.lang.Object

This class creates the indices for a test collection.

Properties:

Author:
Gianni Amati, Vassilis Plachouras, Ben He, Craig Macdonald

Constructor Summary
TRECIndexing()
          A default constructor that initialised the data structures to use for indexing.
TRECIndexing(java.lang.String _path, java.lang.String _prefix)
          A constructor that initialised the data structures to use for indexing.
 
Method Summary
 void createDirectFile()
          Builds the direct file and lexicon.
 void createInvertedFile()
          Building the inverted file.
 void createSinglePass()
          Builds the inverted file from scratch, single pass method
 void index()
          Calls the method index(Collection[]) of the class Indexer in order to build the data structures for a set of collections.
static void main(java.lang.String[] args)
          Used for testing purposes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TRECIndexing

public TRECIndexing(java.lang.String _path,
                    java.lang.String _prefix)
A constructor that initialised the data structures to use for indexing.

Parameters:
_path - Absolute path to where the index should be created
_prefix - Prefix of the index files, usually "data"

TRECIndexing

public TRECIndexing()
A default constructor that initialised the data structures to use for indexing.

Method Detail

index

public void index()
Calls the method index(Collection[]) of the class Indexer in order to build the data structures for a set of collections. This particular method of the Indexer uses a set of builders for a subset of the collection and builds separate data structures, which are later merged.


createInvertedFile

public void createInvertedFile()
Building the inverted file.


createDirectFile

public void createDirectFile()
Builds the direct file and lexicon. This method goes through the input files specified in the collections.spec file and processes them in groups of n documents, where n is specified by the property bundle.size. Then, it merges the temporary lexicon files. If it necessary, it calls for the optimisation of the identifiers assigned to terms.


createSinglePass

public void createSinglePass()
Builds the inverted file from scratch, single pass method


main

public static void main(java.lang.String[] args)
Used for testing purposes.

Parameters:
args - the command line arguments.


Terrier 3.5. Copyright © 2004-2011 University of Glasgow