I'm trying to detect rectangles in a image, I know this is possible with OpenCv but I was thinking of using ImageMagick.  
 The question is, is it possible to do it with ImageMagick? I was looking to find a equivalent `findContours` function from OpenCV in ImageMagick but I couldn't find one?

![enter image description here](https://i.stack.imgur.com/HetI7.jpg)