diff --git a/CHANGELOG.md b/CHANGELOG.md index d48bfb526..2ae90818b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -41,6 +41,7 @@ Entries link to the pull request that introduced them. ## GraphNeuralNetworks.jl — Unreleased (towards 1.1.1) **Changed** +- `GNNRecurrence` now hands each cell an indexed time slice instead of an `eachslice` view, matching the Lux frontend. Enzyme's type analysis fails on `SubArray` cell inputs, so this unblocks `DCGRU`, `EvolveGCNO`, `GConvGRU` and `GConvLSTM` under Enzyme ([#707]). - The recurrent temporal cells now delegate their forward-pass math to shared `GNNlib` functions (requires GNNlib ≥ 1.4); the layer behaviour is unchanged ([#696]). ## GNNlib.jl 1.4.0 — 2026-07-22 @@ -235,5 +236,6 @@ Lux implementations of the graph convolutional, pooling, and temporal layers [#696]: https://github.com/JuliaGraphs/GraphNeuralNetworks.jl/pull/696 [#703]: https://github.com/JuliaGraphs/GraphNeuralNetworks.jl/pull/703 [#704]: https://github.com/JuliaGraphs/GraphNeuralNetworks.jl/pull/704 +[#707]: https://github.com/JuliaGraphs/GraphNeuralNetworks.jl/pull/707 [#706]: https://github.com/JuliaGraphs/GraphNeuralNetworks.jl/pull/706 [FluxML/Zygote.jl#1662]: https://github.com/FluxML/Zygote.jl/issues/1662 diff --git a/GraphNeuralNetworks/src/layers/temporalconv.jl b/GraphNeuralNetworks/src/layers/temporalconv.jl index 347c8ff7a..e6b895a8f 100644 --- a/GraphNeuralNetworks/src/layers/temporalconv.jl +++ b/GraphNeuralNetworks/src/layers/temporalconv.jl @@ -1,7 +1,9 @@ function scan(cell, g::GNNGraph, x::AbstractArray{T,3}, state) where {T} y = [] - for xt in eachslice(x, dims = 2) - yt, state = cell(g, xt, state) + for t in 1:size(x, 2) + # slice by indexing, not `eachslice`: Enzyme's type analysis fails on + # `SubArray` cell inputs. The Lux frontend slices the same way. + yt, state = cell(g, x[:, t, :], state) y = vcat(y, [yt]) end return stack(y, dims = 2)