Skip to content

Commit 5f2680a

Browse files
restrict AdamW's fields to Float64 (#199)
1 parent 669798c commit 5f2680a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/rules.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -528,11 +528,11 @@ Implemented as an [`OptimiserChain`](@ref) of [`Adam`](@ref) and [`WeightDecay`]
528528
The previous rule, which is closer to the original paper, can be obtained by setting `AdamW(..., couple=false)`.
529529
See [this issue](https://github.com/FluxML/Flux.jl/issues/2433) for more details.
530530
"""
531-
struct AdamW{T1,T2,T3,T4} <: AbstractRule
532-
eta::T1
533-
beta::T2
534-
lambda::T4
535-
epsilon::T3
531+
struct AdamW <: AbstractRule
532+
eta::Float64
533+
beta::Tuple{Float64, Float64}
534+
lambda::Float64
535+
epsilon::Float64
536536
couple::Bool
537537
end
538538

0 commit comments

Comments
 (0)