Hi everyone,
I went through the terrier quickstart tutorial corpus and then I run the code below:
import java.util.Arrays;
import org.terrier.indexing.Collection;
import org.terrier.indexing.SimpleFileCollection;
import org.terrier.structures.indexing.Indexer;
import org.terrier.structures.indexing.classical.BasicIndexer;
import org.terrier.utility.ApplicationSetup;
public class IndexingExample {
public static void main(String[] args) throws Exception {
// TODO Auto-generated method stub
// Directory containing files to index
String aDirectoryToIndex = "/home/nadhem/PFE/terrier-core-4.2/share/vaswani_npl/corpus/";
// Configure Terrier
ApplicationSetup.setProperty("terrier.home", "/home/nadhem/PFE/terrier-core-4.2");
Indexer indexer = new BasicIndexer("/home/nadhem/PFE/terrier-core-4.2/var/index", "data");
Collection coll = new SimpleFileCollection(Arrays.asList(aDirectoryToIndex), true);
indexer.index(new Collection[]{coll});
}
}
I got the following error:
WARNING: The file terrier.properties was not found at location /etc/terrier.properties Assuming the value of terrier.home from the corresponding system property. Please ensure that the property terrier.home is specified in the file terrier.properties, or as a system property in the command line.
I didn't understand why the properties file was not found despite having checked it...there is another
Any help would be most appreciated.
thanks, Nadhmanovic