Flux.jl/src
bors[bot] af0dcb2c63
Merge #882
882: Check if CUDA availability changed during init. r=MikeInnes a=maleadt

With this PR, Flux checks using CUDAapi if CUDA is available during initialization, and forces recompilation if that does not agree with what was decided during precompilation. This avoids the scenario where Flux was precompiled without GPU support, consequently not allowing use of the GPU even if the user fixed his CUDA/GPU set-up because that does not force recompilation (and we can't add precompilation dependencies on stuff that doesn't exist).

However, we can't do the same for the case where we have a GPU/CUDA but CuArrays fails to import (checking if it imports during `__init__` would be much too expensive, if even possible), so this PR removes support for having CUDA/a GPU but CuArrays being broken. That's a little risky now that Flux depends on CuArrays, but the package is pretty mature and I haven't seen many bug reports failing to load it recently.

Fixes https://github.com/FluxML/Flux.jl/pull/852#issuecomment-538028314

cc @MikeInnes @xukai92

Co-authored-by: Tim Besard <tim.besard@gmail.com>
2019-10-08 13:24:49 +00:00
..
cuda move pullbacks to CuArrays 2019-09-26 17:14:18 +01:00
data doctests passing 2019-09-10 15:02:43 +01:00
layers line 2019-09-25 15:20:13 +02:00
optimise Merge branch 'master' into zygote 2019-09-06 15:18:58 +01:00
deprecations.jl deprecate param/data 2019-08-19 14:35:48 +01:00
Flux.jl Demote to const variables. 2019-10-03 21:28:55 +02:00
functor.jl Merge #882 2019-10-08 13:24:49 +00:00
onehot.jl Demote to const variables. 2019-10-03 21:28:55 +02:00
utils.jl add hessian 2019-01-29 08:37:30 +00:00