Skip to content

Commit 27a6288

Browse files
authored
Merge pull request #547 from PyThaiNLP/fix-gensim
Fix gensim #546
2 parents 338d5b4 + d8fff27 commit 27a6288

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

.github/workflows/test.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ name: Unit test and code coverage
22

33
on:
44
push:
5-
branches:
6-
- dev
75
paths-ignore:
86
- '**.md'
97
- 'docs/**'

pythainlp/word_vector/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ def sentence_vectorizer(text: str, use_mean: bool = True) -> ndarray:
257257
elif word == "\n":
258258
word = _TK_EOL
259259

260-
if word in _MODEL.index2word:
260+
if word in _MODEL.index_to_key:
261261
vec += _MODEL.word_vec(word)
262262

263263
if use_mean:

0 commit comments

Comments
 (0)