Skip to main content

write_archive

Function write_archive 

Source
pub fn write_archive(
    path: impl AsRef<Path>,
    magic: ArchiveMagic,
    policy: Option<String>,
    initialization: Option<InitializationMeta>,
    tensors: &[(&str, &[usize], &[f32], BitWidth)],
) -> Result<(), PriorError>
Expand description

Writes quantized tensors into a QPI1/QPR1/LRA1/QLA1 binary archive.

Used primarily for testing and creating quantized prior checkpoints.

ยงErrors

Returns PriorError on invalid shapes/counts or I/O failures.