From 538c8e4d65b460db537ab81159f83e1092626275 Mon Sep 17 00:00:00 2001 From: Hai Liu Date: Wed, 20 Apr 2016 15:19:09 +0800 Subject: Add predictor interface JIRA:PREDICTION-43 Change-Id: I4b044ef2a3c34046014697cd9696254c1461f48a --- src/predictor/PredictorInterface.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/predictor/PredictorInterface.java diff --git a/src/predictor/PredictorInterface.java b/src/predictor/PredictorInterface.java new file mode 100644 index 0000000..03b9052 --- /dev/null +++ b/src/predictor/PredictorInterface.java @@ -0,0 +1,18 @@ +package predictor; + +import java.util.Random; + +import weka.core.*; + +public interface PredictorInterface { + public String getName(); + public void crossValidate(Instances instances, int numFold, Random rand) throws Exception; + //public String getEvaluationSummaryString(); + //public String getEvaluationMatrixString() throws Exception; + public FastVector getEvaluationPredictions(); + public void train(Instances instances) throws Exception; + public int predict(Instance instance) throws Exception; + public int predict(Instances instances) throws Exception; + public String getEvaluationResults() throws Exception; +} + -- cgit 1.2.3-korg