本文整理了Java中libsvm.svm.svm_check_parameter()
方法的一些代码示例,展示了svm.svm_check_parameter()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。svm.svm_check_parameter()
方法的具体详情如下:
包路径:libsvm.svm
类名称:svm
方法名:svm_check_parameter
暂无
代码示例来源:origin: dkpro/dkpro-tc
public void run(String argv[]) throws Exception
{
parse_command_line(argv);
read_problem();
error_msg = svm.svm_check_parameter(prob, param);
if (error_msg != null) {
throw new Exception(error_msg);
}
model = svm.svm_train(prob, param);
svm.svm_save_model(model_file_name, model);
}
代码示例来源:origin: org.dkpro.tc/dkpro-tc-ml-libsvm
public void run(String argv[]) throws Exception
{
parse_command_line(argv);
read_problem();
error_msg = svm.svm_check_parameter(prob, param);
if (error_msg != null) {
throw new Exception(error_msg);
}
model = svm.svm_train(prob, param);
svm.svm_save_model(model_file_name, model);
}
代码示例来源:origin: ch.epfl.bbp.nlp/bluima_jsre
public void run(File input_file, File model_file, double c, int mem, double[] weight) throws IOException
{
input_file_name = input_file.getAbsolutePath();
model_file_name = model_file.getAbsolutePath();
//System.out.println("input_file_name: " + input_file_name);
//System.out.println("model_file_name: " + model_file_name);
//System.out.println("mem: " + mem);
set_param(c, mem, weight);
read_problem();
error_msg = svm.svm_check_parameter(prob,param);
if(error_msg != null)
{
System.err.print("Error: "+error_msg+"\n");
System.exit(1);
}
if(cross_validation != 0)
{
//do_cross_validation();
}
else
{
model = svm.svm_train(prob,param);
svm.svm_save_model(model_file_name, model);
}
}
代码示例来源:origin: DigitalPebble/TextClassification
public void internal_learn() throws Exception {
// dumps a file with the vectors for the documents
File learningFile = new File(this.vector_location);
// make space
parse_command_line();
if (cross_validation && nfold < 2)
throw new Exception("n-fold cross validation: n must >= 2\n");
read_problem(learningFile);
error_msg = svm.svm_check_parameter(prob, param);
if (error_msg != null) {
System.err.print("Error: " + error_msg + "\n");
throw new Exception(error_msg);
}
if (cross_validation) {
do_cross_validation();
} else {
model = svm.svm_train(prob, param);
svm.svm_save_model(model_file_name, model);
}
}
代码示例来源:origin: ClearTK/cleartk
private void run(String argv[]) throws IOException {
parse_command_line(argv);
read_problem();
error_msg = svm.svm_check_parameter(prob, param);
if (error_msg != null) {
System.err.print("ERROR: " + error_msg + "\n");
System.exit(1);
}
if (cross_validation != 0) {
do_cross_validation();
} else {
model = svm.svm_train(prob, param);
svm.svm_save_model(model_file_name, model);
}
}
代码示例来源:origin: org.cleartk/cleartk-ml-libsvm
private void run(String argv[]) throws IOException {
parse_command_line(argv);
read_problem();
error_msg = svm.svm_check_parameter(prob, param);
if (error_msg != null) {
System.err.print("ERROR: " + error_msg + "\n");
System.exit(1);
}
if (cross_validation != 0) {
do_cross_validation();
} else {
model = svm.svm_train(prob, param);
svm.svm_save_model(model_file_name, model);
}
}
代码示例来源:origin: org.clulab/processors
final svm_problem prob = readProblem(getInstanceInputStreamReader(".ins"));
final svm_parameter param = getLibSvmParameters();
if(svm.svm_check_parameter(prob, param) != null) {
throw new LibException(svm.svm_check_parameter(prob, param));
代码示例来源:origin: org.maltparser/maltparser
final svm_problem prob = readProblem(getInstanceInputStreamReader(".ins"), libOptions);
final svm_parameter param = getLibSvmParameters(libOptions);
if(svm.svm_check_parameter(prob, param) != null) {
throw new LibException(svm.svm_check_parameter(prob, param));
代码示例来源:origin: jdmp/java-data-mining-package
String error_msg = svm.svm_check_parameter(prob, param);
代码示例来源:origin: nz.ac.waikato.cms.weka/LibSVM
String error_msg = svm.svm_check_parameter(p, pars);
代码示例来源:origin: elki-project/elki
LOG.verbose("Training one-class SVM...");
String err = svm.svm_check_parameter(prob, param);
if(err != null) {
LOG.warning("svm_check_parameter: " + err);
内容来源于网络,如有侵权,请联系作者删除!