Function opendp::measurements::make_base_discrete_laplace_cks20_rug
source · pub fn make_base_discrete_laplace_cks20_rug<D>(
scale: Rational
) -> Fallible<Measurement<D, D::Carrier, D::InputMetric, MaxDivergence<Rational>>>where
D: DiscreteLaplaceDomain<Atom = Integer>,
(D, D::InputMetric): MetricSpace,
Expand description
Make a Measurement that adds noise from the discrete_laplace(scale
) distribution to the input,
directly using bignum types from rug
.
Set D
to change the input data type and input metric:
D | input type | D::InputMetric |
---|---|---|
AtomDomain<Integer> (default) | Integer | AbsoluteDistance<Integer> |
VectorDomain<AtomDomain<Integer>> | Vec<Integer> | L1Distance<Integer> |
Citations
Arguments
scale
- Noise scale parameter for the laplace distribution.scale
== sqrt(2) * standard_deviation.
Generics
D
- Domain of the data type to be privatized. Valid values areVectorDomain<AtomDomain<Integer>>
orAtomDomain<Integer>