title: How to detect test strips with OpenCV?
body: <p>I'm a newbie to computer vision, and I'm trying to detect all the test strips in this image:</p>
  
  <p><a href="https://i.stack.imgur.com/KbxN6.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/KbxN6.jpg" alt="source"></a></p>
  
  <p>The result I'm trying to get:</p>
  
  <p><a href="https://i.stack.imgur.com/pgH6Z.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/pgH6Z.jpg" alt="result"></a></p>
  
  <p>I assume it should be very easy, because all the target objects are in rectangular shape and have a fixed aspect ratio. But I have no idea which algorithm or function should I use. </p>
  
  <p>I've tried edge detection and the 2D feature detection example in OpenCV, but the result is not ideal. How should I detect these similar objects but with small differences?</p>
  
  <p><strong>Update:</strong></p>
  
  <p>The test strips can vary in colors, and of course, the shade of the result lines. But they all have the same references lines, as showing in the picture:</p>
  
  <p><a href="https://i.stack.imgur.com/nhXiX.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nhXiX.jpg" alt="variations of test strips"></a></p>
  
  <p>I don't know how should I describe these simple features for object detection, as most examples I found online are for complex objects like a building or a face. </p>