-
-
Save AvikantSrivastava/092016a7713b981b89b5ada46c6652e4 to your computer and use it in GitHub Desktop.
PDF
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Depends on pdf2image and poppler | |
# import module | |
from pdf2image import convert_from_path | |
# Store Pdf with convert_from_path function | |
images = convert_from_path('example.pdf') | |
for i in range(len(images)): | |
# Save pages as images in the pdf | |
images[i].save('page'+ str(i) +'.jpg', 'JPEG') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment