Classes and functions for arrays of bitsets (i.e., sets of binary values).
A helper class for wrapping a byte array containing an ND-array of bitsets.
Set values of this packed bitset array from a boolean numpy array.
Create a new view of this object’s memory in which the array of bitsets has a different shape.
The length of the component bitsets is unchanged.
Create a new view of this object’s memory in which the component bitsets have a different length.
The shape of the array of bitsets is unchanged.
Create a boolean numpy array from this packed bitset array.
Get the shape of the array.
Get the total number of bits in the array of bitsets.
For example, if the shape of the array is (2, 3) and each bitset has 4 elements, then the size is 24 bits.
Create a bitset from a boolean array.
| Parameters: | bitset_dims (int) – Number of final dimensions of array that correspond to a single bitset. |
|---|
Create an ND-array of bitsets with the given shape.
Create a byte array whose size can support an array of bitsets with the given shape.
| Parameters: |
|
|---|