FluxML / fluxml.github.io

Flux Website
https://fluxml.ai
MIT License
20 stars 45 forks source link

DC-GAN tutorial based on TensorFlow #108

Closed Dsantra92 closed 2 years ago

Dsantra92 commented 2 years ago

Related to #107

Dsantra92 commented 2 years ago

Oops! Spelling mistakes! :grimacing:

logankilpatrick commented 2 years ago

@Dsantra92 great work so far, if we can address the suggestions above, this should be good to go!

Dsantra92 commented 2 years ago

@logankilpatrick I am done with the writing part, just refactoring the code a bit. I should be able to wrap it up by today.

Dsantra92 commented 2 years ago

Anything more I should add?

ToucheSir commented 2 years ago

I don't think so, but let me have another look tomorrow.

logankilpatrick commented 2 years ago

Right now I get:

ERROR: UndefVarError: gen_ps not defined
Stacktrace:
 [1] train_generator!(gen::Chain{Tuple{Dense{typeof(identity), Matrix{Float32}, Flux.Zeros}, BatchNorm{typeof(relu), Vector{Float32}, Float32, Vector{Float32}}, var"#6#7", ConvTranspose{2, 4, typeof(identity), Array{Float32, 4}, Flux.Zeros}, BatchNorm{typeof(relu), Vector{Float32}, Float32, Vector{Float32}}, ConvTranspose{2, 4, typeof(identity), Array{Float32, 4}, Flux.Zeros}, BatchNorm{typeof(relu), Vector{Float32}, Float32, Vector{Float32}}, ConvTranspose{2, 4, typeof(tanh), Array{Float32, 4}, Flux.Zeros}}}, disc::Chain{Tuple{Conv{2, 4, typeof(identity), Array{Float32, 4}, Vector{Float32}}, var"#8#10", Dropout{Float64, Colon}, Conv{2, 4, typeof(identity), Array{Float32, 4}, Vector{Float32}}, var"#9#11", Dropout{Float64, Colon}, typeof(flatten), Dense{typeof(identity), Matrix{Float32}, Vector{Float32}}}}, fake_img::Array{Float32, 4}, opt::ADAM, ps::Zygote.Params, hparams::HyperParams)
   @ Main ./REPL[35]:3
 [2] train(hparams::HyperParams)
   @ Main ./REPL[39]:47
 [3] top-level scope
   @ REPL[41]:1
 [4] top-level scope
   @ ~/.julia/packages/CUDA/YpW0k/src/initialization.jl:52
ToucheSir commented 2 years ago

Side note: has anyone looked into writing tutorials as literate.jl or jmd files so that they can be easily verified and run?

logankilpatrick commented 2 years ago

Great work on this @Dsantra92 and thanks for the review @ToucheSir!

Dsantra92 commented 2 years ago

Thanks @logankilpatrick 🙌. This was a great learning experience all thanks to you and @ToucheSir .