-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
There should be an easier way to do the equivalent of mean(abs2, x, dims=1)
with the Einops syntax. Currently, one might have to do:
reduce((x; dims) -> mean(abs2, x; dims), x, (:a, ..) --> (..))
I'd consider moving the both the function used to reduce, and the function applied to each term, to the back of the reduce
function like so:
reduce(x, (:a, ..) --> (..), mean, abs2)
Ignoring e.g. abs2
, this is also closer to the Python syntax:
reduce(x, 'a ... -> ...', 'mean')
Metadata
Metadata
Assignees
Labels
No labels