Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error compiling mex files on 64 bit Ubuntu #8

Closed
spearsem opened this issue Apr 22, 2011 · 9 comments
Closed

Error compiling mex files on 64 bit Ubuntu #8

spearsem opened this issue Apr 22, 2011 · 9 comments

Comments

@spearsem
Copy link

I followed the download instructions, and after fixing the include directories, etc., and getting the "compile.m" function to work successfully, I then tried to run the tracker on a directory of images. Things seemed to work OK for a second, and the first image within my directory popped up with the interactive bounding box as seen in the tutorial. I tried to select the initial bounding box of a face and double clicked inside it and received this error in the Matlab console:


??? Invalid MEX-file '/home/ely/Desktop/Classroom_Project/Research_Code/Predator_Tracking/zk00006-OpenTLD-8a6934d/mex/lk.mexa64': /home/ely/matlab/bin/glnxa64/../../sys/os/glnxa64/libstdc++.so.6:
version `GLIBCXX_3.4.11' not found (required by /usr/local/lib/libopencv_contrib.so.2.2).

Error in ==> tldInit at 20
lk(0);

Error in ==> tldExample at 34
tld = tldInit(opt,[]); % train initial detector and initialize the 'tld' structure

Error in ==> run_TLD at 49
[bb,conf] = tldExample(opt);


I am using Matlab R2010 A with Ubuntu 10.04 64-bit. Any help is very appreciated.

Cheers,
Ely

@efelem
Copy link

efelem commented Apr 22, 2011

Hi Ely,

I had the same problem and I fix it following the instruction given here :
https://bbs.archlinux.org/viewtopic.php?id=86809

Hope it helps

@spearsem
Copy link
Author

I followed all of the steps in these links, including reverting back to G++4.1, and then moving and re-linking the relevant libstdc++* files. Howevere, I still get the exact same error:


??? Invalid MEX-file
'/home/ely/Desktop/Classroom_Project/Research_Code/Predator_Tracking/zk00006-OpenTLD-8a6934d/mex/lk.mexa64':
/home/ely/matlab/bin/glnxa64/../../sys/os/glnxa64/libstdc++.so.6:
version `GLIBCXX_3.4.11' not found (required by
/usr/local/lib/libopencv_contrib.so.2.2).


I'm using Matlab 2010A, OpenCV 2.2.0, on Ubuntu 10.04 64-bit. I'm not sure why mex seems to be failing. The file compile.m still works fine and everything compiles, but then when I run run_TLD.m, the above error still appears. Any more ideas?

-Ely

@efelem
Copy link

efelem commented Apr 23, 2011

I have exactly the same OS, same Matlab version and same opencv version. I had exactly the same error until I also removed the file libgcc_s.so.1 from the $MATLABROOT/sys/os/glnxa64 directory.

-Flo

@spearsem
Copy link
Author

Thanks Flo, however I have also done that. I first tried moving the existing copy of libgcc_s.so.1 to libgcc_s.so.1.orig and then recompiling, but it gives the same error. Then I tried creating a new sym link to /lib/libgcc_s.so.1, the system's version of the file, and still again I get the same error.

Ely

@efelem
Copy link

efelem commented Apr 23, 2011

Just to be sure, have you close matlab after moving libgcc_s.so.1 to libgcc_s.so.1.orig and before recompiling ?

@spearsem
Copy link
Author

Okay, back in the office today. After restarting Matlab, it appears to work and gives me a "results saved to ./_output" at the console. However, the .txt file of results contains the location of the box in Frame 1 (the one I selected), and every subsequent frame they are all NaNs. Any ideas on what would make the tracker choke like this? The image files I am using it on are .jpgs in a directory. Do I need to name them with any special convention for it process them in order? Thanks!

@efelem
Copy link

efelem commented Apr 25, 2011

I think that the images should be numbered something like :
00001.jpg
00002.jpg
00003.jpg
...

Be sure that you have enough zeros so that all the image files have the same
size

name
2011/4/25 spearsem <
reply@reply.github.com>

Okay, back in the office today. After restarting Matlab, it appears to work
and gives me a "results saved to ./_output" at the console. However, the
.txt file of results contains the location of the box in Frame 1 (the one I
selected), and every subsequent frame they are all NaNs. Any ideas on what
would make the tracker choke like this? The image files I am using it on are
.jpgs in a directory. Do I need to name them with any special convention for
it process them in order? Thanks!

Reply to this email directly or view it on GitHub:
#8 (comment)

@zk00006
Copy link
Owner

zk00006 commented Apr 30, 2011

This error does not fit well here, use OpenTLD discussion group.

@zk00006 zk00006 closed this as completed Apr 30, 2011
@hajarSokeh
Copy link

Hi,
Today I just started to install TLD, but when I wanted to run "compile.m", I got this error:
mex: link of ' "lk.mexa64"' failed.

Error using mex (line 206)
Unable to complete successfully.

Error in compile (line 77)
eval(['mex lk.cpp -O' include lib]);

any suggestions???
Thanks,
Hajar

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants