Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
Vaibhavdixit02 committed Jan 16, 2025
1 parent 29bbddc commit ccf890f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/OptimizationOptimisers/src/OptimizationOptimisers.jl
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ function SciMLBase.__solve(cache::OptimizationCache{
min_err = x
min_θ = copy(θ)
end
if iterations == length(data)*epochs #Last iter, revert to best.
if iterations == length(data) * epochs #Last iter, revert to best.
opt = min_opt
x = min_err
θ = min_θ
Expand Down
6 changes: 3 additions & 3 deletions lib/OptimizationOptimisers/test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,9 @@ end

res = Optimization.solve(prob, Optimisers.Adam(), epochs = 50)

@test res.stats.iterations == 50*length(data)
@test res.stats.fevals == 50*length(data)
@test res.stats.gevals == 50*length(data)
@test res.stats.iterations == 50 * length(data)
@test res.stats.fevals == 50 * length(data)
@test res.stats.gevals == 50 * length(data)

res = Optimization.solve(prob, Optimisers.Adam(), callback = callback, epochs = 100)

Expand Down

0 comments on commit ccf890f

Please sign in to comment.