-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBrownTestHMM.java
More file actions
25 lines (20 loc) · 841 Bytes
/
Copy pathBrownTestHMM.java
File metadata and controls
25 lines (20 loc) · 841 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/**
* This is a class to test my HMM class on the Brown corpus dataset.
* This runs the file test and then the console test to accept and tag console input from the user.
*
* @author Basil Lone
*/
public class BrownTestHMM {
public static void main(String[] args) throws Exception {
// BROWN TESTING
HMM brown_test = new HMM();
// Model training
brown_test.trainModel("data/brown-train-tags.txt", "data/brown-train-sentences.txt");
// Model testing
brown_test.fileTester("data/brown-test-sentences.txt", "predictions/brown-test-predictions.txt");
// Get metrics on the performance of the model
brown_test.getMetrics("data/brown-test-tags.txt", "predictions/brown-test-predictions.txt");
// Run the console test
brown_test.consoleTester();
}
}