我已经使用 pyinstaller 创建了我的 python 应用程序的独立应用程序
pyinstaller --windowed app.py
它实际上在我的计算机上运行并且按预期工作,但是当我在我朋友的计算机上尝试它时,它不起作用。它运行但不知何故无法处理文本。
这是使用的库:
import tkinter as Tk
import tkinter.ttk as ttk
import tkinter.scrolledtext as ScrollTxt
from tkinter import END,E,W,filedialog,messagebox
from nltk.tokenize import sent_tokenize, RegexpTokenizer, word_tokenize
import math
import fileinput
from textblob import TextBlob as tb
from nltk.tag import pos_tag, map_tag
from nltk.corpus import stopwords
如果你想查看结果文件:https://www.dropbox.com/s/mfdnaaoik7w0r23/TextSummaryV73.rar?dl=0 https://www.dropbox.com/s/mfdnaaoik7w0r23/TextSummaryV73.rar?dl=0
有人知道出了什么问题或缺少什么吗?
我认为它是 nltk 或 textblob,任何人都可以帮助如何将这些文件添加到包中吗?
EDIT:我已使用规范文件将 nltk 和 textblob 添加到 Python 应用程序的目录中。现在的问题是,如何让程序知道这两个导入已经在目录中了?