Flux.jl
Flux.jl copied to clipboard
doc reference for `gpu_backend!`
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 79.90%. Comparing base (
d3a083c
) to head (7f6e9d3
). Report is 163 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #2292 +/- ##
==========================================
+ Coverage 79.02% 79.90% +0.88%
==========================================
Files 31 31
Lines 1721 1911 +190
==========================================
+ Hits 1360 1527 +167
- Misses 361 384 +23
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
How easy would it be to make this friendlier?
julia> using Flux, Metal
julia> x = rand(Float32, 3) |> Flux.gpu
┌ Info: The CUDA functionality is being called but
│ `CUDA.jl` must be loaded to access it.
└ Add `using CUDA` or `import CUDA` to your code.
The minimal step would be to change this message, so that it mentions that you could be trying to use Metal / AMDGPU but have the wrong global setting.
If the Metal extension is loaded, it could be even more specific. Perhaps ideally, it would prompt you the way using Flux
does, "do you want to change Flux's global setting to Metal, y/n?".
Related to #2293 as well