churchmanlab / genewalk

GeneWalk identifies relevant gene functions for a biological context using network representation learning
https://churchman.med.harvard.edu/genewalk
BSD 2-Clause "Simplified" License
127 stars 14 forks source link

Install issue #31

Closed npokorzynski closed 3 years ago

npokorzynski commented 3 years ago

Hi all,

I'm having an issue with GeneWalk install as it gets to the point of installing gensim, which continues to error out with an exit status 1 regardless of being run in a virtual environment. I'm using MacOS v11.1 and Python v3.9.

The code I'm using is as follows:

$ python3 -m venv tutorial-env $ source tutorial-env/bin/activate $ pip install genewalk

There error I get (alongside the program log) is:

ERROR: Command errored out with exit status 1: /Users/npokoryznski/tutorial-env/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/jc/43vp9sr55j714y8tzqs948580000gp/T/pip-install-3uba9rue/gensim/setup.py'"'"'; file='"'"'/private/var/folders/jc/43vp9sr55j714y8tzqs948580000gp/T/pip-install-3uba9rue/gensim/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(file);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' install --record /private/var/folders/jc/43vp9sr55j714y8tzqs948580000gp/T/pip-record-3x8walux/install-record.txt --single-version-externally-managed --compile --install-headers /Users/npokoryznski/tutorial-env/include/site/python3.9/gensim Check the logs for full command output.

I've tried to upgrade pip and setuptools to potentially resolve the issue but neither helped. I've tried a variety of other commands to circumvent administrative barriers etc as well, but since none seemed to resolve the issue I thought I would keep it simple. I'm very novice when it comes to python, bash, etc. so I fully expect to be making a trivial error somewhere here but I can't figure out the problem. Any help is appreciated!

bgyori commented 3 years ago

Hi @npokorzynski, I suspect the issue is that gensim (https://pypi.org/project/gensim/) doesn't build correctly under Python 3.9 on your environment. I tried doing

$ python3 -m venv tutorial-env
$ source tutorial-env/bin/activate
$ pip install genewalk

on a Mac with Python 3.9 and it actually worked for me so I'm not sure what the specific issue is. If you can't get the installation to work, we also supply a Dockerfile: https://github.com/churchmanlab/genewalk/blob/master/Dockerfile from which you can build a containerized environment for GeneWalk and work with it that way.

npokorzynski commented 3 years ago

@bgyori believe it or not but the Dockerfile produces the same issue with gensim. I was also unable to install gensim by itself, but again I'm not sure why. Any recommendations for a hard reset type of fix?

bgyori commented 3 years ago

Do you happen to be using one of the new Macs with an M1 processor? It's possible that due to the different architecture, gensim isn't compatible with that, and using Docker wouldn't help in that case.

npokorzynski commented 3 years ago

@bgyori no fancy processor here, just an Intel i7

ri23 commented 3 years ago

Check the logs for full command output. Did you find a program log file alongside the gensim install error? If so, could you share that with us?

npokorzynski commented 3 years ago

@ri23 I'm not sure if I found a program log file, though an entire program log was output with the error. I could share that if it helps.

For what its worth, I was able to get genewalk to work on another Mac with MacOS v11.2 and Python v3.8 using the same code as above.

bgyori commented 3 years ago

If you try pip install gensim, do you get the same error? If you do, it might be possible to get more help directly from gensim: https://github.com/RaRe-Technologies/gensim/issues.

npokorzynski commented 3 years ago

@bgyori yea, I do get the same error. I'll follow up with gensim and see what they have to say. I can close this out for the time being since I have genewalk working on another computer. Thanks for the help!