Search

Machine Vision Filters are Your Friend

Updated: Sep 20, 2021

Working with Machine Vision can have its surprising benefits that will surprise you sometimes.




When we are new to machine vision, we often like to look deep into the images we are obtaining and seek a clear image. We like to have the clarity, sharpness, contrast, and possibly color that we are seeing with our eyes, often failing to remember that the vision system that we are using is dependent upon itself to better understand the image based on our chosen algorithms. One must remember, “It is not what you see, but rather what the camera sees.”

Today I had one of my own challenges in this very issue. Working with a Cognex Smart that is now about 10 years old has its own set of challenges. I have had to adjust the placement of the sensor 3 different times now, with its current placement being the last one we will use for proper imaging. Then I have had to discover the proper lighting for it in is current environment. This surprisingly is running a Red light in the Visible Light Spectrum and an Infrared light as well. Both in their current placement give me the best of both worlds when it comes to illumination, but I am still running into the challenge of dealing with those false positives.

So today after fighting through the same tools day after day for several weeks now to get the right function, as I am working with several different sizes of variation along with about 5 different color variations, I stumbled upon a tool I had totally forgotten about. The amazing Filter tool. There are several options for filtering, but the Binarize function worked the best for my application. I will boldly admit adding this into my vision program was a real game changer for me.

Now there are two things I should mention about using this filter. First this changed every part of my program from the get-go. I no longer needed some of the tools I was regularly relying on, then it also used some other tools that I now needed more regularly. So, knowing this, I had to go about changing all my tools to work with this Binarize function, but for me this was no issue as I had already done this several times in my programming.

Second is if you are in a high-speed environment, this may not be an option for you as it does add to your processing time when you filter your image. In my case the customer is running parts at 90 parts a minute, when they are really running parts, otherwise it is more like 60 parts a minute, so having a program that takes 28.8 ms to process is the least of my concern at this point.

6 views0 comments

Recent Posts

See All