phanein / deepwalk

DeepWalk - Deep Learning for Graphs
http://www.perozzi.net/projects/deepwalk/
Other
2.68k stars 826 forks source link

error with running scoring.py #38

Closed songzenghui closed 7 years ago

songzenghui commented 7 years ago

when i run scoring.py , the error occurs: TypeError: load_word2vec_format() got an unexpected keyword argument 'norm_only'

GTmac commented 7 years ago

DeepWalk uses Gensim 0.10.2: https://github.com/phanein/deepwalk/blob/master/requirements.txt#L6

My guess is that you are using a newer version of Gensim, and they change the arguments for this function: https://github.com/RaRe-Technologies/gensim/blob/7115c7228156ff28c23481f722b6ed3813cbc613/gensim/models/word2vec.py#L1447

So switching back to Gensim 0.10.2 should works.

songzenghui commented 7 years ago

thanks. it worked