Persisting data between Opencv-Python and Opencv-C++

asked 2015-02-16 04:41:15 -0500

krips89 gravatar image

updated 2015-02-16 07:52:06 -0500

Hello, is there any simple interface which can be used for persisting data between Opencv-Python and Opencv-C++? That is I want to write some data (metrices) from Opencv-Python and read it later with Opencv-C++ (and vice versa).

One way is to convert numpy arrays to cv::Mat manually which in my opinion is ugly. Also, I did not get any simple solution for doing that in the latest opencv. All the available solution I found dates back to 3 years which uses modules like cv and functions like cv.fromarray which are not available in the latest version (?).

edit retag flag offensive close merge delete

Comments

1

known pain point. but until e.g. this, see 3) will make it into opencv, you probably will have find your own way.

berak gravatar imageberak ( 2015-02-16 05:01:39 -0500 )edit

@berak Ah, so its a GSoC idea. It actually should not take much time, isn't it?

krips89 gravatar imagekrips89 ( 2015-02-16 08:02:18 -0500 )edit

@krips89 i am guessing that the GSoC will handle more than only the transfer of the data :)

StevenPuttemans gravatar imageStevenPuttemans ( 2015-02-16 08:19:59 -0500 )edit
1

gsoc won't finish until august or september, and we don't even know, if someone will jump at that idea.

you'll still have to roll your own in the meantime.

berak gravatar imageberak ( 2015-02-16 10:06:20 -0500 )edit