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

Problems with the installation of Dropkick #9

Open
jessijessi opened this issue Jul 4, 2022 · 7 comments
Open

Problems with the installation of Dropkick #9

jessijessi opened this issue Jul 4, 2022 · 7 comments

Comments

@jessijessi
Copy link

Hi, I tried to install the package using both pip install dropkick command and the cloning of the github but the installation was unsuccessful. This is probably due to the fact that the package needs older versions of the required packages. Below a screenshot of the middle part of the error:

immagine

I tried also to use the functions taking one to one in my script but I have a trouble with the function dropkick() because, as far as I could understood, it requires glmnet package from fortran and I couldn't load it.

How could i fix it?

Thany you,
Best regards

@codyheiser
Copy link
Collaborator

Hi,

Could you provide the following information so I can help troubleshoot?:

  • Platform you're working on (Mac, Linux, Windows)
  • Fortran compiler installed on the system (gfortran for Linux, or gcc for Mac)
  • Exact installation command you used to get the above traceback

Thanks!
Cody

@sjfleming
Copy link

I had success with the following (on a linux machine, Ubuntu 16.04)

$ conda create -n dropkick python=3.7
$ conda activate dropkick
(dropkick) $ pip install numpy
(dropkick) $ conda install -c conda-forge gfortran
(dropkick) $ pip install dropkick

If you don't install numpy manually first, then the install will fail. Not sure why that is.

@sjfleming
Copy link

sjfleming commented Oct 4, 2022

Just to leave one more note...

The above recipe worked on Linux, but did not work on Mac.

I tried many things on a Mac, including trying to have glmnet pre-installed, as in

$ conda create -n dropkick python=3.8
$ conda activate dropkick
(dropkick) $ conda install libgcc
(dropkick) $ conda install -c conda-forge gfortran
(dropkick) $ conda install -c conda-forge glmnet
(dropkick) $ pip install numpy
(dropkick) $ pip install dropkick

but nothing seemed to work. The above did not work.

@codyheiser
Copy link
Collaborator

Hi @sjfleming,

Thanks for the notes. Just to capture a couple more things to help @jessijessi and anyone else who may have installation troubles in the future:

  1. Yes, the install requires numpy to be installed first for some of the setup functions - this is important to note when installing in a fresh virtual environment that does not yet contain numpy.
  2. On Mac, I typically recommend using homebrew to install the fortran compiler available in gcc:
brew install gcc

@jessijessi
Copy link
Author

Hi,

Could you provide the following information so I can help troubleshoot?:

* Platform you're working on (Mac, Linux, Windows)

* Fortran compiler installed on the system (gfortran for Linux, or gcc for Mac)

* Exact installation command you used to get the above traceback

Thanks! Cody

Hi @codyheiser,
excuse me but I forgot to answer to your questions. I am on CentOS Linux release 7.7.1908 (Core) and the Fortran compiler is GNU Fortran (GCC) 4.8.5 20150623 (Red Hat 4.8.5-39).

Thank you,
Best regards,Jessi

@codyheiser
Copy link
Collaborator

@jessijessi, not sure if you're using Anaconda to manage virtual environments on your machine, but have you tried the suggestion from above?:

$ conda create -n dropkick python=3.7
$ conda activate dropkick
(dropkick) $ pip install numpy
(dropkick) $ conda install -c conda-forge gfortran
(dropkick) $ pip install dropkick

The two keys here are installation of numpy prior to pip install dropkick, and also installation of gfortran via Conda so your system is sure to find the proper compiler.
If you're not using Conda, I would try making sure that your GCC is located somewhere on your $PATH such that it's called properly by pip.

@sbwiecko
Copy link

sbwiecko commented Nov 30, 2022

A simple sudo apt install gfortran solved the issue in my case. GCC was already installed.

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

4 participants