From 1d221a3565769ec1f01a0b672a9f2766b05fd6b4 Mon Sep 17 00:00:00 2001 From: Brian Chen Date: Tue, 24 Oct 2023 12:20:42 -0700 Subject: [PATCH 1/2] Test changes from https://github.com/FluxML/ZygoteRules.jl/pull/26 --- src/Zygote.jl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Zygote.jl b/src/Zygote.jl index 64564ad7f..b995a2932 100644 --- a/src/Zygote.jl +++ b/src/Zygote.jl @@ -6,6 +6,11 @@ using LinearAlgebra: copytri!, AbstractTriangular import ZygoteRules: @adjoint, @adjoint!, AContext, adjoint, _pullback, pullback, literal_getproperty, literal_getfield, unthunk_tangent +ZygoteRules.gradtuple0(::Tuple{Vararg{Nothing}}) = nothing +ZygoteRules.gradtuple1(::Tuple{Vararg{Nothing}}) = nothing +ZygoteRules.gradtuple2(::Tuple{Vararg{Nothing}}) = nothing +ZygoteRules.gradtuple3(::Tuple{Vararg{Nothing}}) = nothing + using ChainRulesCore using ChainRules: ChainRules, rrule, unthunk, canonicalize using IRTools From 9d7a93511642e092c3c3cf2be2455c07be789e0b Mon Sep 17 00:00:00 2001 From: Brian Chen Date: Tue, 24 Oct 2023 12:32:08 -0700 Subject: [PATCH 2/2] Update Zygote.jl --- src/Zygote.jl | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Zygote.jl b/src/Zygote.jl index b995a2932..decc49234 100644 --- a/src/Zygote.jl +++ b/src/Zygote.jl @@ -6,6 +6,7 @@ using LinearAlgebra: copytri!, AbstractTriangular import ZygoteRules: @adjoint, @adjoint!, AContext, adjoint, _pullback, pullback, literal_getproperty, literal_getfield, unthunk_tangent +using ZygoteRules: ZygoteRules ZygoteRules.gradtuple0(::Tuple{Vararg{Nothing}}) = nothing ZygoteRules.gradtuple1(::Tuple{Vararg{Nothing}}) = nothing ZygoteRules.gradtuple2(::Tuple{Vararg{Nothing}}) = nothing