3

For text detection, I split the entire image for better results (all those images with the same dimensions having overlapping) and generate its mask(Binary image) and merge those split images into one full image(with the dimension of the original image).

image: Full image split images masked binary image

now I used to merge all these images, but the overlapped image where the text not detected removes the white patch in the image full merged mask image.

In order to overcome this issue I came to know about the stitching image in OpenCV, hence I used this link for stitching imagehttps://www.pyimagesearch.com/2018/12/17/image-stitching-with-opencv-and-python/#pyi-pyimagesearch-plus-pricing-modal, but this code doesn't work for a binary image. Is it possible to stitch binary image with overlapping in OpenCV?

1 Answer 1

2

Stitching in OpenCV python is only for panorama images(camera images) where it finds and matches the features in the image as you refer to this link:https://docs.opencv.org/master/d1/d46/group__stitching.html

if you want to get merge those image you can use it simply with PIL in python:https://pillow.readthedocs.io/en/stable/reference/Image.html#PIL.Image.Image.paste

merge those image with :image.paste(im, (x, y),mask=im) Where the mask is 255, the given image is copied as is. Where the mask is 0, the current value is preserved.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.