BERTopic fit_transform error #13778
Unanswered
Ivanhoeee
asked this question in
Help: Installation
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm completely new to BERTopic and have some real difficulties getting it to work.
I work locally and have created a new conda environment and have installed bertopic (0.16.2) with all its dependencies.
After running the following code which is taken from BERTopic's quick start:
from bertopic import BERTopic
topic_model = BERTopic(language="english")
topics, probs = topic_model.fit_transform(["this is some data",
"and this too is some data",
"cars bikes planes"])
I get the following error:
ValueError: Unrecognized model in sentence-transformers/all-MiniLM-L6-v2. Should have a
model_type
key in its config.json, or contain one of the following strings in its name: albert, align, altclip, aria, aria_text,.......xlm-roberta-xl, xlnet, xmod, yolos, yoso, zamba, zamba2, zoedepthTrying this gives the same error:
from sentence_transformers import SentenceTransformer
model = SentenceTransformer(
'sentence-transformers/all-MiniLM-L6-v2')
Any idea how to proceed?
Beta Was this translation helpful? Give feedback.
All reactions