Skip to content

Commit fd44bd4

Browse files
fix: correct type params to ODESolution adjoint
1 parent 9d87ca0 commit fd44bd4

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

ext/SciMLBaseChainRulesCoreExt.jl

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -97,30 +97,30 @@ end
9797
function ChainRulesCore.rrule(
9898
::Type{
9999
<:ODESolution{T1, T2, T3, T4, T5, T6, T7, T8, T9, T10,
100-
T11, T12
100+
T11, T12, T13, T14
101101
}}, u,
102102
args...) where {T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11,
103-
T12}
103+
T12, T13, T14}
104104
function ODESolutionAdjoint(ȳ)
105105
(NoTangent(), ȳ, ntuple(_ -> NoTangent(), length(args))...)
106106
end
107107

108-
ODESolution{T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12}(u, args...),
108+
ODESolution{T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14}(u, args...),
109109
ODESolutionAdjoint
110110
end
111111

112-
function ChainRulesCore.rrule(
113-
::Type{
114-
<:ODESolution{uType, tType, isinplace, P, NP, F, G, K,
115-
ND
116-
}}, u,
117-
args...) where {uType, tType, isinplace, P, NP, F, G, K, ND}
118-
function SDESolutionAdjoint(ȳ)
119-
(NoTangent(), ȳ, ntuple(_ -> NoTangent(), length(args))...)
120-
end
121-
122-
SDESolution{uType, tType, isinplace, P, NP, F, G, K, ND}(u, args...), SDESolutionAdjoint
123-
end
112+
# function ChainRulesCore.rrule(
113+
# ::Type{
114+
# <:SDESolution{uType, tType, isinplace, P, NP, F, G, K,
115+
# ND
116+
# }}, u,
117+
# args...) where {uType, tType, isinplace, P, NP, F, G, K, ND}
118+
# function SDESolutionAdjoint(ȳ)
119+
# (NoTangent(), ȳ, ntuple(_ -> NoTangent(), length(args))...)
120+
# end
121+
#
122+
# SDESolution{uType, tType, isinplace, P, NP, F, G, K, ND}(u, args...), SDESolutionAdjoint
123+
# end
124124

125125
function ChainRulesCore.rrule(::SciMLBase.EnsembleSolution, sim, time, converged)
126126
out = EnsembleSolution(sim, time, converged)

0 commit comments

Comments
 (0)