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 when building #1
Comments
Hi pxuanqui, can I have 3 things before I can debug this issue?
I'm not sure what's the issue (it's still working on mine) ...
but if those two lines are the cause of the error, then I hate to tell you that, those are the APIs from OpenCV. But again, if you're okay with it, please supply me those 3 things so that I can debug it. For your information, this example uses OpenCV 2.4.9 and Tesseract 3.02. |
I use your TestText.png and the same parameters, I don't modify anything |
Hmmm, I don't have a Visual Studio, I only have a Macbook here, so there are things that I can't do. First, here's some of the information about my build of OpenCV from home-brew (a package installer in mac)
I don't think you need eigen, jasper, or openexr. But the example were compiled with QT functionalities for printing out the text, so you might want to comment the part out. Second, I wrote a small test function to help me localise the issue, please try this updated main.cpp file: https://www.dropbox.com/s/5pt941ulbp388vh/main.cpp Third, I'd presume that your OpenCV weren't built with QT support, so you might want to comment out
And print out the detected text from Please update me about the progress, I'm apologise for the inconveniences. |
First is that I updated RobustTextDetection to have a check on the resulting detected region, to avoid exception Second, sadly for your example, you require to increase your max connected component count And finally, although it will run now, the result will be way off, and you might need to start with parameter tuning to get the desired result. |
Sadly the application is very fragile, you might need to tweak the parameters a bit when it comes to new images. It's not meant to be a library, it's supposed to be a sample test case on how it works. |
Well, I'm not the one who wrote the paper...
These are the range of the detected MSER area, for detected regions that are outside of those number of pixels (10 - 400 pixels), it's discarded
Parameters for canny edge detection
These are for connected components. Similar to the MSER params above, any connected component above or below the range, will be discarded
The final 4 params, are bit confusing, even for me. Basically it defines whether the detected region is a blob, or twisted, it's solid, and how spread out it is. You might want to play a bit around it, to see how it affects the detection of letters like 'I' or 'S', etc. |
oh! ! !thank you very much,i can run it now thank you !! |
Hello,subokia! I use opencv 2.4.10 for windows(without QT support i guess,so i just replace cvFontQT with fontQT and i don't know wether it works or not),Tesseract 3.02 and Visual Studio 2013. I debuged it for several days but failed in the end. I wonder if thise code could only run at Mac? Did you have a "windows version"? (Sorry,I'm not good at speeking english. But i want to say: you are a nice person!) |
Hi HerShawn, sadly I don't really know what's the main issue when running on Windows (I don't own a Windows PC, sadly). Anyway, maybe try to comment out the QT part first, and see if that's the issue, sometimes I think it's more of the incompatible library, but maybe not in this case. Below is the snippet of the last few chunk of codes on the main method, just comment out the QT font part.
I doubt that commenting QT would resolve the issue, but please keep me updated. |
Thank you very much,Saburo Okita! |
Hi,brother:
in windows. So i send them to you . Good night!
------------------ 原始邮件 ------------------ Hi HerShawn, sadly I don't really know what's the main issue when running on Windows (I don't own a Windows PC, sadly). Anyway, maybe try to comment out the QT part first, and see if that's the issue, sometimes I think it's more of the incompatible library, but maybe not in this case. Below is the snippet of the last few chunk of codes on the main method, just comment out the QT font part. — |
Great! Have fun with it! |
Hi Subokita, I have an error when building with g++ (-std=gnu++11) : /usr/include/c++/4.8/bits/stl_algo.h:2263:35: error: no match for call to ‘(ConnectedComponent::apply(const cv::Mat&)::__lambda0) (ComponentProperty&, const ComponentProperty&)’ Do you know what it could be? Thanks in advance! |
Hello Subokita, In what line of code will I insert the bounding box part found on part 4 MATLAB implementation? Thanks :) |
@swingfox Should be starting around line 123 in RobustTextDetection.cpp |
@ctouffet |
Hello, when I compile the project, I get the error: variable type 'cv::MSER' is an abstract class. |
@mynameischaos Sadly I haven't touched this project for 2 years. Based on the documentation, it shouldn't be abstract, but I no longer know what's the issue. Basically in the createMSERMask() it should call opencv's MSER method
Maybe the version of OpenCV I used were too old, just update it to newest opencv code that apply MSER to the greyscale image. |
@subokita Oh,no. Because of the version, based on the documentation of version 3.1.0, now it's abstract class. |
When debug to this function, it shows the error "Access violation reading location 0xCDCDCDD1"
Mat RobustTextDetection::createMSERMask(Mat& grey) {
/* Find MSER components */
vector<vector> contours;
MSER mser(8, param.minMSERArea, param.maxMSERArea, 0.25, 0.1, 100, 1.01, 0.03, 5);
mser(grey, contours);
}
The text was updated successfully, but these errors were encountered: