Embossed-Text-Reader
                                
                                 Embossed-Text-Reader copied to clipboard
                                
                                    Embossed-Text-Reader copied to clipboard
                            
                            
                            
                        Not working on given images
@DevashishPrasad
I tried on following image but it does not gives expected output .

Can you please help me on these ? Also which research paper r u referging?
The text on your metal is not embossed, its engraved. So, you need to filter it more. Try tuning the parameters of canny. Also try to change dilation and erosion iterations. I am not referring any paper. I m referring the official documentation of opencv python. https://docs.opencv.org/3.1.0/da/d22/tutorial_py_canny.html
@harshalcse I used the code successfully on a very similar engraved pattern, but I ran the tesseract magic directly on the "dilated" version of the image, and skipped all the mask transformation.
That is, in this line:
# Tesseract OCR on the image temp = pytesseract.image_to_string(th1)
Replace "th1" by "dilate"
Oh. One difference is that in my case my text is perfectly horizontal. I don't know if it's making it easier for tesseract?
If it still doesn't work, display the blurred/edged/dilated/new image/inverterd threshold version of the image and try to figure out at which step it becomes unreadable by tesseract, and then try to tweak it. But you're engraving is quite clear, it's definitely doable.