Cómo puedo medir distancias automaticamente ?, How I can automatically measure distances?

1 view (last 30 days)
I'm working with lots of images and I need to measure the distance from the bottom edge to an edge of this, I need to do it with a lot of images and automatic way
  3 Comments
Image Analyst
Image Analyst on 1 Nov 2014
Show another image or two, so we know if the cable and the blue scale are always somewhere in the photo, and if they are in the same location each time, and if the exposure and colors of the sand and overhead clutter are always the same.

Sign in to comment.

Answers (2)

Image Analyst
Image Analyst on 1 Nov 2014
You need to spatially calibrate your image. Fortunately you already have a blue scale in the image, so you can just use or adapt my spatial calibration demo, attached.

Image Analyst
Image Analyst on 1 Nov 2014
It's too much work for me to do it for you but what I would do is to assume that the orange cable and the blue scale are always there. Then I'd do there steps
  1. Convert RGB into hsv color space,
  2. Threshold the S channel to get high S areas (the cable and blue scale) then set those pixels to zero in the v channel.
  3. Take the histogram of the V channel, but ignore the blackened pixels at bin 0. Find the big hump - presumably it's the large sand area on the bottom.
  4. Threshold the v channel to get just the sand.
  5. Use activecontour (demo attached) to get the "envelope" of the sand, which will jump across the gaps where the blackened cable and scale are as well as give you a smooth upper border.
Code that up and let us know how it goes.

Categories

Find more on Images in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!