Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

which is the python version required for this code? #4

Open
VijayIyer opened this issue Nov 1, 2021 · 4 comments
Open

which is the python version required for this code? #4

VijayIyer opened this issue Nov 1, 2021 · 4 comments

Comments

@VijayIyer
Copy link

  1. When I do 'pip install -r requirements.txt', I get errors when pandas version starts to download, and pip install of dependencies stops.
  2. Is there equivalent code to this with latest versions of torchtext and torch?
@HarithaMK14
Copy link

Hi @VijayIyer : Facing similar kind of issues, have you found answers for your questions. If so, kindly share
Thanks in advance.

@EricvanSchaik
Copy link

EricvanSchaik commented Feb 28, 2022

Same problem here, pandas 0.22.0 is only compatible with python 2.7, 3.5 and 3.6, while torch 1.2.0 doesn't work with those versions for me

@VijayIyer
Copy link
Author

I manually installed the version specific packages. There was actually quite a few workarounds I had to do. This was a while back so I don't recall very well. Below are some changes I had to make to make it work.

importing gensim for gensim.downloader as api
installed gensim==3.8.3
aggregate.py -> api.load for w2v takes time
add encoding=utf-8 for each read

..............error in generate.py
from sumeval.metrics.rouge import RougeCalculator
from sumeval.metrics.bleu import BLEUCalculator
...........

...installed sumeval in generate.py

....sacrebleu 1.5.1

....needed to make prepare_default to prepare_yelp-default midway

...get_agg_name in utils.py....change in name reading

.......torchtext/utils.py line 130 replacing maxInt in place of sys.maxsize...for windows??

....csv.writer takes newline="" argument

@EricvanSchaik
Copy link

EricvanSchaik commented Mar 2, 2022

To get the packages to work, I used python 3.6.4, sumeval 0.1.7 and also sacrebleu 1.5.1. and gensim 3.8.3 To get the right PyTorch package I also had to provide the download link, so pip install torch==1.2.0 -f https://download.pytorch.org/whl/torch_stable.html (I use Windows and PyPi didn't have the torch 1.2.0 windows binaries). I also used torchtext 0.5.0 to get rid of the maxInt overflow bug.

I also managed to fix most of the other bugs (altough it still doesn't fully work on the default dataset). I pushed it to my fork https://github.com/EricvanSchaik/opiniondigest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants