I set my own umap (with random_state=0), hdbscan (with random_state=0), ctfidf_model, and representation_model, and then passed these four modules into the BERTopic() function. However, my results are different every time I run the code. What should I do? #2214
superseanyoung
started this conversation in
General
Replies: 1 comment 5 replies
-
Could you create an issue for this as a bug and fill in all the information listed there? It's difficult to say what is happening without more context. Also, make sure you provide the full code. |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
topic_model = BERTopic(embedding_model=transformer_model,
min_topic_size=3,
verbose=True,
umap_model=umap_model,
hdbscan_model=hdbscan_model,
ctfidf_model=ctfidf_model,
representation_model=representation_model,
#top_n_words=10,
#min_topic_size=10,
#nr_topics=None,
#low_memory=False,
#calculate_probabilities=True
)
topics,probs= topic_model.fit_transform(sentences,embeddings=embeddings)
Beta Was this translation helpful? Give feedback.
All reactions