Skip to main content

parse_weight_blob

Function parse_weight_blob 

Source
pub fn parse_weight_blob(bytes: &[u8]) -> Result<WeightBlob, AudioError>
Expand description

Parse a weight blob from bytes. Bounded and strict: unknown magic → BackendUnavailable (treated as “no usable weights” so the head fails closed); any structural problem (short read, oversized counts, trailing bytes) → MalformedAudio. Never partially accepts.