def restore
import stelliferous@0.0.2.0/tensor_cursor.bend as TensorCursorimport Base
32# Outer axes: reset axes are kept reversed and restored after the carry stops.
33def restore(reset: List<&2,Axis>,axes: List<&2,Axis>) -> List<&2,Axis>:
34 match reset:
35 case []: axes
36 case axis <> tail: restore(tail,axis <> axes)