# \[Mocha\] Where does libcudnn go on linux boxes?

**URL:** <https://discourse.julialang.org/t/mocha-where-does-libcudnn-go-on-linux-boxes/4181>\
**Category:** GPU\
**Tags:** question\
**Created:** [June 9, 2017, 4:03pm UTC](https://discourse.julialang.org/t/mocha-where-does-libcudnn-go-on-linux-boxes/4181 "2017-06-09T16:03:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nectarineimp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nectarineimp/32/883_2.png) [@Nectarineimp](https://discourse.julialang.org/u/Nectarineimp)\
**Post date:** [June 9, 2017, 4:03pm UTC](https://discourse.julialang.org/t/mocha-where-does-libcudnn-go-on-linux-boxes/4181/1 "2017-06-09T16:03:19Z")

</div>

I am trying to use the Mocha package, and I’ve downloaded the Deep Neural Network cuda library from nVidia. I put a copy of it in /libs and another in ~/.julia/v0.5/Mocha/Deps. No luck running Pkg.test(“Mocha”). If I turn off the GPU backend it works fine, so I know all other parts of my setup are correct. The Mocha documentation skips the part of what to do once you download the shared library.

I know this is off topic but I couldn’t find an appropriate discourse like site for Mocha. If there is one, please redirect me there. Thanks!

---

<div class="post-metadata">

**Author:** ![maleadt](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/maleadt/32/10097_2.png) [@maleadt](https://discourse.julialang.org/u/maleadt)\
**Post date:** [June 9, 2017, 5:15pm UTC](https://discourse.julialang.org/t/mocha-where-does-libcudnn-go-on-linux-boxes/4181/2 "2017-06-09T17:15:46Z")

</div>

Mocha seems to use regular `Base.find_library`, so depending on your library add something to eg. `LD_LIBRARY_PATH` (Linux) or edit the relevant `find_library` calls (ie. the ones discovering CUDA and cuDNN in respectively `cuda.jl` and `cudnn.jl`) to include your CUDA toolkit library directory in the (currently empty) array of directories as second argument.

Their build system should probably discover your library, or provide a way to point towards it (eg. `CUDA_HOME`/`CUDA_ROOT` env var).

---

<div class="post-metadata">

**Author:** ![Nectarineimp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nectarineimp/32/883_2.png) [@Nectarineimp](https://discourse.julialang.org/u/Nectarineimp)\
**Post date:** [June 13, 2017, 3:04pm UTC](https://discourse.julialang.org/t/mocha-where-does-libcudnn-go-on-linux-boxes/4181/3 "2017-06-13T15:04:57Z")

</div>

OK that is sound advice! I will give it a try later today. The machine I am using it on here at work has two Titan cards in it, and the option pricing black scholes demo calculated 25 billion prices a second. So I am keenly interested to see if I can get similar computing power with my large data sets.
