sdv-dev / SDMetrics

Metrics to evaluate quality and efficacy of synthetic datasets.
https://docs.sdv.dev/sdmetrics
MIT License
210 stars 45 forks source link

Create single table BaseProperty class #354

Closed amontanez24 closed 1 year ago

amontanez24 commented 1 year ago

Problem Description

As a developer, it would be easier to make changes to the QualityReport if our code abstractions matched our logical and user facing abstractions. It's hard to add new properties, modify aggregation in existing ones and handle errors now because the results are being collected in a way that doesn't match the desired output.

SDMetrics has a concept of properties. These are a collection of similar metrics that can be used to tell us about one aspect of the synthetic data (eg. column pair trends). The problem is, our code doesn't have this concept. Instead the metrics are all collected and then converted into properties for the user facing output. This causes inefficiencies in the way the metrics are collected (the same columns/tables being looped over multiple times) and makes the code harder to read.

To solve these problems we propose adding a new module called _properties to the reports/single_table folder and creating a BaseSingleTableProperty class.

Expected behavior

Attributes

Abstract methods

Additional context