Giter Club home page Giter Club logo

Comments (16)

amroamroamro avatar amroamroamro commented on July 18, 2024

@escorciav:
What is your configuration of OS, compiler, MATLAB and OpenCV versions?

@kyamagu:
In those lines, p is a smart pointer.
Maybe the test should use p.empty() instead of p==0?

(I should mention that I don't have any compilation problems with the above using VS2010)

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

@escorciav
Can you post the OS, compiler, MATLAB and OpenCV versions, as amro suggests? The latest commit includes a possible fix for that specific error. Can you also pull the latest commit and see if the problem still persist?

@amro
Thanks, it's updated.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

Thanks @kyamagu and @amro.
I'm using Fedora 18, gcc 4.6 and opencv 2.4.9. I will fetch the repositorie later because I am not in home.

I have another machine with Centos 6, gcc 4.4 and opencv 2.4.9. Could you expect to work in this too?

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

Well, the latest official release of OpenCV is 2.4.3. I cannot give any
guarantee for a future release. Nevertheless, the codes might work as long
as the API doesn't change.

On Mon, Feb 11, 2013 at 1:46 PM, Victor Escorcia Castillo <
[email protected]> wrote:

Thanks @kyamagu https://github.com/kyamagu and @amrohttps://github.com/amro.

I'm using Fedora 18, gcc 4.6 and opencv 2.4.9. I will fetch the
repositorie later because I am not in home.

I have another machine with Centos 6, gcc 4.4 and opencv 2.4.9. Could you
expect to work in this too?


Reply to this email directly or view it on GitHubhttps://github.com//issues/37#issuecomment-13395560.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

Thanks. I can compile the MEX-files without problem after pull the repo.
Currently, I have some problems testing the mex-files ( error linking libraries --libraw1394.so.8 which is neither in my OS nor MATLAB 2011b). I don't understand who is using this library. Could you give me any idea?

@kyamagu or @amro: Could you put the result of ">!ldd /path_to/mexopencv/+cv/imread.mexa64"?

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

That's a library for camera connection. I currently don't have a handy Linux 64-bit environment to run that command, but I can imagine that highgui module depends on IEEE1394 camera.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

I linked libraw1394.so.11 to /matlab/bin/glnx64/ as libraw1394.so.8 but it appears another error with libopencv_world. I'm going to compile opencv again.
Thanks @kyamagu

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

Hi @kyamagu,
I recompile opencv version 2.4.3 and I still get the linking error with libraw1394.so.8. Besides, Matlab crashes if I replace libraw1394.so.11 with libraw1394.so.8.
Do you recommend compile mexopencv with all opencv libraries except highgui module?

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

Can you run an ordinary OpenCV program written in C++? One possibility is that matlab is loading its internal libraw1394 while the compiler is linking against system's library. In that case, you can solve the problem with LD_PRELOAD variable (see README).

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

It's so strange because I can't find libraw1394.so.8 in my OS.
When I type anyone opencv example from shell

$ ldd /path_to/example_opencv
libraw1394.so.11 -> /us/lib64/libraw1394.so.11

However, when I type the mexopencv example from matlab

>> !ldd /path_to/example_mexopencv
/usr/lib64/libraw1394.so.11 (0x00007f9b1f02b000)
libras1394.so.8 -> not found

I'm using LD_PRELOAD with (libraw1394.so.11) however this can't solve the problem. Maybe, libraw1394.so.8 is a dependency of another library loaded by MATLAB. Do you know how to preload all the libraries in /usr/lib64 -without copy one by one-?

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

I don't know how to preload everything, but maybe the libdc1394 that is coming with matlab is depending on libraw1394. Can you check what libraries are located at $MATLABROOT/bin/glnxa64/ ? Check if there are suspicious shared objects, and try PRELOAD or replace them with symlinks to see if that solves a problem.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

I compile and invoke (call without error) the mex-file including libdc1394.so.22.1.6 instead of libraw1394.so.11 in LD_PRELOAD. However, Matlab crashes after call the mex-file.

Abnormal termination:
Segmentation violation
...
MATLAB is exiting because of fatal error

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

What happens if you move libdc1394 out of the matlab internal? Also can you try using the system's libstdc++.so in LD_PRELOAD? You can append multiple shared objects in LD_PRELOAD with colon separation.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

Hi @kyamagu, sorry by my late reply.
I test your opencv wrapper in other machine (Centos 6.3, kernel 2.6.32-279.19.1.el6.x86_64, gcc 4.4.6, MATLAB R2011b, opencv 2.4.3) and It compiles and "runs" successfully. I'm going to compile carefully in my fedora machine.
By other hand, I typed:

$ make test MATLABDIR=/matlab_path/MATLAB/R2011b/

and I got some messages (an example below):

== TestCalcOpticalFlowPyrLK ======
-- test_1 ------
PASS
-- test_error_1 ------
PASS
== TestCalibrateCamera ======
-- test_error_1 ------
PASS
  1. Is it normal?
  2. Are all the functions compile succesfully?
  3. Do I have to debug some functions?

from mexopencv.

kyamagu avatar kyamagu commented on July 18, 2024

Yes, the test is running correctly. Try to check the difference in fedora.

Kota

On Feb 14, 2013, at 18:10, Victor Escorcia Castillo [email protected] wrote:

Hi @kyamagu, sorry by my late reply.
I test your opencv wrapper in other machine (Centos 6.3, kernel 2.6.32-279.19.1.el6.x86_64, gcc 4.4.6, MATLAB R2011b, opencv 2.4.3) and It compiles and "runs" successfully. I'm going to compile carefully in my fedora machine.
By other hand, I typed:
$ make test MATLABDIR=/matlab_path/MATLAB/R2011b/
and I got some messages (an example below):
== TestCalcOpticalFlowPyrLK ======
-- test_1 ------
PASS
-- test_error_1 ------
PASS
== TestCalibrateCamera ======
-- test_error_1 ------
PASS

  1. Is it normal?
  2. Are all the functions compile succesfully?
  3. Do I have to debug some functions?


Reply to this email directly or view it on GitHub.

from mexopencv.

escorciav avatar escorciav commented on July 18, 2024

I have no idea what happen in fedora 18. I compile gcc 4.6 and opencv 2.4.3 again but I can not run the mexopencv successfully (matlab crashed with segmentation fault ...).

from mexopencv.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.