python中的doc_在windows 10上读取python中的.doc文件
this
,但我的问题是使用textract
工作。我正在寻找(a)让textract在windows 10上工作的方法,或(b)另一种解决方案。
我正在构建一个需要读取各种类型文件的系统。我已经设置了pdfminer来阅读.pdfs,并且基于概述的过程
here
我安装了textract,现在还可以读取.docx文件。然而,textract依赖antiword来读取.doc文件,即使按照说明操作,我也无法让它工作
here
下面是运行textract.process('d.doc')时的错误(忽略第一个错误,文件肯定存在):
Traceback (most recent call last):
File "C:\ProgramData\Anaconda3\lib\site-packages\textract\parsers\utils.py", line 84, in run
stdout=subprocess.PIPE, stderr=subprocess.PIPE,
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 709, in __init__
restore_signals, start_new_session)
File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 997, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "C:\ProgramData\Anaconda3\lib\site-packages\textract\parsers\__init__.py", line 77, in process
return parser.process(filename, encoding, **kwargs)
File "C:\ProgramData\Anaconda3\lib\site-packages\textract\parsers\utils.py", line 46, in process
byte_string = self.extract(filename, **kwargs)
File "C:\ProgramData\Anaconda3\lib\site-packages\textract\parsers\doc_parser.py", line 9, in extract
stdout, stderr = self.run(['antiword', filename])
File "C:\ProgramData\Anaconda3\lib\site-packages\textract\parsers\utils.py", line 91, in run
' '.join(args), 127, '', '',
textract.exceptions.ShellError: The command antiword d.doc failed with exit code 127
python中的doc_在windows 10上读取python中的.doc文件相关推荐
- 如何在Windows 10上安装Python
Installing and using Python on Windows 10 is very simple. The installation procedure involves just t ...
- 如何在Windows 10上压缩(和解压缩)文件
The ZIP file format reduces the size of files by compressing them, saving disk space, and reducing n ...
- 如何在Windows 10上跳过回收站以删除文件
Windows 10 normally sends files you delete to the Recycle Bin. They'll be kept until you empty it-or ...
- windows系统中pyyaml_关于python:如何在Windows 10上安装pyYAML
我试图从Windows 10上的源代码安装pyYAML.我从https://pypi.python.org/pypi/PyYAML下载了PyYAML 3.11. 运行setup.py时出现错误:[Wi ...
- 如何在Windows 10上使用Microsoft Defender扫描文件或文件夹中的恶意软件
On Windows 10, Microsoft Defender (formerly called "Windows Defender") always scans files ...
- 从一台 Windows 10 上共享文件夹到Docker中的Volume卷
本文的内容是之前三篇内容的结合: <Docker for Windows 自动共享本机文件的脚本示例> http://blog.csdn.net/hu_zhenghui/article/d ...
- WSL2使用Python访问Windows 10上的MongoDB报错:pymongo.errors.ServerSelectionTimeoutError: localhost:27017: [Er
WSL2使用Python访问Windows 10上的MongoDB报错:pymongo.errors.ServerSelectionTimeoutError: localhost:27017: [Er ...
- 如何在Windows 10上安装MySQL数据库服务器8.0.19
In this article, I am going to explain the step by step installation process of MySQL database serve ...
- Windows 10 上使用 CMake GUI 编译 Krita 源代码并使用 MinGW 64 作为构建工具
krita系列文章目录 提示:这里可以添加系列文章的所有文章的目录,目录需要自己手动添加 例如:第一章 Python 机器学习入门之pandas的使用 提示:写完文章后,目录可以自动生成,如何生成可参 ...
最新文章
- WhatsApp与Gmail用户数均突破10亿大关
- Linux内存申请机制
- ubuntu安装python3.8_将 Ubuntu 16 和 18 上的 python 升级到最新 python3.8 的方法教程
- 关于JSON的简介及取值以及常见面试题
- 使用selenium进行密码破解(绕过账号密码JS加密)
- 为什么分布式一定要有redis,redis的一些优缺点
- 用Barcode生成条形码图片
- .NET反编译工具:de4dot
- 计算机在线拥有,电路在线计算器
- 计算机等级考试ppt怎么做,计算机等级考试PPT教学.ppt
- Android植入Wooboo广告教程
- Python 爬取微信公众号文章
- 介绍 json_介绍
- POSIX是什么有什么用
- 2022开年书单:7本程序员专业书籍与您相约
- 【mysql】记一次selectOne报错
- 小程序云开发中如何生成pdf?
- 电源中静态电流IQ理解
- 重返研一,你会怎么过?
- 复变函数与积分变换笔记(一)
热门文章
- 使用代码删除IBASE object component
- SAP ABAP实用技巧介绍系列之Debug XSLT transformation
- nodejs因buildpack指定不当部署到CloudFoundry后出的一个错误
- 如何使用SAP Gigya的登录服务和您的网站集成
- 使用JavaScript调用手机平台上的原生API
- 在SAP云平台的CloudFoundry环境下消费ABAP On-Premise OData服务
- 基于html5游戏毕业设计数据流图,基于HTML5的网络拓扑图设计
- python 连续比较_For循环比较python中以前的值
- spring boot 跨域请求_SpringBoot 系列教程 web 篇之自定义请求匹配条件 RequestCondition...
- 使用git克隆GitHub仓库时报错解决方案