Skip to content

Compilation fails because CMake silently picks up cudnn from conda #4869

@DavidNemeskey

Description

@DavidNemeskey

I was trying to compile master from source, but the test cases did not compile. It turns out I ran into the same problem as VladislavZavadskyy did in #3567: CMake picked up the cuDNN package installed by conda instead of the one manually installed system-wide. That issue was closed as removing the conda version was deemed a "solution". However, I think this is a problem that should be reported as its own issue (and solved). As I see it, the main problems are:

  1. As seen in the logs below, CMake explicitly reports that it found the system-wide cuDNN version:
    -- Found cuDNN: v6.0.21  (include: /usr/local/cuda/include, library: /usr/local/cuda/lib64/libcudnn.so)
    
    ; but then it goes on to use the library installed by conda without any notice (and the header in the system-wide version, hence the error). Note that for MKL, the logs clearly show that it was taken from the conda environent; not for cuDNN.
  2. The conda cudnn package is a dependency of tensorflow-gpu 1.4.1, so uninstalling it also removes tensorflow. Of course, I can re-install it via pip, but conda version has different package structures so this issue messes up the environment (as can be seen in the conda/pip lists).
  • OS: Linux charlie 3.16.0-4-amd64 Matrix multiplication operator #1 SMP Debian 3.16.43-2+deb8u5 (2017-09-19) x86_64 GNU/Linux
  • PyTorch version: master
  • How you installed PyTorch (conda, pip, source): source
  • Python version: 3.6
  • CUDA/cuDNN version: now that's the problem (CUDA 8 / cuDNN 6 vs 7 in conda)
  • GPU models and configuration: GeForce GTX 980
  • GCC version (if compiling from source): 4.9.2

cmake_log.txt
conda_list.txt
pip_list.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions