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 Functors.functor(::Type{<:GNNLayer}, m::T) where T
childr = (; (f =>getfield(m, f) for f infieldnames(T))...)
Tstripped = Base.typename(T).wrapper # remove all parameters. From https://discourse.julialang.org/t/stripping-parameter-from-parametric-types/8293/16
re = x ->Tstripped(x...)
return childr, re
end
so that we don't need to add @functor to types inheriting from GNNLayer.
I'm not sure if this change should be considered breaking.
The text was updated successfully, but these errors were encountered:
Now that we use Flux.@layer instead (#452) marking every subtype of GNNLayer a @layer by default would be more complicated. We would also lose the customization opportunities (e.g. for show) given by the @layer macro. Since the gain would be very little I think we shouldn't do this.
Consider adding the definitions
so that we don't need to add
@functor
to types inheriting fromGNNLayer
.I'm not sure if this change should be considered breaking.
The text was updated successfully, but these errors were encountered: