Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

IMAQ Find Geometric Pattern not returning any matches

Sorry to bother you twice in one week, developers, but I'm kind of stuck.  I am trying to use custom geometric template matching to return a camera to an original pose, and I have a problem:  the Match Geometric Patter vi isn't returning any matches.  Ordinarily, I would suspect that I was a dunce, but I can make the same images work in the Vision Assistant.

Anyway, the general setup is pretty standard.  I created a template, loaded it with Read Image and Vision Info, instantiated an IEEE 1394 camera, took a snapshot, and compared.  For the Setup Geometric Matching vi, I'm using all the values that I found in the geometric matching example, as well as port defaults that make sense, like ROI being fully inclusive.  Finally, everything gets dumped into the geometric pattern matching, at which point I use an algorithm from the geometric pattern matching example to overlay the template outline on the camera image.

The problem is, there's no outline, and no matches going into my further user interface.  I've tried every variation I can think of in terms of geomatch setup, I've created templates through custom vi's, the vision assistant (8.0), and the Vision template editor, and that hasn't made a difference.  To be quite frank, I really can't even see anything I'm doing differently than the geomatch example, except I don't have a ROI on the matching vi, as an unwired ROI port checks the entire image.

Also, I'm working in LabVIEW 8.20 and yes, I have scaling, rotation, and occlusion checking enabled, and right now my matching score is at 350.  So if anyone has any ideas, I'm more than happy to listen.

 - Jeff

and in case it matters, here's the important part of my vi
http://filer.case.edu/jno/geomatch.bmp
0 Kudos
Message 1 of 3
(3,410 Views)

Hi Jeff,

I just want to clarify a few things.  You mentioned that you were able to get this to work when using the vision Assistant.  Did you create your code using the Vision assistant or did you create it from scratch?  If I understand correctly you created a template in the Vision Assistant and it worked correctly, abut then when you tried in LabVIEW it didn’t work.  One thing we could try is creating the code from the Vision Assistant.  Once you have something working in the Vision Assistant go to Tools>>Create LabVIEW VI.    If the code is working in vision assistant then it should work when you use it to build the labview code.  I hope this helps.  Keep me posted.

Regards,

GG

0 Kudos
Message 2 of 3
(3,390 Views)
I asked one of the graduate students working on a similar problem, and he pointed out that I hadn't explicitly stated in my IMAQ Create that it should be 8-bit grayscale, so it turned out the mismatched image types were causing the problem.

Thanks for your help.

Message Edited by JeffCWRU on 04-30-2007 04:34 PM

0 Kudos
Message 3 of 3
(3,389 Views)