vi3k6i5 / GuidedLDA

semi supervised guided topic model with custom guidedLDA
Mozilla Public License 2.0
497 stars 108 forks source link

Unable to install guidedlda, please help URGENT!!!!!! assignment due #58

Open shrshdhnkr opened 3 years ago

shrshdhnkr commented 3 years ago

with pip install guidedlda error :

ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

with https://github.com/vi3k6i5/GuidedLDA cd GuidedLDA sh build_dist.sh python setup.py sdist pip install -e

'https:' is not recognized as an internal or external command, operable program or batch file. The system cannot find the path specified. 'sh' is not recognized as an internal or external command, operable program or batch file. python: can't open file 'setup.py': [Errno 2] No such file or directory

Usage:
pip install [options] [package-index-options] ... pip install [options] -r [package-index-options] ... pip install [options] [-e] ... pip install [options] [-e] ... pip install [options] <archive url/path> ...

-e option requires 1 argument

OS details: -

64 bit, x64 processor Edition - Windows 10 Pro Version - 2004 OS build - 19041.388

Jurgita-DS commented 3 years ago

I am having similar issues with installing the package, neither of the two options are working. Any suggestions?

shrshdhnkr commented 3 years ago

I am having similar issues with installing the package, neither of the two options are working. Any suggestions?

Try using Google Collab, you won't face any issues.

gonzalezf commented 3 years ago

There is also another implementation in Gensim. Check it out: https://www.machinelearningplus.com/nlp/topic-modeling-gensim-python/

Jurgita-DS commented 3 years ago

Thank you for the suggestion.

I tried using gensim LDA model and eta parameter to define term priors for each topic but it generated exactly the same outcome as eta = 'auto'. I only get different topics if I set the weights of the seeded words to very large values. However, the quality of the topics it produces doesn't seem great - it picks up some random and rare terms that don't seem to be related with the main keywords provided as seed words.

gonzalezf commented 3 years ago

Oh I see!

I haven't noticed that. Please let me know if you find a better way or if you are able to install GuidedLDA

On Tue, Feb 16, 2021, 20:01 JJ notifications@github.com wrote:

Thank you for the suggestion.

I tried using gensim LDA model and eta parameter to define term priors for each topic but it generated exactly the same outcome as eta = 'auto'. I only get different topics if I set the weights of the seeded words to very large values. However, the quality of the topics it produces doesn't seem great - it picks up some random and rare terms that don't seem to be related with the main keywords provided as seed words.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/vi3k6i5/GuidedLDA/issues/58#issuecomment-780173395, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAO3NG5UEHZ2BRPCYZN4LDLS7L2OJANCNFSM4VPKZOAA .

gonzalezf commented 3 years ago

Hi @Jurgita-DS, I hope you are doing well! Did you be able to get better results using GuidedLda on Gensim? Or did you be able to install guidedLda? I am having trouble getting good results.

Jurgita-DS commented 3 years ago

Unfortunately I wasn't able to install guidedlda. I tried setting eta parameter in Gensim LDA, however, I wasn't able to achieve good quality topics either. When setting eta in Gensim the weights for the seed words need to be really high in order to make any difference in the model, but then the list of other words selected in each topic looks almost random. I ended up using Tomotopy package https://github.com/bab2min/tomotopy. LDAModel allows setting term priors. I haven't managed to get a good quality model with the topics I was expecting (yet), but I can see the output changing in the right direction when the term priors are set. Hope this helps.

hhagedorn commented 3 years ago

From what you wrote I am not sure if this has been tried yet, but for me installing the module in the version found in pull request #56 (along with how to install from the forked repo) fixed the issue on my environment.

pat266 commented 3 years ago

hey @shrshdhnkr how were you able to install GuidedLDA in Google Colab? I am trying to install it but got "ERROR: Failed building wheel for guidedlda" and

"ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-p_6r2bg5/guidedlda/setup.py'"'"'; file='"'"'/tmp/pip-install-p_6r2bg5/guidedlda/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /tmp/pip-record-mkuo0x9p/install-record.txt --single-version-externally-managed --compile Check the logs for full command output."

Are there any ways I can install GuidedLDA in Google Colab?

hhagedorn commented 3 years ago

In Google Colab you are also able to pip install from github repositories, thus you can also install the version from #56.

It should work like this: !pip install git+https://github.com/alexeyegorov/GuidedLDA

For python 3.7 use: !pip install git+https://github.com/CatalinVoss/GuidedLDA