我正在使用colab,这是我的代码
import sent2vec
sent2vec_model = sent2vec.Sent2vecModel()
我有这个错误:
AttributeError
Traceback (most recent call last)
<ipython-input-58-a60edfdfe29c> in <cell line: 2>()
1 # Initialiser et entraîner le modèle Sent2Vec
----> 2 sent2vec_model = sent2vec.Sent2vecModel()
3 sent2vec_model.train(tokenized_names)
4
AttributeError: module 'sent2vec' has no attribute 'Sent2vecModel
安装sent2vec的正确方法是在此处克隆其存储库https://github.com/epfml/sent2vec并按照自述文件中的说明进行操作
if you install sent2vec using
$ pip install sent2vec
then you'll get the wrong package. Please follow the instructions in the README.md to install it correctly.