I want to detect a specific shape which is combination of 2 shapes Pentagon and a square. However side of a square should be around 3 times of a pentagon to match a valid shape as shown in the image.
I'm learning different image processing techniques for my requirement.
Contour Detection: Issue is knowing there are 7 corners is not enough as x : 3x need to be validated.
Haar features: Issue is images consist of background and there are text inside these object. So haar will not optimal method in my opinion.
My idea
I think may be I can detect lines corners and using side lengths I can do some math and identify the image.Is there any image processing technique that use mathematical distance, scale, location to identify object?
Original image
matching
not matching




