cvangysel / pytrec_eval

pytrec_eval is an Information Retrieval evaluation tool for Python, based on the popular trec_eval.
http://ilps.science.uva.nl/
MIT License
290 stars 32 forks source link

error when installing using pip #42

Closed issam-hub closed 1 year ago

issam-hub commented 1 year ago

hello everyone, so basically i'm using windows and i'm trying to install python-terrier and since pytrec_eval is one of the dependencies, there is this error that appears when installing it and break the whole thing: raise ValueError("path '%s' cannot be absolute" % pathname) ValueError: path '/tmp/tmpgd7izyps/trec_eval-9.0.8/convert_zscores.c' cannot be absolute any solutions ??

seanmacavaney commented 1 year ago

It's unexpected that it's building from source, given the binaries are distributed on pypi. Which Python version and OS version are you using?

issam-hub commented 1 year ago

windows 10 and python 3.11.1

seanmacavaney commented 1 year ago

It looks like there are builds available for various linux distributions on py11, but not Windows. We should certainly add them, but I'm not sure how soon it will happen. Any chance you could bump down to Python 3.10 for the time being?

Source: https://pypi.org/project/pytrec-eval-terrier/#files

issam-hub commented 1 year ago

ah ok, so now if i switch to python 3.10 it will install normal right ?

seanmacavaney commented 1 year ago

It should -- it's just that there's not a pre-built Windows binary for Python 11, so it tries to build from scratch. And that process can be tricky/error-prone due to differences in the environment (e.g., which compilers are installed, etc.)

But there are pre-built Windows binaries for Python 3.7-3.10.

issam-hub commented 1 year ago

alright, thanks for the help