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.
CategoricalSVM.
compute
Compute this metric.
This fits an adversial attacker model on the synthetic data and then evaluates it making predictions on the real data.
A key_fields column(s) name must be given, either directly or as a first level entry in the metadata dict, which will be used as the key column(s) for the attack.
key_fields
metadata
A sensitive_fields column(s) name must be given, either directly or as a first level entry in the metadata dict, which will be used as the sensitive_fields column(s) for the attack.
sensitive_fields
real_data (Union[numpy.ndarray, pandas.DataFrame]) – The values from the real dataset.
synthetic_data (Union[numpy.ndarray, pandas.DataFrame]) – The values from the synthetic dataset.
metadata (dict) – Table metadata dict. If not passed, it is build based on the real_data fields and dtypes.
key_fields (list(str)) – Name of the column(s) to use as the key attributes.
sensitive_fields (list(str)) – Name of the column(s) to use as the sensitive attributes.
model_kwargs (dict) – Key word arguments of the attacker model. cls.MODEL_KWARGS will be used if none is provided.
Scores obtained by the attackers when evaluated on the real data.
union[float, tuple[float]]