Skip to content

Commit

Permalink
chore: run formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
avik-pal committed Sep 2, 2024
1 parent 466c13d commit 2dc38f8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ SciMLBase = "2"
SciMLSensitivity = "7.43"
StableRNGs = "1.0.2"
Statistics = "1.10"
SteadyStateDiffEq = "2"
SteadyStateDiffEq = "2.3.2"
Test = "1.10"
Zygote = "0.6.69"
julia = "1.10"
Expand Down
10 changes: 4 additions & 6 deletions test/layers_tests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@ end
x = randn(rng, Float32, x_size...) |> dev
z, st = model(x, ps, st)

opt_broken = solver isa SimpleLimitedMemoryBroyden
@jet model(x, ps, st) opt_broken=opt_broken
@jet model(x, ps, st) opt_broken=true

@test all(isfinite, z)
@test size(z) == size(x)
Expand Down Expand Up @@ -102,8 +101,8 @@ end
dense_layer(2 => 4) dense_layer(2 => 3) NoOpLayer() dense_layer(2 => 1);
dense_layer(1 => 4) dense_layer(1 => 3) dense_layer(1 => 2) NoOpLayer()]]

init_layers = [(dense_layer(4 => 4), dense_layer(4 => 3),
dense_layer(4 => 2), dense_layer(4 => 1))]
init_layers = [(
dense_layer(4 => 4), dense_layer(4 => 3), dense_layer(4 => 2), dense_layer(4 => 1))]

x_sizes = [(4, 3)]
scales = [((4,), (3,), (2,), (1,))]
Expand Down Expand Up @@ -141,8 +140,7 @@ end
z, st = model(x, ps, st)
z_ = DEQs.__flatten_vcat(z)

opt_broken = solver isa SimpleLimitedMemoryBroyden
@jet model(x, ps, st) opt_broken=opt_broken # Broken due to nfe dynamic dispatch
@jet model(x, ps, st) opt_broken=true

@test all(isfinite, z_)
@test size(z_) == (sum(prod, scale), size(x, ndims(x)))
Expand Down

0 comments on commit 2dc38f8

Please sign in to comment.