Filtering kinda "half-toned" image for OCR processing I have a scanned PDF material to which I want to add hidden text layer, so I could index the document. I used ghostscript black and white tiff output device (tiffg4) to extract pages as tiff images, and here is example of what they look like:



Processing this image with tesseract, does not give good results.
Changing ghostscript output DPI (600, 300, 150, 96) shows that image at 96 DPI gives best result from tesseract but it's still not satisfactory.

Now I thought to ask for advice which filter would enhance this image for OCR processing.

I could use imagemagick, or numpy/scipy/ndimage
What you really require is probably some morphological operation like dilation followed by erosion. This is called as Closing operation. May be in your case- just dilation itself might be good. 

There was a similar question asked previously - which can help with other aspects. 

monochrome (1-bit black-and-white) image conversion

How do I reconstruct text from an image using only morphological operations?