Skip to content

Commit 938623b

Browse files
committed
unthunk input to Tridiagonal_pullback
1 parent dfbd363 commit 938623b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/rulesets/LinearAlgebra/structured.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,8 +275,9 @@ end
275275

276276
function rrule(::Type{Tridiagonal}, dl, d, du)
277277
y = Tridiagonal(dl, d, du)
278-
@views function ∇Tridiagonal(∂y)
278+
@views function Tridiagonal_pullback(ȳ)
279+
∂y = unthunk(ȳ)
279280
return (NoTangent(), diag(∂y, -1), diag(∂y), diag(∂y, 1))
280281
end
281-
return y, ∇Tridiagonal
282+
return y, Tridiagonal_pullback
282283
end

0 commit comments

Comments
 (0)