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
Is there any chance you can support transducers in groupreduce? Roughly speaking it's "just" rewriting
acc = init
for x in xs
acc =op(acc, x)
end
to
acc =start(op, init)
for x in xs
acc =next(op, acc, x)
acc isa Reduced &&return acc # required only for terminatable transducersend
acc =complete(op, acc)
This way, I can pass op = reducingfunction(transducer, original_op) to groupreduce. It is useful for complex per-group operations fused with the reduction. I can split the abstract interface in a separate package if requiring whole Transducers.jl is not ideal.
The text was updated successfully, but these errors were encountered:
Is there any chance you can support transducers in
groupreduce
? Roughly speaking it's "just" rewritingto
This way, I can pass
op = reducingfunction(transducer, original_op)
togroupreduce
. It is useful for complex per-group operations fused with the reduction. I can split the abstract interface in a separate package if requiring whole Transducers.jl is not ideal.The text was updated successfully, but these errors were encountered: