使用Python挖掘文本的PDF文件? [英] text-mine PDF files with Python?

查看:173
本文介绍了使用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.

这篇关于使用Python挖掘文本的PDF文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆