Danger You are looking at the documentation for an older version of the SDV! We are no longer supporting or maintaining this version of the software Click here to go to the new docs pages.
Danger
You are looking at the documentation for an older version of the SDV! We are no longer supporting or maintaining this version of the software
Click here to go to the new docs pages.
sdv.metrics.tabular.
NumericalPrivacyMetric
Base class for Numerical Privacy metrics on single tables.
These metrics fit an adversial attacker model on the synthetic data and then evaluate its accuracy (or probability of making the correct attack) on the real data.
name
Name to use when reports about this metric are printed.
str
goal
The goal of this metric.
sdmetrics.goal.Goal
min_value
Minimum value or values that this metric can take.
Union[float, tuple[float]]
max_value
Maximum value or values that this metric can take.
model
Model class to use for the prediction.
Class
model_kwargs
Keyword arguments to use to create the model instance.
dict
loss_function
Loss function to use when evaluating the accuracy of the privacy attack.
loss_function_kwargs
Keyword arguments to use to create the loss function instance.
__init__
Initialize self. See help(type(self)) for accurate signature.
Methods
__init__()
Initialize self.
compute(real_data, synthetic_data[, …])
compute
Compute this metric.
compute_breakdown(real_data, synthetic_data)
compute_breakdown
Compute this metric breakdown.
get_subclasses([include_parents])
get_subclasses
Recursively find subclasses of this metric.
normalize(raw_score)
normalize
Compute the normalized value of the metric.
Attributes
LOSS_FUNCTION_KWARGS
MODEL
MODEL_KWARGS