You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# function ChainRules.rrule(AT::Type{<:Array{T,N}}, x::AbstractArray{S,N}) where {T,S,N}
206
+
# # We're leaving these in the eltype that the cotangent vector already has.
207
+
# # There isn't really a good reason to believe we should convert to the
208
+
# # original array type, so don't unless explicitly requested.
209
+
# AT(x), Δ->(NoTangent(), Δ)
210
+
# end
209
211
210
212
# WARNING: Method definition rrule(Type{var"#s260"} where var"#s260"<:(Array{T, N} where N where T), UndefInitializer, Any...) in module ChainRules at /Users/me/.julia/packages/ChainRules/kkDLd/src/rulesets/Base/array.jl:5 overwritten in module Diffractor at /Users/me/.julia/dev/Diffractor/src/extra_rules.jl:209.
211
213
# function ChainRules.rrule(AT::Type{<:Array}, undef::UndefInitializer, args...)
@@ -254,10 +256,9 @@ function ChainRules.frule(_, ::Type{Vector{T}}, undef::UndefInitializer, dims::I
@test_brokengradient(x ->sum(gradient(x ->sum(x'.* x), x)[1]), [1,2,3]) == ([6,6,6],) # Control flow support not fully implemented yet for higher-order reverse mode
@test_brokengradient(x ->sum(x .* [1,2,3]'), (true, false)) == (NoTangent(),) # Cannot `convert` an object of type NoTangent to an object of type ZeroTangent
250
+
251
+
tup_adj =gradient((x,y) ->sum(2.* x .+log.(y)), (1,2), [3,4,5]')
@test_brokengradient(x ->sum(gradient(x ->sum(x'.* x), x)[1]), [1,2,3]) == ([6,6,6],) # Control flow support not fully implemented yet for higher-order reverse mode
0 commit comments