Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Transfer learning tutorial which uses ResNet returns NaN values #242

Open
natema opened this issue Jul 21, 2020 · 0 comments
Open

Transfer learning tutorial which uses ResNet returns NaN values #242

natema opened this issue Jul 21, 2020 · 0 comments

Comments

@natema
Copy link
Contributor

natema commented Jul 21, 2020

I'm trying to run the transfer learning with Flux tutorial, but I get

┌ Warning: `haskey(::TargetIterator, name::String)` is deprecated, use `Target(; name = name) !== nothing` instead.
│   caller = llvm_compat(::VersionNumber) at compatibility.jl:176
└ @ CUDAnative ~/.julia/packages/CUDAnative/ierw8/src/compatibility.jl:176
ERROR: LoadError: LoadError: SystemError: unable to read directory /home/foo/transflearn/dataloader.jl/train: Not a directory

After explicitly writing the path to the dataset on the r.h.s. of the line

const PATH = joinpath(@__FILE__, "train")

in dataloader.jl, the dataset appears properly loaded, but then I get

┌ Warning: `haskey(::TargetIterator, name::String)` is deprecated, use `Target(; name = name) !== nothing` instead.
│   caller = llvm_compat(::VersionNumber) at compatibility.jl:176
└ @ CUDAnative ~/.julia/packages/CUDAnative/ierw8/src/compatibility.jl:176
[ Info: Epoch 1
┌ Warning: `Target(triple::String)` is deprecated, use `Target(; triple = triple)` instead.
│   caller = ip:0x0
└ @ Core :-1
[ Info: Epoch 2
2×10 CuArrays.CuArray{Float32,2,Nothing}:
NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN
NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN  NaN

If I write @show model(imgs) before the training, it correctly shows an array of Floats:

model(imgs) = Float32[0.3590678 0.35996166 0.3930334 0.4063199 0.42696851 0.41264024 0.37735277 0.3759735 0.37500587 0.4045543; 0.6409
322 0.6400384 0.6069666 0.5936801 0.5730315 0.5873597 0.62264717 0.62402654 0.6249941 0.5954457]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant