Skip to main content

SyntheRela - Synthetic Relational Data Generation Benchmark

Our paper Benchmarking the Fidelity and Utility of Synthetic Relational Data is available on arxiv.

Installation

To install only the benchmark package, run the following command:

pip install syntherela

Replicating the paper's results

We divide the reproducibility of the experiments into two parts: the generation of synthetic data and the evaluation of the generated data. The following sections describe how to reproduce the experiments for each part.

To reproduce some of the figures the synthetic data needs to be downloaded first. The tables can be reproduced with the results provided in the repository or by re-running the benchmark.

First, create a .env file in the root of the project with the path to the root of the project. Copy .env.example, rename it to .env and update the path.

Download synthetic data and results

The data and results can be downloaded and extracted with the below script, or are available on google drive here.

conda activate reproduce_benchmark
./experiments/reproducibility/download_data_and_results.sh

Evaluation of synthetic data

To run the benchmark and get the results of the metrics, run:

conda activate reproduce_benchmark
./experiments/reproducibility/evaluate_relational.sh

./experiments/reproducibility/evaluate_tabular.sh

./experiments/reproducibility/evaluate_utility.sh

Generation of synthetic data

Depending on the synthetic data generation method a separate pythone environment is needed. The instruction for installing the required environment for each method is provided in docs/INSTALLATION.md.

After installing the required environment, the synthetic data can be generated by running the following commands:

conda activate reproduce_benchmark
./experiments/reproducibility/generation/generate_sdv.sh

conda activate rctgan
./experiments/reproducibility/generation/generate_rctgan.sh

conda activate realtabformer
./experiments/reproducibility/generation/generate_realtabformer.sh

conda activate tabular
./experiments/reproducibility/generation/generate_tabular.sh

conda activate gretel
python experiments/generation/gretel/generate_gretel.py --connection-uid  <connection-uid> --model lstm
python experiments/generation/gretel/generate_gretel.py --connection-uid  <connection-uid> --model actgan

cd experiments/generation/clavaddpm
./generate_clavaddpm.sh <dataset-name> <real-data-path> <synthetic-data-path>  

To generate data with MOSTLYAI, insructions are provided in experiments/generation/mostlyai/README.md. 
Further instructions for GRETELAI are provided in experiments/generation/gretel/README.md.

Visualising Results

To visualize results, after running the benchmark you can run the below script. The figures will be saved to results/figures/:

conda activate reproduce_benchmark
./experiments/reproducibility/generate_figures.sh

Reproducing Tables

To reproduce the tables you can run the below script. The tables will be saved as .tex files in results/tables/:

conda activate reproduce_benchmark
./experiments/reproducibility/generate_tables.sh

Adding a new metric

The documentation for adding a new metric can be found in docs/ADDING_A_METRIC.md.

Synthetic Data Methods

Open Source Methods

* Denotes the method does not have a public implementation available.

Commercial Providers

A list of commercial synthetic relational data providers is available in docs/SYNTHETIC_DATA_TOOLS.md.

Conflicts of Interest

The authors declare no conflict of interest and are not associated with any of the evaluated commercial synthetic data providers.

Citation

If you use SyntheRela in your work, please cite our paper:

@misc{hudovernik2024benchmarkingsyntheticrelationaldata,
      title={Benchmarking the Fidelity and Utility of Synthetic Relational Data}, 
      author={Valter Hudovernik and Martin Jurkovič and Erik Štrumbelj},
      year={2024},
      eprint={2410.03411},
      archivePrefix={arXiv},
      primaryClass={cs.DB},
      url={https://arxiv.org/abs/2410.03411}, 
}

Metadata

Release files for syntherela 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for syntherela 0.0.3
File Size Uploaded
syntherela-0.0.3.tar.gz 272.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for syntherela 0.0.3
File Interpreter ABI Platform
syntherela-0.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 642.8 kB

Release files / syntherela-0.0.3.tar.gz

Download URL syntherela-0.0.3.tar.gz
Size 272.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ac084c63641676c3aa13a5508498dbd2ded0dd117613979d16d71f4e59d7979d
BLAKE2b-256 checksum
How to use checksums
27e00328b2c0e74e0ddd400e2c9ad8353234a1860d2539ae0cc461917bf4e07d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.10.13

Release files / syntherela-0.0.3-py3-none-any.whl

Download URL syntherela-0.0.3-py3-none-any.whl
Size 370.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
881b26c234a81184ea3af6a99716dd9b9c6258f1006fa7e7faa2357128d5b920
BLAKE2b-256 checksum
How to use checksums
70178f42d95129507f0dfabb4fed25a83ec421129079a564b3a6aba1e8a6a738
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.10.13

Release history Release notifications | RSS feed

0.0.4

2 release files

This release

0.0.3 This release

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page