Skip to main content

Module tensor

Module tensor 

Source
Expand description

Tensor-compute axes per Wiki ADR-031 (re-export of uor-prism-tensor).

Provides TensorAxis and ActivationAxis with fixed-shape CPU integer-precision reference impls. Variable-rank tensor compute composes through verbs over partition_product!-declared shapes (ADR-033/044).

Modules§

activation
ActivationAxis declaration + parametric element-wise i8 nonlinearity reference impls.
dtype
GGML / GGUF / ONNX tensor element-type alphabet per Wiki ADR-031.
shape
Higher-rank tensor ConstrainedTypeShape carriers (Tensor3Shape, Tensor4Shape).
tensor
TensorAxis declaration + parametric square-matmul impl + shape.
verbs
Layer-3 substrate-Term verbs per Wiki ADR-024 + Wiki ADR-055 + Wiki ADR-056 (ψ-residuals discipline scope refined to route bodies only — verb bodies admit comparison + concat + hash composition).

Macros§

axis_extension_impl_for_activation_axis
Wiki ADR-030 companion macro: instantiate AxisExtension for a concrete struct implementing this axis trait. The macro emits an impl AxisExtension for <StructIdent> block that delegates dispatch_kernel to the axis-trait methods per KERNEL_* id. The orphan-rule-conformant per-struct impl mechanism replacing the blanket impl<T: <axis>> AxisExtension for T (which would violate Rust’s orphan rule from any crate that does not define AxisExtension).
axis_extension_impl_for_tensor_axis
Wiki ADR-030 companion macro: instantiate AxisExtension for a concrete struct implementing this axis trait. The macro emits an impl AxisExtension for <StructIdent> block that delegates dispatch_kernel to the axis-trait methods per KERNEL_* id. The orphan-rule-conformant per-struct impl mechanism replacing the blanket impl<T: <axis>> AxisExtension for T (which would violate Rust’s orphan rule from any crate that does not define AxisExtension).

Structs§

CpuI8MatmulSquare
Parametric square DIM × DIM i8 × i8i16 matmul.
CpuI8VectorActivation
Parametric element-wise activation kernels over an N-element i8 vector.
MatrixShape
Parametric ConstrainedTypeShape for a row-major ROWS × COLS matrix of ELEM_BYTES-byte elements. Per ADR-031’s Tensor<Element, Shape> shape commitment, restricted to matrix rank-2 here; higher ranks compose through partition_product! per ADR-033/044.
Tensor3Shape
Parametric ConstrainedTypeShape for a row-major rank-3 tensor of shape D0 × D1 × D2 carrying ELEM_BYTES-byte elements.
Tensor4Shape
Parametric ConstrainedTypeShape for a row-major rank-4 tensor of shape D0 × D1 × D2 × D3 carrying ELEM_BYTES-byte elements.
VectorShape
Parametric ConstrainedTypeShape for a length-N vector of ELEM_BYTES-byte elements. Per ADR-031’s Tensor<Element, Shape> for rank-1.

Constants§

STANDARD_LIBRARY_VERSION
Wiki ADR-031 standard-library version banner.

Traits§

ActivationAxis
Wiki ADR-031 element-wise nonlinearity axis.
TensorAxis
Wiki ADR-031 tensor-compute axis.