nvflare.app_common.filters.svt_privacy module
- class SVTPrivacy(fraction=0.1, epsilon=0.1, noise_var=0.1, gamma=1e-05, tau=1e-06, data_kinds: [<class 'str'>] = None, replace=True, epsilon_threshold: float = None, epsilon_query: float = None, epsilon_release: float = None)[source]
Bases:
DXOFilterImplementation of the standard Sparse Vector Technique (SVT) differential privacy algorithm.
lambda_rho = gamma / epsilon_threshold threshold = tau + np.random.laplace(scale=lambda_rho)
- Parameters:
fraction (float, optional) – used to determine dataset threshold. Defaults to 0.1.
epsilon (float, optional) – total privacy budget used for the threshold/query selection phase. Defaults to 0.1.
noise_var (float, optional) – legacy release-noise control retained for backward compatibility. When epsilon_release is not specified, this implies a total release budget of
n_upload * noise_varand preserves the previous release noise scale. Defaults to 0.1.gamma (float, optional) – Defaults to 1e-5.
tau (float, optional) – Defaults to 1e-6.
data_kinds (str, optional) – Defaults to None.
replace (bool) – whether to sample with replacement. Defaults to True.
epsilon_threshold (float, optional) – privacy budget used for threshold noise. When omitted, the standard SVT non-monotonic split is used.
epsilon_query (float, optional) – privacy budget used for query noise. When omitted, the remainder of epsilon is assigned after applying the selected split.
epsilon_release (float, optional) – total privacy budget used for the release-noise phase. When omitted, the budget is derived from noise_var to preserve existing behavior.