Skip to content

Commit

Permalink
fix location of models per book instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
gsingers committed Mar 4, 2013
1 parent 1c909ef commit 23d1099
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/test/java/com/tamingtext/frankenstein/Frankenstein.java
Original file line number Diff line number Diff line change
Expand Up @@ -220,13 +220,13 @@ private void addMetadata(Document doc, int lines, int paragraphs, int paragraphL
*/
private void init() throws IOException {
System.out.println("Initializing Frankenstein");
File models = new File("../../opennlp-models");
File wordnet = new File("../../WordNet-3.0");
File models = new File("./opennlp-models");
File wordnet = new File("./WordNet-3.0");
if (models.exists() == false) {
throw new FileNotFoundException("../../opennlp-models");
throw new FileNotFoundException("./opennlp-models");
}
System.setProperty("model.dir", "../../opennlp-models");
System.setProperty("wordnet.dir", "../../WordNet-3.0");
System.setProperty("model.dir", "./opennlp-models");
System.setProperty("wordnet.dir", "./WordNet-3.0");

File modelFile = new File(models, "en-sent.bin");
InputStream modelStream = new FileInputStream(modelFile);
Expand Down

0 comments on commit 23d1099

Please sign in to comment.