pdftotext-3.0.0
توضیحات
Simple PDF text extraction
| ویژگی | مقدار |
|---|---|
| سیستم عامل | - |
| نام فایل | pdftotext-3.0.0 |
| نام | pdftotext |
| نسخه کتابخانه | 3.0.0 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Jason Alan Palmer |
| ایمیل نویسنده | jalanpalmer@gmail.com |
| آدرس صفحه اصلی | https://github.com/jalan/pdftotext |
| آدرس اینترنتی | https://pypi.org/project/pdftotext/ |
| مجوز | MIT |
# pdftotext
[](https://pypi.python.org/pypi/pdftotext)
[](https://github.com/jalan/pdftotext/actions)
[](https://pepy.tech/project/pdftotext)
Simple PDF text extraction
```python
import pdftotext
# Load your PDF
with open("lorem_ipsum.pdf", "rb") as f:
pdf = pdftotext.PDF(f)
# If it's password-protected
with open("secure.pdf", "rb") as f:
pdf = pdftotext.PDF(f, "secret")
# How many pages?
print(len(pdf))
# Iterate over all the pages
for page in pdf:
print(page)
# Read some individual pages
print(pdf[0])
print(pdf[1])
# Read all the text into one string
print("\n\n".join(pdf))
```
## OS Dependencies
These instructions assume you're on a recent OS. Package names may differ for an
older OS.
### Debian, Ubuntu, and friends
```
sudo apt install build-essential libpoppler-cpp-dev pkg-config python3-dev
```
### Fedora, Red Hat, and friends
```
sudo yum install gcc-c++ pkgconfig poppler-cpp-devel python3-devel
```
### macOS
```
brew install pkg-config poppler python
```
### Windows
Currently tested only when using conda:
- Install the Microsoft Visual C++ Build Tools
- Install poppler through conda:
```
conda install -c conda-forge poppler
```
## Install
```
pip install pdftotext
```
نحوه نصب
نصب پکیج whl pdftotext-3.0.0:
pip install pdftotext-3.0.0.whl
نصب پکیج tar.gz pdftotext-3.0.0:
pip install pdftotext-3.0.0.tar.gz