Skip to content

Commit 9d98a4a

Browse files
committed
sklearn api change fix
1 parent d625b50 commit 9d98a4a

File tree

5 files changed

+6
-4
lines changed

5 files changed

+6
-4
lines changed

docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
author = 'Dimo Angelov'
3030

3131
# The full version, including alpha/beta/rc tags
32-
release = '1.0.27'
32+
release = '1.0.28'
3333

3434

3535
# -- General configuration ---------------------------------------------------

requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
numpy>=1.20.0
2+
scikit-learn>=1.2.0
23
pandas
34
gensim>=4.0.0
45
umap-learn>=0.5.1

setup.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
setuptools.setup(
77
name="top2vec",
88
packages=["top2vec"],
9-
version="1.0.27",
9+
version="1.0.28",
1010
author="Dimo Angelov",
1111
author_email="dimo.angelov@gmail.com",
1212
description="Top2Vec learns jointly embedded topic, document and word vectors.",
@@ -28,6 +28,7 @@
2828
install_requires=[
2929
'numpy >= 1.20.0',
3030
'pandas',
31+
'scikit-learn >= 1.2.0',
3132
'gensim >= 4.0.0',
3233
'umap-learn >= 0.5.1',
3334
'hdbscan >= 0.8.27',

top2vec/Top2Vec.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -578,7 +578,7 @@ def return_doc(doc):
578578
# preprocess vocabulary
579579
vectorizer = CountVectorizer(tokenizer=return_doc, preprocessor=return_doc)
580580
doc_word_counts = vectorizer.fit_transform(tokenized_corpus)
581-
words = vectorizer.get_feature_names()
581+
words = vectorizer.get_feature_names_out()
582582
word_counts = np.array(np.sum(doc_word_counts, axis=0).tolist()[0])
583583
vocab_inds = np.where(word_counts > min_count)[0]
584584

top2vec/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
from top2vec.Top2Vec import Top2Vec
22

3-
__version__ = '1.0.27'
3+
__version__ = '1.0.28'

0 commit comments

Comments
 (0)