没有名为:bert_嵌入的模块。python

2024-10-02 02:38:17 发布

您现在位置:Python中文网/ 问答频道 /正文

所以我使用Colab,导入bert_嵌入时遇到问题

我使用:

!pip install bert-embedding
from bert_embedding import BertEmbedding
bert_embedding = BertEmbedding()

Error: No module named bert_embedding

但在文档中,它清楚地表明我应该这样称呼它:https://pypi.org/project/bert-embedding/

有没有办法解决这个问题

塔克斯


Tags: installpipnofrom文档httpsimportpypi
1条回答
网友
1楼 · 发布于 2024-10-02 02:38:17

关于bert embedding项目中github上已解决的问题,我建议您通过

安装最新的gluonnlp包 pip install https://github.com/dmlc/gluon-nlp/tarball/master

https://github.com/imgarylai/bert-embedding/issues/3-这就是我所指的问题。这应该对你有用

相关问题 更多 >

    热门问题