Tensor.reduced: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/tensor.bend as Tensor Lines 473-478 of stelliferous@0.0.2.0/tensor.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/tensor.bend&start_line=473&end_line=478 import Base import stelliferous@0.0.2.0/storage_buffer.bend as Storage import stelliferous@0.0.2.0/tensor_operations.bend as Operations # Reductions visit elements in row-major order. def reduced(~Element: Data,~Accumulator: Data,name: String,+shape: List<&2,U32>,result: Operations.Outcome<(Storage.Buffer & Accumulator)>) -> Result<&2,&2,Problem,Accumulator>: match result: case Operations.Accepted{(storage,value)}: Done{value} case Operations.Rejected{(storage,value)}: Fail{Problem{name,InvalidShape{shape}}} Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/storage_buffer.bend&name=Buffer https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor.bend&name=Problem https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor.bend&name=Reason https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_operations.bend&name=Outcome