在大图像中找到小的部分透明图像的坐标(find coordinates of small partially-transparent image within a large image)
corner images的坐标。 使用这些坐标，我想确定特定的“感兴趣区域”，以便我能够在呈现图像时聚焦这些区域或从图像中剪切这些区域。
corner items（它们只是同一原始图像的90度旋转），并将它们与大图像“比较”。 在大图像中，
corner items可能“非常接近”其他图形内容。 因此，简单的逐块身份测试可能会失败。 “透明度”应被视为“不关心”。
I am looking for a way to programmatically (without using any graphical user interface) find the coordinates of a small image within a large image.
My aim is to find the coordinates of small
corner imageswithin a larger information image. With these coordinates I want to determine specific "regions of interest" so that I would be able to focus on these regions while presenting the image or cut these regions from the image.
corner imagescould look like these (please ignore the blue numbers, as they are only comments. I'd like to use gray PNG graphics with transparency):
1top left corner
2bottom left corner
3bottom right corner
4top right corner
corner imagesare placed at certain positions within the large image:
Each set of
corner iconsdefines a "region of interest" (how to determine which of the multiple top left corners belongs to which region would be another issue, though).
I'd like to use a free/open source library together with command line operation or a Python interface. It seems that the
ImageMagicklibrary looks pretty close to a possible solution. But any other technology would be fine if it solves this problem.
With e.g. the
ImageMagicklibrary I would like to check the four
corner itemssequentially (they are just 90 degree rotations of the same original image) and "compare" each of them with the large image. Within the large image, it would be more than possible that the
corner itemsreside "very near" to other graphical content. So, a simple block-wise identity testing would possibly fail. "Transparency" should be considered as "don't care".
What tool and process could I use to get the absolute x- and y-positions of such a small image within a larger one?