chickadee » array-morphisms » batch-scan

batch-scan func init mprocedure
batch-scan/slices func init mprocedure

Scan func along the batch axis. batch-scan turns the step into one scan with morph-scan/fn, with as many nodes for any batch size. When the step cannot be turned into an expression, or init is not an array of one element's shape and dtype, it runs batch-scan/slices, which applies the step to each slice and stacks the results.