polars_arrow::bitmap

Module utils

Source
Expand description

General utilities for bitmaps representing items where LSB is the first item.

Structs§

BitChunks
This struct is used to efficiently iterate over bit masks by loading bytes on the stack with alignments of uX. This allows efficient iteration over bitmaps.
BitChunksExact
An iterator over a slice of bytes in BitChunks.
BitChunksExactMut
An iterator over mutable slices of bytes of exact size.
BitmapIter
An iterator over bits according to the LSB, i.e. the bytes [4u8, 128u8] correspond to [false, false, true, false, ..., true].
SlicesIterator
Iterator over a bitmap that returns slices of set regions.
ZipValidityIter
An Iterator over validity and values.

Enums§

ZipValidity
An Iterator over Option<T> This enum can be used in two distinct ways:

Traits§

BitChunk
A chunk of bits. This is used to create masks of a given length whose width is 1 bit. In portable_simd notation, this corresponds to m1xY.
BitChunkIterExact
Trait representing an exact iterator over bytes in BitChunk.

Functions§

bytes_for
Returns the number of bytes required to hold bits bits.
count_zeros
Returns the number of zero bits in the slice offsetted by offset and a length of length.
fmt
Formats bytes taking into account an offset and length of the form
get_bit_unchecked
Returns whether bit at position i in bytes is set or not.
is_set
Returns whether bit at position i in byte is set or not
leading_ones
Returns the number of one bits before seeing a zero bit in the slice offsetted by offset and a length of length.
leading_zeros
Returns the number of zero bits before seeing a one bit in the slice offsetted by offset and a length of length.
set_bit_in_byte
Sets bit at position i in byte.
set_bit_unchecked
Sets bit at position i in bytes without doing bound checks.
trailing_ones
Returns the number of one bits before seeing a zero bit in the slice offsetted by offset and a length of length.
trailing_zeros
Returns the number of zero bits before seeing a one bit in the slice offsetted by offset and a length of length.