Prevent breakage due to new `active` field in BatchNorm
This commit is contained in:
parent
19a034b215
commit
0def352383
|
@ -157,6 +157,8 @@ mutable struct BatchNorm{F,V,W,N}
|
||||||
active::Union{Bool, Nothing}
|
active::Union{Bool, Nothing}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
BatchNorm(λ, β, γ, μ, σ², ϵ, momentum) = BatchNorm(λ, β, γ, μ, σ², ϵ, momentum, nothing)
|
||||||
|
|
||||||
BatchNorm(chs::Integer, λ = identity;
|
BatchNorm(chs::Integer, λ = identity;
|
||||||
initβ = (i) -> zeros(Float32, i), initγ = (i) -> ones(Float32, i), ϵ = 1f-5, momentum = 0.1f0) =
|
initβ = (i) -> zeros(Float32, i), initγ = (i) -> ones(Float32, i), ϵ = 1f-5, momentum = 0.1f0) =
|
||||||
BatchNorm(λ, initβ(chs), initγ(chs),
|
BatchNorm(λ, initβ(chs), initγ(chs),
|
||||||
|
|
Loading…
Reference in New Issue