pub(crate) fn batch_encode<'py>(
_py: Python<'py>,
probs: PyReadonlyArray1<'py, f64>,
length: usize,
seed: u64,
) -> PyResult<Vec<Vec<u64>>>Expand description
Bernoulli-encode a numpy float64 array into packed bitstream words.
Returns nested packed words with shape (n_probs, ceil(length / 64)).