Image processing problem (counting is hard )

AI Thread Summary
The discussion revolves around a challenge in processing images containing horizontal lines, where the goal is to measure the width of each line while filtering out noise. The user has identified that the images contain small holes and extraneous pixels, complicating the measurement process. They propose using a pattern recognition algorithm to differentiate between actual line segments and noise. After some exploration, they found that the right image pattern recognition algorithm can significantly enhance the scanning process. The conversation highlights the importance of effective noise filtering in image processing tasks.
the.drizzle
Messages
10
Reaction score
0
Hiya! Long time registrant, have not used these forums is years though...

Anyhow, the problem I have is that I need to collect data from a very large number of images that are essentially horizontal lines on a page. I've attached a sample here, which has been processed to find the edges of the lines--the attached file shows the edges of nine lines, unevenly spaced. I want to measure the width of each line over all pixels, and export that data to an external file for later processing.

In theory this would be quite simple; start at the top (or bottom) of the page, scan down (up) until one hits a red pixel, record that position, record the position of the next one, and the difference gives us the width for that line at that position. We then continue down (up) for all n-lines, and across the page as well.

The tricky bit though is that images are noisy. That is, there are small "holes" in the lines and a few outside them as well. What I need to do is figure out a method of deciding which bits are noise, and which bits are not. I can't manually delete the "holes" from the data set, as there are literally thousands of these to process, and that would take weeks.

I'm thinking some sort of pattern recognition algorithm would be a good idea, but I'm not sure how they work...

Thus, what I'm looking for here are some possible ideas as to how one might go about filtering the noise from the image in some manner, or pehaps an algorithm that may be able to decide which points are line and which ones are noise when scanning the image. I've been at this for some time now, and am running out of ideas...

Thanks in advance for any help!
 

Attachments

  • red_line.jpg
    red_line.jpg
    28.6 KB · Views: 477
Engineering news on Phys.org
OK, got it sorted out and churning away nicely.
 
Yep. the image pattern recognition algorithm can influence the image scanning effection, as for how to set the image recognition algorithm and more info algotithm, you can have a search.
 
Posted June 2024 - 15 years after starting this class. I have learned a whole lot. To get to the short course on making your stock car, late model, hobby stock E-mod handle, look at the index below. Read all posts on Roll Center, Jacking effect and Why does car drive straight to the wall when I gas it? Also read You really have two race cars. This will cover 90% of problems you have. Simply put, the car pushes going in and is loose coming out. You do not have enuff downforce on the right...
I'm trying to decide what size and type of galvanized steel I need for 2 cantilever extensions. The cantilever is 5 ft. The space between the two cantilever arms is a 17 ft Gap the center 7 ft of the 17 ft Gap we'll need to Bear approximately 17,000 lb spread evenly from the front of the cantilever to the back of the cantilever over 5 ft. I will put support beams across these cantilever arms to support the load evenly
Thread 'What's the most likely cause for this carbon seal crack?'
We have a molded carbon graphite seal that is used in an inline axial piston, variable displacement hydraulic pump. One of our customers reported that, when using the “A” parts in the past, they only needed to replace them due to normal wear. However, after switching to our parts, the replacement cycle seems to be much shorter due to “broken” or “cracked” failures. This issue was identified after hydraulic fluid leakage was observed. According to their records, the same problem has occurred...
Back
Top