Function concrete_core::math::random::fill_with_random_uniform_n_lsb [−][src]
pub fn fill_with_random_uniform_n_lsb<Scalar, Tensorable>(
output: &mut Tensorable,
n: usize
) where
Scalar: RandomGenerable<UniformLsb>,
Tensorable: AsMutTensor<Element = Scalar>,
Fills an AsMutTensor
value with random values whose n lsbs are sampled uniformly.
Example
use concrete_core::math::tensor::Tensor; use concrete_core::math::random::fill_with_random_uniform_n_lsb; let mut tensor = Tensor::allocate(0 as u8, 100); fill_with_random_uniform_n_lsb(&mut tensor, 3);