使用Python挖掘文本的PDF文件?

问题描述:

是否有用于python的软件包/库,可以让我打开PDF,并在文本中搜索某些单词?

Is there a package/library for python that would allow me to open a PDF, and search the text for certain words?

使用 PyPdf2 您可以使用 extractText()方法提取pdf文本并进行处理.

Using PyPdf2 you can use extractText() method to extract pdf text and work on it.

更新:由于@Aditya Kumar的注意,更改了文本以引用PyPdf2.

Update: Changed text to refer to PyPdf2, thanks to @Aditya Kumar for heads up.