bend-ml-binary-read
Search uses release 0.2.0.0 · 6 definitions
Definitions (6)
- def read_f32Reads n numbers (4 * n bytes) at byte `offset` of `file` into cells 0 ..
- def size64The size of `file` in bytes as (hi, lo): hi * 2^32 + lo.
- def read_f32_atAs read_f32, at the byte offset hi * 2^32 + lo, and it answers the number of whole numbers read (not bytes), so a read of up to 2^32 - 1 numbers (16 GiB) answers its count in a U32.
- def read_bf16_atn little-endian BF16 numbers (2 * n bytes) at the byte offset hi * 2^32 + lo, each widened exactly into a cell of `a`: the F32 whose top 16 bits are the BF16's and whose low 16 bits are zero (what bf16.to(torch.float32) gives).
- def read_f32_intoAs read_f32_at, writing cells at ..
- def read_bf16_intoAs read_bf16_at, writing cells at ..