sdv.evaluation.evaluate

sdv.evaluation.evaluate(synthetic_data, real_data=None, metadata=None, root_path=None, table_name=None, metrics=None, aggregate=True)[source]

Apply multiple metrics at once.

Parameters
  • synthetic_data (dict[str, pandas.DataFrame] or pandas.DataFrame) – Map of names and tables of synthesized data. When evaluating a single table, a single pandas.DataFrame can be passed alone.

  • real_data (dict[str, pandas.DataFrame] or pandas.DataFrame) – Map of names and tables of real data. When evaluating a single table, a single pandas.DataFrame can be passed alone.

  • metadata (str, dict, Metadata or None) – Metadata instance or details needed to build it.

  • root_path (str) – Relative path to find the metadata.json file when needed.

  • metrics (list[str]) – List of metric names to apply.

  • table_name (str) – Table name to be evaluated, only used when synthetic_data is a pandas.DataFrame and real_data is None.

  • aggregate (bool) – If get_report is False, whether to compute the mean of all the normalized scores to return a single float value or return a dict containing the score that each metric obtained. Defaults to True.

Returns

float or sdmetrics.MetricsReport