AlanLuSun / High-quality-ellipse-detection

A high-quality ellipse detector based on arc-support line segments which can both accurately and efficiently detect ellipses in images.
459 stars 145 forks source link

How to migrate the code to Linux? #10

Open Yishun99 opened 5 years ago

Yishun99 commented 5 years ago

Can you provide some idea for migrating the code/compilation to Linux?

guysoft commented 4 years ago

I tried and got stuck. It seems the repo has been abandoned.

maaaaadn commented 4 years ago

for me it works perfectly under ubuntu linux. first you need to install the opencv either from the website or from the repo using sudo apt install libopencv-dev then you should be able to mex using mex -lmwlapack -lopencv_core -lopencv_highgui -lopencv_imgproc generateEllipseCandidates.cpp in case of questions feel free to ask.

maaaaadn commented 4 years ago

ah, I forgot one thing... I had to add using namespace std; in the generateEllipseCandidates.cpp file, e.g. just after using namespace cv; (line 17)

guysoft commented 4 years ago

@maaaaadn Where are what mex command from? Matlab? If so what version?

What does the ouput of which mex?

maaaaadn commented 4 years ago

@guysoft , the mex command is a matlab command yes. I'm currently running matlab R2019b which mex gives me built-in (/usr/local/MATLAB/R2019b/toolbox/matlab/general/mex) note, /usr/local/MATLAB/R2019b/ is my matlab root directory.

liang-zijian commented 1 year ago

I have successfully ported to Ubuntu 20.04 and Opencv4.5.5, you can download my compiled mexa64 file from my repository and try it out:https://github.com/liang-zijian/High-quality-ellipse-detection-ubuntu20