Tensor.permuted: def of bendtorch@1.3.0.0 Import: import bendtorch@1.3.0.0/tensor.bend as Tensor Lines 467-473 of bendtorch@1.3.0.0/tensor.bend: https://jend.leeeet.dev/read.txt?path=bendtorch@1.3.0.0/tensor.bend&start_line=467&end_line=473 import Base # the shape with axes reordered by p: axis d of the result is axis p[d] of s def permuted(+s: List<&2, Nat>, p: List<&2, Nat>) -> List<&2, Nat>: match p: case Nil{}: Nil{} case Con{k, r}: at1(s, k) <> permuted(s, r) Uses (3): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=bendtorch@1.3.0.0/tensor.bend&name=at1