TensorBandConcat.append_tree: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/tensor_band_concat.bend as TensorBandConcat Lines 102-111 of stelliferous@0.0.2.0/tensor_band_concat.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/tensor_band_concat.bend&start_line=102&end_line=111 import Base import stelliferous@0.0.2.0/tensor.bend as Tensors import stelliferous@0.0.2.0/tensor_band.bend as Bands import stelliferous@0.0.2.0/storage_buffer.bend as Storage import stelliferous@0.0.2.0/traversal_partition.bend as Partition def append_tree(~Element: Data,output: Bands.Bands(~Element),+geometry: Bands.Geometry,+channel: U32,input: Tensors.Tensor) -> Tensors.Tensor & Bands.Bands(~Element): match output: case Partition.Leaf{output,+first,+count,details}: Storage.bind_pair(~Tensors.Tensor,~Storage.Buffer,~(Tensors.Tensor & Bands.Bands(~Element)), rows(~Element,geometry,first,count,channel,input,output),input => output => (input,Partition.Leaf{output,first,count,Unit{}})) case Partition.Fork{left,right}: Storage.bind_pair(~Tensors.Tensor,~Bands.Bands(~Element),~(Tensors.Tensor & Bands.Bands(~Element)), append_tree(~Element,left,geometry,channel,input),input => left => Storage.bind_pair(~Tensors.Tensor,~Bands.Bands(~Element),~(Tensors.Tensor & Bands.Bands(~Element)), append_tree(~Element,right,geometry,channel,input),input => right => (input,Partition.Fork{left,right}))) Uses (11): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Unit 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/storage_buffer.bend&name=bind_pair https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor.bend&name=Tensor https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_band.bend&name=Bands https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_band.bend&name=Geometry https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/tensor_band_concat.bend&name=rows https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/traversal_partition.bend&name=Tree