# -*- coding: utf-8 -*-
#读取pdf文档
from pdfminer.converter import PDFPageAggregator
from pdfminer.layout import LAParams
from pdfminer.pdfparser import PDFParser,PDFDocument
from pdfminer.pdfinterp import PDFResourceManager, PDFPageInterpreter
from pdfminer.pdfdevice import PDFDevice
import pdfminer.pdfinterp
#获取文档对象
fp = open("naacl06-shinyama.pdf","rb")
#创建一个与文档关联的解释器
parser=PDFParser(fp)
#PDF文档对象
doc = PDFDocument()
python读取pdf文档-实战
最新推荐文章于 2024-07-10 11:49:26 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)