yeezhu / SPN.pytorch

PyTorch implementation of "Soft Proposal Networks for Weakly Supervised Object Localization", ICCV 2017.
http://yzhu.work/spn.html
MIT License
212 stars 37 forks source link

Error in installation #27

Closed sar-gupta closed 6 years ago

sar-gupta commented 6 years ago

I tried to install by using conda (from the environment.yml file). On running conda env create -f environment.yml, I get the error:

Solving environment: failed

UnsatisfiableError: The following specifications were found to be in conflict:
  - blas==1.1=openblas
  - numpy==1.13.1=py35_0 -> blas=[build=mkl]
Use "conda info <package>" to see the dependencies for each package.

Any help in solving this issue would be appreciated, thanks!

sar-gupta commented 6 years ago

For anyone else looking for a solution, here goes. I made a new environment, installed the dependencies as mentioned in README:

It took a lot of time to get this working because this only works with pytorch<=0.4.0 (would be great if this is also mentioned in the README).

Pytorch 0.4.1 introduced some breaking changes, hence doesn't work with this repo. Reference: https://github.com/pytorch/pytorch/issues/8483

Also, 0.4.0 version works with CUDA 8 (not 9), so for people who want to keep both versions of CUDA on their machine, this worked for me: https://blog.kovalevskyi.com/multiple-version-of-cuda-libraries-on-the-same-machine-b9502d50ae77

Another important thing: For running the CUDA runfile (.run), you'd need gcc <= 5.3.1 as mentioned in the installation instructions for CUDA toolkit. I used gcc-4.8 and it worked fine for me. (You can use update-alternatives to manage different versions of gcc).