You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
520 B
17 lines
520 B
4 weeks ago
|
import os
|
||
|
|
||
|
|
||
|
# 可执行文件路径
|
||
|
mtef = r'D:\dsWork\dsProject\dsRag\mtef-go-3\mtef-go.exe'
|
||
|
# 源文件路径
|
||
|
sourceDocx = r'D:\dsWork\dsProject\dsRag\static\Txt\化学方程式_CHEMISTRY_1.docx'
|
||
|
# 输出文件路径
|
||
|
output_file = r"d:\output.txt" # 可修改为您需要的路径
|
||
|
|
||
|
# 构建命令
|
||
|
command = mtef + r" -w " + sourceDocx + " -o " + output_file
|
||
|
os.system(command)
|
||
|
# 把output.txt里的内容打印出来看看
|
||
|
with open(output_file, 'r', encoding='utf-8') as file:
|
||
|
print(file.read())
|