GateNLP / gateplugin-LearningFramework

A plugin for the GATE language technology framework for training and using machine learning models. Currently supports Mallet (MaxEnt, NaiveBayes, CRF and others), LibSVM, Scikit-Learn, Weka, and DNNs through Pytorch and Keras.
https://gatenlp.github.io/gateplugin-LearningFramework/
GNU Lesser General Public License v2.1
26 stars 6 forks source link

Exception when training regression problems #23

Closed johann-petrak closed 8 years ago

johann-petrak commented 8 years ago

The following exception occurs when training GaussianProcesses or SMO on the abalone regression problem:

Using target feature name from model: review
gate.util.GateRuntimeException: Error during training of Weka
algorithm class weka.classifiers.functions.GaussianProcesses
    at gate.plugin.learningframework.engines.EngineWeka.trainModel(EngineWeka.java:151)
    at gate.plugin.learningframework.LF_TrainRegression.afterLastDocument(LF_TrainRegression.java:172)
    at gate.plugin.learningframework.AbstractDocumentProcessor.controllerExecutionFinished(AbstractDocumentProcessor.java:91)
    at gate.creole.ConditionalSerialAnalyserController.invokeControllerExecutionFinished(ConditionalSerialAnalyserController.java:554)
    at gate.creole.ConditionalSerialAnalyserController.execute(ConditionalSerialAnalyserController.java:142)
    at gate.util.Benchmark.executeWithBenchmarking(Benchmark.java:291)
    at gate.gui.SerialControllerEditor$RunAction$1.run(SerialControllerEditor.java:1734)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ArrayIndexOutOfBoundsException: 54
    at weka.core.SparseInstance.toDoubleArray(SparseInstance.java:425)
    at weka.filters.unsupervised.attribute.Normalize.batchFinished(Normalize.java:304)
    at weka.filters.Filter.useFilter(Filter.java:676)
    at weka.classifiers.functions.GaussianProcesses.buildClassifier(GaussianProcesses.java:334)
    at gate.plugin.learningframework.engines.EngineWeka.trainModel(EngineWeka.java:147)
    ... 7 more
johann-petrak commented 8 years ago

Fixed by 98d7815127ff1237235679014912d5c227689258