LxMLS / lxmls-toolkit

Machine Learning applied to Natural Language Processing Toolkit used in the Lisbon Machine Learning Summer School
Other
223 stars 215 forks source link

Data reader fails when installing with pip #83

Closed ramon-astudillo closed 3 months ago

ramon-astudillo commented 6 years ago

What happens:

When installing the guide the absolute paths are different and the lxmls.readers do not find the data.

How to solve this:

Dependencies of local files inside code should be avoided. One pythonic solution would be to force the user to give the data path when instantiating the data.

Way to reproduce:

virtualenv venv
source venv/bin/activate
pip install -r requirements.txt
pip install .    # As opposed to python setup.py develop

the run the code

import lxmls.readers.sentiment_reader as srs
corpus = srs.SentimentCorpus("books")

note that python setup.py develop will work.

ramon-astudillo commented 6 years ago

Thanks to @tjppires for not following the instructions 🗡