How to store and load train data of KNearest with Java API

asked 2016-02-12 02:38:03 -0600

I use the java impl of opencv 3.1.0 on windows.

I use KNearest with my sample image to train. After training i like to store the train result. But always i get a exception on the knearest.save() call:

Exception in thread "main" java.lang.Exception: unknown exception at org.opencv.core.Algorithm.save_0(Native Method) at org.opencv.core.Algorithm.save(Algorithm.java:53) at omrtest.omr.KMeansOMRReader.train(KMeansOMRReader.java:96)

And not enough - if saving works, how can i load the train data? I do not see any load method.

Thanks in advance.

edit retag flag offensive close merge delete

Comments

Ever found a solution for this?

just_trying_stuff gravatar imagejust_trying_stuff ( 2016-04-11 14:44:29 -0600 )edit

No, maybe API isnt fully ported yet.

kreyssel gravatar imagekreyssel ( 2016-04-12 02:29:58 -0600 )edit

Any luck yet?

yaswanth_kr gravatar imageyaswanth_kr ( 2016-11-29 05:01:38 -0600 )edit