BERTopic 关于二维文档的空白标签问题和可视化 以下是文本内容的翻译结果: 关于二维文档的空白标签问题和可视化

c9x0cxw0  于 2个月前  发布在  其他
关注(0)|答案(5)|浏览(35)

当我在.py脚本中运行topicmodeling时,我遇到了这个问题。

bogh5gae

bogh5gae1#

感谢您的分享,但我对您的 .py 脚本不熟悉。我需要更多的信息来了解这里发生了什么。您能与我分享您使用的 完整 BERTopic 代码以及版本吗?

lnxxn5zx

lnxxn5zx2#

谢谢你的回复。
正常的导入llama 2,然后使用write_html函数保存可视化。

from sentence_transformers import SentenceTransformer
neskvpey

neskvpey3#

Could you check what labels you set in llama2_labels ? There might be something going on there that Llama 2 might not have created all labels.

k5ifujac

k5ifujac4#

我检查了它们,但我认为问题出在我用Python脚本运行时。当我在Jupyter Notebook中运行时它工作得很好,但我需要它在.py文件中,这样就可以自动化。

8ftvxx2r

8ftvxx2r5#

That's strange as the output is actually HTML I believe and should not render differently in a Jupyter Notebook compared to using .py

相关问题