Skip to content

Commit

Permalink
Revert changes
Browse files Browse the repository at this point in the history
  • Loading branch information
jgreener64 committed Apr 21, 2024
1 parent 256e0e9 commit d4ea073
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
4 changes: 0 additions & 4 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@ EnzymeCore = "0.7"
Enzyme_jll = "0.0.104"
GPUCompiler = "0.21, 0.22, 0.23, 0.24, 0.25, 0.26"
LLVM = "6.1"
Libdl = "1.6"
LinearAlgebra = "1.6"
ObjectFile = "0.4"
Preferences = "1.4"
Printf = "1.6"
Random = "1.6"
julia = "1.6"
9 changes: 6 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3038,9 +3038,12 @@ end
@test autodiff(Reverse, f8, Active, Active(1.5))[1][1] == 0
@test autodiff(Forward, f8, Duplicated(1.5, 1.0))[1] == 0

f9(x) = sum(quantile([1.0, x], [0.5, 0.7]))
@test autodiff(Reverse, f9, Active, Active(2.0))[1][1] == 1.2
@test autodiff(Forward, f9, Duplicated(2.0, 1.0))[1] == 1.2
# On Julia 1.6 the gradients are wrong (0.7 not 1.2) and on 1.7 it errors
@static if VERSION v"1.8-"
f9(x) = sum(quantile([1.0, x], [0.5, 0.7]))
@test autodiff(Reverse, f9, Active, Active(2.0))[1][1] == 1.2
@test autodiff(Forward, f9, Duplicated(2.0, 1.0))[1] == 1.2
end
end

@static if VERSION >= v"1.7-"
Expand Down

0 comments on commit d4ea073

Please sign in to comment.