Package org.data2semantics.proppred.predictors

Examples of org.data2semantics.proppred.predictors.SVMPropertyPredictor.train()


    // Create a new SVM property predictor
    SVMPropertyPredictor pred = new SVMPropertyPredictor();
   
    // Train on the first 100 instances
    pred.train(dataset, instances.subList(0, 100), labels.subList(0, 100), blackLists);
   
    // Predict on the rest, note that we also need the blacklists here, since the labels already occur in the test set as well,
    // because we do not use an unlabeled test set, which we would use in an application setting.
    List<Value> predictions = pred.predict(dataset, instances.subList(100,instances.size()), blackLists);
   
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.