jhlau / doc2vec

Python scripts for training/testing paragraph vectors
Apache License 2.0
644 stars 192 forks source link

AttributeError: 'Doc2Vec' object has no attribute 'neg_labels' #22

Closed masa-nudt closed 6 years ago

masa-nudt commented 6 years ago

While I'm loading your pre-trained DOC2VEC models, aka. English Wikipedia DBOW (1.4GB) and Associated Press News DBOW (0.6GB) , error AttributeError: 'Doc2Vec' object has no attribute 'neg_labels' occurs.

I also notice that in the loaded model, negative is set to 5 but no neg_labels are provided.

jhlau commented 6 years ago

You'll need to use my forked version of gensim: https://github.com/jhlau/gensim

masa-nudt commented 6 years ago

Yes, I'am using your forked version. I noticed that there are three bin files within each model. I assume that I should load all of them, but how can I achieve this?

Thanks for your patience, I sorry to disturb you again.

rbarriaa commented 6 years ago

Hi

I am facing the same problem.

I am using the forked version at https://github.com/jhlau/gensim, but still after loading model="doc2vec.bin" from the AP News, I get an error "Doc2Vec object has no attribute 'neg_labels'".

Any ideas how to solve this?

Kind Regards, Rodrigo

mmunsi2 commented 5 years ago

Hello, I'm facing the same issue.

Abhimanyu100 commented 5 years ago

I'm too facing this same issue.

rbarriaa commented 5 years ago

Hi,

After several tries, I ended up using an older version, that didnt have that problem

El mar., 10 sep. 2019 10:13 a. m., Abhimanyu notifications@github.com escribió:

I'm too facing this same issue.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/jhlau/doc2vec/issues/22?email_source=notifications&email_token=AA7US4NAOEJSAQDOS5OEGK3QI6MRHA5CNFSM4FC7ZLV2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD6LBBAQ#issuecomment-529928322, or mute the thread https://github.com/notifications/unsubscribe-auth/AA7US4OHN6C3DLF432MFCDTQI6MRHANCNFSM4FC7ZLVQ .

Abhimanyu100 commented 5 years ago

Hey, @rbarriaa Which library version you are talking about?

parshin76 commented 2 years ago

I'm also facing the same issue. @rbarriaa Can you please explain more what is this older version?