Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vickypandey14/convert-pdf-into-image-by-python
This Python script converts each page of a PDF document into separate image files. It utilizes the PyMuPDF library (fitz) to handle PDF operations and the Python Imaging Library (PIL) for image processing.
https://github.com/vickypandey14/convert-pdf-into-image-by-python
pdf-converter pymupdf pymupdf-fitz python python-script
Last synced: 5 days ago
JSON representation
This Python script converts each page of a PDF document into separate image files. It utilizes the PyMuPDF library (fitz) to handle PDF operations and the Python Imaging Library (PIL) for image processing.
- Host: GitHub
- URL: https://github.com/vickypandey14/convert-pdf-into-image-by-python
- Owner: vickypandey14
- License: unlicense
- Created: 2024-02-22T11:31:17.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2024-02-22T12:52:35.000Z (10 months ago)
- Last Synced: 2024-11-05T11:15:39.164Z (about 2 months ago)
- Topics: pdf-converter, pymupdf, pymupdf-fitz, python, python-script
- Language: Python
- Homepage:
- Size: 248 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PDF to Images Converter
This Python script converts each page of a PDF document into separate image files. It utilizes the PyMuPDF library (`fitz`) to handle PDF operations and the Python Imaging Library (`PIL`) for image processing.
## Usage
### Prerequisites
Make sure you have the required dependencies installed:
```bash
pip install PyMuPDF pillow
```### Running the Script
```bash
python pdf_to_images.py
```Make sure to customize the `pdf_path` and `output_folder` variables in the script according to your PDF file location and desired output folder.
## Example
```python
if __name__ == "__main__":
pdf_path = "path/to/your/pdf/document.pdf"
output_folder = "path/to/your/output/folder"
pdf_to_images(pdf_path, output_folder)
```## License
This project is licensed under the [MIT License](LICENSE) - see the [LICENSE](LICENSE) file for details.