Skip to main content

chunk_range

Function chunk_range 

Source
pub fn chunk_range(
    chunk_idx: usize,
    offset: usize,
    array_len: usize,
) -> Range<usize>
Expand description

Computes the index range for a chunk, accounting for slice offset.

ยงArguments

  • chunk_idx - Index of the chunk
  • offset - Offset from slice
  • array_len - Length of the sliced array