Search code examples
pythonopencvimage-processingcomputer-visionedge-detection

Measuring the width of a hot steel plate with OpenCV


I want to measure the width along the green line in the image, I applied filters like canny via OpenCV but I guess the filter didn't work (can't show the edges) because of the very high temperature. My idea is to draw 2 vertical lines and measure by drawing a line between them (I want to draw the vertical edges of the object in the picture, so). Is there any method that can work for this?

Steel Plate


Solution

  • The red component binarizes wonderfully, so it won't be a big deal to find the sides.

    For more accuracy, you can lowpass filter vertically to reduce noise. You can also do subpixel interpolation by using a linear model that straddles the edge. But I am not sure that this luxury is required for your case.

    enter image description here

    Lowpassed:

    enter image description here