pub fn encode_and_popcount<R: Rng + ?Sized>(
weight_words: &[u64],
prob: f64,
length: usize,
rng: &mut R,
) -> u64Expand description
Fused encode+AND+popcount without materializing encoded input words.
Semantically equivalent to:
encoded = bernoulli_packed_simd(prob, length, rng)sum(popcount(encoded[word] & weight_words[word]))