title: Extracting scanned pages from PDF using python
body: <p>I have a lot of <code>PDF</code> files, which are basically scanned documents so every page is one scanned image. I want to perform <code>OCR</code> and extract text from those files. I have tried <code>pytesseract</code> but it does not perform <code>OCR</code> directly on <code>pdf</code> files so as a work around, I want to extract the <code>images</code> from <code>PDF</code> files, save them in directory and then perform <code>OCR</code> using <code>pytesseract</code> on those images directly. Is there any way in python to extract scanned images from <code>pdf</code> files? or is there any way to perform <code>OCR</code> directly on pdf files?</p>