Ask Your Question
0

cannot save SVM in OpenCV4Android 3.2 after upgrade: Fatal signal 11

asked 2017-01-08 14:11:16 -0600

wes.y.w. gravatar image

I just upgraded to 3.2.0 from 2.4.9 and it seems like the save function is broken? All I did was change CvSVM to SVM

SVM svmClassifier = SVM.create(); 
File svm_file = new File(dir, "svm_test.xml");
svmClassifier.save(svm_file.toString());

will now report A/libc: Fatal signal 11 (SIGSEGV) at 0x644e98f8 (code=2), thread 2380 (Thread-6433). The same flow worked fine with 2.4.9 and CvSVM. Help?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2017-01-09 14:52:48 -0600

alexander33 gravatar image

the way like you create the SVM is wrong. since opencv 3.0 changed.

You can see this: http://docs.opencv.org/3.1.0/d1/d73/t... for see one example.

Ptr<SVM> svm = SVM::create();

also i find this explanation, the best that i found. https://www.simplicity.be/article/rec...

good luck!

edit flag offensive delete link more

Comments

nice, that you're trying to help, but the question i about java, while your answer is about c++.

berak gravatar imageberak ( 2017-01-09 17:19:22 -0600 )edit

thanks, @alexander33, but as @berak pointed out, this error seems to be specific to java.

wes.y.w. gravatar imagewes.y.w. ( 2017-01-09 20:53:56 -0600 )edit

Have you found solution to this save problem?

Infinito gravatar imageInfinito ( 2017-02-27 07:49:45 -0600 )edit

@wes.y.w. Have you found a solution for this. I am suffering from the same error.

Nani gravatar imageNani ( 2017-07-05 07:39:50 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2017-01-08 14:11:16 -0600

Seen: 275 times

Last updated: Jan 09 '17