diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/.gitignore b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..5fe5c08858a9f78b16a14e3d3757641d03307c72 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/.gitignore @@ -0,0 +1,174 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +share/python-wheels/ +*.egg-info/ +.installed.cfg +*.egg +MANIFEST + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.nox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +*.py,cover +.hypothesis/ +.pytest_cache/ +cover/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py +db.sqlite3 +db.sqlite3-journal + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +.pybuilder/ +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# IPython +profile_default/ +ipython_config.py + +# pyenv +# For a library or package, you might want to ignore these files since the code is +# intended to run in multiple environments; otherwise, check them in: +# .python-version + +# pipenv +# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. +# However, in case of collaboration, if having platform-specific dependencies or dependencies +# having no cross-platform support, pipenv may install dependencies that don't work, or not +# install all needed dependencies. +#Pipfile.lock + +# poetry +# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. +# This is especially recommended for binary packages to ensure reproducibility, and is more +# commonly ignored for libraries. +# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control +#poetry.lock + +# pdm +# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. +#pdm.lock +# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it +# in version control. +# https://pdm.fming.dev/latest/usage/project/#working-with-version-control +.pdm.toml +.pdm-python +.pdm-build/ + +# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm +__pypackages__/ + +# Celery stuff +celerybeat-schedule +celerybeat.pid + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ +.dmypy.json +dmypy.json + +# Pyre type checker +.pyre/ + +# pytype static type analyzer +.pytype/ + +# Cython debug symbols +cython_debug/ + +# PyCharm +# JetBrains specific template is maintained in a separate JetBrains.gitignore that can +# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore +# and can be added to the global gitignore or merged into this file. For a more nuclear +# option (not recommended) you can uncomment the following to ignore the entire idea folder. +#.idea/ + +.DS_Store +# data/adult +data/beijing +data/default +data/magic +data/news +data/shoppers + +wandb/ + +*.DS_Store diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/LICENCE b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/LICENCE new file mode 100644 index 0000000000000000000000000000000000000000..421b2ef006d92669068729de1866b3dde6b3fd45 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/LICENCE @@ -0,0 +1,7 @@ +Copyright 2024 Andrés Guzmán-Cordero + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/README.md b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/README.md new file mode 100644 index 0000000000000000000000000000000000000000..ffe4e59cce3dd04f5d51853fb14ac71daa561843 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/README.md @@ -0,0 +1,128 @@ +# Exponential Family Variational Flow Matching for Tabular Data Generation + +

+ + MIT License + + + Openreview + + + Paper URL + +

+ +
+ Model Logo +

Figure 1: Exponential Family Variational Flow Matching (EF-VFM) is a generative modeling framework designed for mixed continuous +and discrete variables. By leveraging the exponential family and a mean-field assumption, EF-VFM efficiently matches the sufficient +statistics of the distributions via learned probability paths, ensuring state-of-the-art fidelity and diversity in synthetic data.

+
+ +This repository provides the prototypical implementation of EF-VFM: TabbyFlow (ICML, 2025). + +## Latest Update + +- [2025.09]:We are finally releasing our code! To speed the release and avoid compatibility isues, we removed the hyperparameter scripts we use to launch out experiments in our available cluster. Contact us if you have any questions! + +## Introduction + +EF-VFM uses the exponential family to jointly model different distributions with a single variational flow matching framework. Its key contributions are: + +1) We propose Exponential Family Variational Flow Matching (EF-VFM), an extension of VFM that incorporates exponential family distributions that facilitates efficient training via moment matching. +2) We establish a deep connection between VFM and a generalized flow matching objective through the lens of Bregman divergences, offering a theoretical foundation for learning probability paths over mixed data types. +3) To demonstrate the effectiveness of EF-VFM, we introduce TabbyFlow, a model that achieves state-of-the-art performance on standard tabular benchmarks, improving both fidelity and diversity in synthetic data generation. + +The schema of EF-VFM is presented in the figure above. For more details, please refer to [our paper](https://arxiv.org/pdf/2506.05940). + +## Environment Setup + +Create the main environment with [ef_vfm.yaml](ef_vfm.yaml). This environment will be used for all tasks except for the evaluation of additional data fidelity metrics (i.e., $\alpha$-precision and $\beta$-recall scores) + +```conda env create -f ef_vfm.yaml``` + +Create another environment with [synthcity.yaml](synthcity.yaml) to evaluate additional data fidelity metrics + +```conda env create -f synthcity.yaml``` + +## Datasets Preparation + +### Using the datasets experimented in the paper + +Download raw datasets: + +```python download_dataset.py``` + +Process datasets: + +```python process_dataset.py``` + +## Training TabbyFlow + +To train an unconditional EF-VFM model across the entire table, run + +```python main.py --dataname --mode train --exp_name ``` + +where `````` is the name of the dataset you want to train on, and `````` is the name of your experiment. + +Current Options of `````` are: adult, default, shoppers, magic, beijing, news + +Wanb logging is enabled by default. To disable it and log locally, add the ```--no_wandb``` flag. + +You must specify the experiment name, which will be used for logging and saving files, add ```--exp_name ```. + +## Sampling and Evaluating TabbyFlow (Density, MLE, C2ST) + +To sample synthetic tables from trained EF-VFM models and evaluate them, run + +```python main.py --dataname --mode test --report --no_wandb --exp_name ``` + +where `````` and `````` should be the same as those used in training. + +This will sample 20 synthetic tables randomly. Meanwhile, it will evaluate the density, mle, and c2st scores for each sample and report their average and standard deviation. The results will be printed out in the terminal, and the samples and detailed evaluation results will be placed in ./eval/report_runs///. + +## Evaluating on Additional Fidelity Metrics ($\alpha$-precision and $\beta$-recall scores) + +To evaluate EF-VFM on the additional fidelity metrics ($\alpha$-precision and $\beta$-recall scores), you need to first make sure that you have already generated some samples by the previous commands. Then, you need to switch to the `synthcity` environment (as the synthcity packet used to compute those metrics conflicts with the main environment), by running + +```conda activate synthcity``` + +Then, evaluate the metrics by running + +```python eval/eval_quality.py --dataname ``` + +Similarly, the results will be printed out in the terminal and added to ./eval/report_runs/// + +## Evaluating Data Privacy (DCR score) + +To evalute the privacy metric DCR score, you first need to retrain all the models, as the metric requires an equal split between the training and testing data (our initial splits employ a 90/10 ratio). To retrain with an equal split, run the training command but append `_dcr` to `````` + +```python main.py --dataname _dcr --mode train``` + +Then, test the models on DCR with the same `_dcr` suffix + +```python main.py --dataname _dcr --mode test --report --no_wandb``` + +## License + +This work is licensed under the MIT License. + +## Acknowledgement + +This repo is built upon the previous work TabDiff's [[codebase]](https://github.com/MinkaiXu/TabDiff). Many thanks to Juntong, Minkai, Harper and Hengrui! + +## Citation + +```@inproceedings{ +guzmancordero2025exponentialfamily, +title={Exponential Family Variational Flow Matching for Tabular Data Generation}, +author={Andr\'es Guzm\'an-Cordero and Floor Eijkelboom and Jan-Willem van de Meent}, +booktitle={The Forty-Second International Conference on Machine Learning}, +year={2025}, +url={https://openreview.net/forum?id=kjtvCSkSsy} +} +``` + +## Contact + +If you encounter any problem or you have any question regarding the paper, please contact [Andrés](andresguzco@gmail.com). diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..3e4e5bb742d8d0c5497ec4ec864f1f3d595a7a55 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5160adcfd7a3dae2c17b5f31ba22d95318143f8ac4060711377a03f5431e38a +size 4092888 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..f3747fcd7e942d6ed4b2fa3bc9000043ea2ed0bb --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2afe152298b9b50f482d85dae554b6e35d6e98e43a32bbbafa4bb90d8770aea9 +size 32630248 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..89d8521e13cfe324582788e159a80b911f23630e --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_cat_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cd6b9e6e1227d5c8d6bec250b01723d86289999b2941b93efacc0b077fe4d6ae +size 4068008 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..e024771b21afd3380f7909bc4a008c3d4990fc09 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:300d9dfe9e44f5c06842165d657a72abbe126f90ef97854177e63ca429686468 +size 4076 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..624924ae67ad4e3ac474ef42f0a8455ded2eeb1e --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df2f44047e580945b1b5b7564af9fb585edd796a433a013d355aaac6a4897a4e +size 31604 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..634ed815e1441e488b5e2976bf8206ae5e93fdbf --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/X_num_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f6ff5229f67a68378f1ac2ddf0cbf9d6bcd9ac35aff540e8d7434418a119f075 +size 4052 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/info.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/info.json new file mode 100644 index 0000000000000000000000000000000000000000..b7885431320aa7b2b9480542436bf05d5417d8cc --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c7e4b1ec5600b398fb81dc17fe173571e8c31ccb75bc7a71a115b049c083b72a +size 239660 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/real.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/real.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/real.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/staged_features.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/test.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/train.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/val.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..ead69000308d740029106af368f28be74e4a4984 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0827ebc8f8dfce84f28bfed2e70fc2736d3d5ef9489400232a27ad8de35a9e11 +size 2760 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..6ecd5a37945d502473b0b23292f01d52b03957d6 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/data/pipeline_c12/y_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2405e82f954de2d2909d0f30c075b2481e20ed9963101c4c0fafa1539271e127 +size 2744 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/download_dataset.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/download_dataset.py new file mode 100644 index 0000000000000000000000000000000000000000..427dbbdc686039d81b03aa05d721d06c5b0dcd47 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/download_dataset.py @@ -0,0 +1,49 @@ +import os +from urllib import request +import zipfile + +DATA_DIR = 'data' + + +NAME_URL_DICT_UCI = { + 'adult': 'https://archive.ics.uci.edu/static/public/2/adult.zip', + 'default': 'https://archive.ics.uci.edu/static/public/350/default+of+credit+card+clients.zip', + 'magic': 'https://archive.ics.uci.edu/static/public/159/magic+gamma+telescope.zip', + 'shoppers': 'https://archive.ics.uci.edu/static/public/468/online+shoppers+purchasing+intention+dataset.zip', + 'beijing': 'https://archive.ics.uci.edu/static/public/381/beijing+pm2+5+data.zip', + 'news': 'https://archive.ics.uci.edu/static/public/332/online+news+popularity.zip', + 'news_nocat': 'https://archive.ics.uci.edu/static/public/332/online+news+popularity.zip', + 'adult_dcr': 'https://archive.ics.uci.edu/static/public/2/adult.zip', + 'default_dcr': 'https://archive.ics.uci.edu/static/public/350/default+of+credit+card+clients.zip', + 'magic_dcr': 'https://archive.ics.uci.edu/static/public/159/magic+gamma+telescope.zip', + 'shoppers_dcr': 'https://archive.ics.uci.edu/static/public/468/online+shoppers+purchasing+intention+dataset.zip', + 'beijing_dcr': 'https://archive.ics.uci.edu/static/public/381/beijing+pm2+5+data.zip', + 'news_dcr': 'https://archive.ics.uci.edu/static/public/332/online+news+popularity.zip', +} + +def unzip_file(zip_filepath, dest_path): + with zipfile.ZipFile(zip_filepath, 'r') as zip_ref: + zip_ref.extractall(dest_path) + + +def download_from_uci(name): + + print(f'Start processing dataset {name} from UCI.') + save_dir = f'{DATA_DIR}/{name}' + if not os.path.exists(save_dir): + os.makedirs(save_dir) + + url = NAME_URL_DICT_UCI[name] + request.urlretrieve(url, f'{save_dir}/{name}.zip') + print(f'Finish downloading dataset from {url}, data has been saved to {save_dir}.') + + unzip_file(f'{save_dir}/{name}.zip', save_dir) + print(f'Finish unzipping {name}.') + + else: + print('Aready downloaded.') + +if __name__ == '__main__': + for name in NAME_URL_DICT_UCI.keys(): + download_from_uci(name) + \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/ckpt/pipeline_c12/adapter_efvfm/config.pkl b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/ckpt/pipeline_c12/adapter_efvfm/config.pkl new file mode 100644 index 0000000000000000000000000000000000000000..fa54b6b1304b9f1933fc2a8ce9aa617c3df781db --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/ckpt/pipeline_c12/adapter_efvfm/config.pkl @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e06a7bb227a7ef1a7069ce8bf2348803714f6c4623f7d9ecd7cd6d89eacb94f1 +size 4046 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/configs/ef_vfm_configs.toml b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/configs/ef_vfm_configs.toml new file mode 100644 index 0000000000000000000000000000000000000000..da1df42825e99fb19a331757d981a43fd5c25472 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/configs/ef_vfm_configs.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:677698232b3ea325b54527cccdc11c49fadb971129a77065e71d64aa7567ddb6 +size 674 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/main.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/main.py new file mode 100644 index 0000000000000000000000000000000000000000..d3e0966c01ffb317e0d8cb94b6f293992dbfbdc1 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/main.py @@ -0,0 +1,246 @@ +import glob +import json +import os +import pickle +import random + +import numpy as np +from ef_vfm.metrics import TabMetrics +from ef_vfm.modules.main_modules import UniModMLP +from ef_vfm.models.flow_model import ExpVFM +from ef_vfm.trainer import Trainer +import src +import torch + +from torch.utils.data import DataLoader +import argparse +import warnings + +import wandb + + +from utils_train import EFVFMDataset + +warnings.filterwarnings('ignore') + + +def main(args): + device = args.device + + ## Disable scientific numerical format + np.set_printoptions(suppress=True) + torch.set_printoptions(sci_mode=False) + + ## Get data info + dataname = args.dataname + data_dir = f'data/{dataname}' + info_path = f'data/{dataname}/info.json' + with open(info_path, 'r') as f: + info = json.load(f) + + ## Set up flags + is_dcr = 'dcr' in dataname + + ## Set experiment name + exp_name = args.exp_name + assert args.exp_name is not None, "Experiment name must be provided" + + ## Load configs + curr_dir = os.path.dirname(os.path.abspath(__file__)) + config_path = f'{curr_dir}/configs/ef_vfm_configs.toml' + raw_config = src.load_config(config_path) + + print(f"{args.mode.capitalize()} Mode is Enabled") + num_samples_to_generate = None + ckpt_path = None + if args.mode == 'train': + print("NEW training is started") + elif args.mode == 'test': + num_samples_to_generate = args.num_samples_to_generate + ckpt_path = args.ckpt_path + if ckpt_path is None: + ckpt_parent_path = f"{curr_dir}/ckpt/{dataname}/{exp_name}" + ckpt_path_arr = glob.glob(f"{ckpt_parent_path}/best_ema_model*") + assert ckpt_path_arr, f"Cannot not infer ckpt_path from {ckpt_parent_path}, please make sure that you first train a model before testing!" + ckpt_path = ckpt_path_arr[0] + config_path = os.path.join(os.path.dirname(ckpt_path), 'config.pkl') + if os.path.exists(config_path): + with open(config_path, 'rb') as f: + cached_raw_config = pickle.load(f) + print(f"Found cached config at {config_path}") + raw_config = cached_raw_config + + + ## Creat model_save and result paths + model_save_path, result_save_path = None, None + if args.mode == 'train': + model_save_path = 'debug/ckpt' if args.debug else f'{curr_dir}/ckpt/{dataname}/{exp_name}' + result_save_path = model_save_path.replace('ckpt', 'result') #i.e., f'{curr_dir}/results/{dataname}/{exp_name}' + elif args.mode == 'test': + if args.report: + result_save_path = f"eval/report_runs/{exp_name}/{dataname}" + else: + result_save_path = os.path.dirname(ckpt_path).replace('ckpt', 'result') # infer the exp_name from the ckpt_name + raw_config['model_save_path'] = model_save_path + raw_config['result_save_path'] = result_save_path + if model_save_path is not None: + if not os.path.exists(model_save_path): + os.makedirs(model_save_path) + if result_save_path is not None: + if not os.path.exists(result_save_path): + os.makedirs(result_save_path) + + ## Make everything determinstic if needed + raw_config['deterministic'] = args.deterministic + if args.deterministic: + print("DETERMINISTIC MODE is enabled!!!") + ## Set global random seeds + torch.manual_seed(0) + random.seed(0) + np.random.seed(0) + + ## Ensure deterministic CUDA operations + os.environ['PYTHONHASHSEED'] = '0' + os.environ['CUBLAS_WORKSPACE_CONFIG'] = ':4096:8' # or ':16:8' + torch.use_deterministic_algorithms(True) + if torch.cuda.is_available(): + torch.cuda.manual_seed(0) + torch.cuda.manual_seed_all(0) + torch.backends.cudnn.deterministic = True + torch.backends.cudnn.benchmark = False + + ## Set debug mode parameters + if args.debug: # fast eval for DEBUG mode + raw_config['train']['main']['check_val_every'] = 2 + raw_config['train']['main']['batch_size'] = 4096 + raw_config['sample']['batch_size'] = 10000 + + _smoke = os.environ.get("EFVFM_SMOKE_STEPS", "").strip() + if _smoke and args.mode == "train": + n = max(1, int(_smoke)) + raw_config["train"]["main"]["steps"] = n + raw_config["train"]["main"]["check_val_every"] = max( + 1, min(n, raw_config["train"]["main"]["check_val_every"]) + ) + if os.environ.get("EFVFM_ADAPTER_TRAIN", "").strip() and args.mode == "train": + raw_config["train"]["main"]["check_val_every"] = int(raw_config["train"]["main"]["steps"]) + + _sample_batch = os.environ.get("EFVFM_SAMPLE_BATCH_SIZE", "").strip() + if _sample_batch: + raw_config["sample"]["batch_size"] = max(1, int(_sample_batch)) + _train_workers = os.environ.get("EFVFM_TRAIN_NUM_WORKERS", "").strip() + train_num_workers = max(0, int(_train_workers)) if _train_workers else 4 + + ## Load training data + batch_size = raw_config['train']['main']['batch_size'] + + train_data = EFVFMDataset(dataname, data_dir, info, isTrain=True, dequant_dist=raw_config['data']['dequant_dist'], int_dequant_factor=raw_config['data']['int_dequant_factor']) + train_loader = DataLoader( + train_data, + batch_size = batch_size, + shuffle = True, + num_workers = train_num_workers, + ) + d_numerical, categories = train_data.d_numerical, train_data.categories + + val_data = EFVFMDataset(dataname, data_dir, info, isTrain=False, dequant_dist=raw_config['data']['dequant_dist'], int_dequant_factor=raw_config['data']['int_dequant_factor']) + + ## Load Metrics + real_data_path = f'synthetic/{dataname}/real.csv' + test_data_path = f'synthetic/{dataname}/test.csv' + val_data_path = f'synthetic/{dataname}/val.csv' + if not os.path.exists(val_data_path): + print(f"{args.dataname} does not have its validation set. During MLE evaluation, a validation set will be splitted from the training set!") + val_data_path = None + if args.mode == 'train': + metric_list = ["density"] + else: + if is_dcr: + metric_list = ["dcr"] + else: + metric_list = [ + "density", + "mle", + "c2st", + ] + metrics = TabMetrics(real_data_path, test_data_path, val_data_path, info, device, metric_list=metric_list) + + ## Load the module and models + raw_config['unimodmlp_params']['d_numerical'] = d_numerical + raw_config['unimodmlp_params']['categories'] = (categories).tolist() + model = UniModMLP(**raw_config['unimodmlp_params']) + model.to(device) + + flow_model = ExpVFM( + num_classes=categories, + num_numerical_features=d_numerical, + vf_fn=model, + device=device, + ) + num_params = sum(p.numel() for p in flow_model.parameters()) + print("The number of parameters = ", num_params) + flow_model.to(device) + flow_model.train() + + ## Print the configs + printed_configs = json.dumps(raw_config, default=lambda x: int(x) if isinstance(x, np.int64) else x, indent=4) + print(f"The config of the current run is : \n {printed_configs}") + + ## Enable Wandb + project_name = f"XVFM_{dataname}" + raw_config['project_name'] = project_name + logger = wandb.init( + project=raw_config['project_name'], + name=exp_name, + config=raw_config, + mode='disabled' if args.debug or args.no_wandb else 'online', + ) + + ## Load Trainer + sample_batch_size = raw_config['sample']['batch_size'] + trainer = Trainer( + flow_model, + train_loader, + train_data, + val_data, + metrics, + logger, + **raw_config['train']['main'], + sample_batch_size=sample_batch_size, + num_samples_to_generate=num_samples_to_generate, + model_save_path=raw_config['model_save_path'], + result_save_path=raw_config['result_save_path'], + device=device, + ckpt_path=ckpt_path, + ) + if args.mode == 'test': + if args.report: + if is_dcr: + trainer.report_test_dcr(args.num_runs) + else: + trainer.report_test(args.num_runs) + else: + trainer.test() + else: + ## Save config + config_save_path = raw_config['model_save_path'] + with open (os.path.join(config_save_path, 'config.pkl'), 'wb') as f: + pickle.dump(raw_config, f) + trainer.run_loop() + + + +if __name__ == '__main__': + + parser = argparse.ArgumentParser(description='Training of TabbyFlow') + + parser.add_argument('--dataname', type=str, default='adult', help='Name of dataset.') + parser.add_argument('--gpu', type=int, default=0, help='GPU index.') + + args = parser.parse_args() + + # check cuda + if args.gpu != -1 and torch.cuda.is_available(): + args.device = f'cuda:{args.gpu}' + else: + args.device = 'cpu' diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/metrics.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/metrics.py new file mode 100644 index 0000000000000000000000000000000000000000..4f104427533ac37610c92216b135fdeba3d181be --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/metrics.py @@ -0,0 +1,306 @@ +from copy import deepcopy +import numpy as np +import torch +import pandas as pd +# Metrics +from eval.mle.mle import get_evaluator +from eval.visualize_density import plot_density +from sdmetrics.reports.single_table import QualityReport, DiagnosticReport +from sdmetrics.single_table import LogisticDetection +from sklearn.preprocessing import OneHotEncoder + +from tqdm import tqdm + + +class TabMetrics(object): + def __init__(self, real_data_path, test_data_path, val_data_path, info, device, metric_list) -> None: + self.real_data_path = real_data_path + self.test_data_path = test_data_path + self.val_data_path = val_data_path + self.info = info + self.device = device + self.real_data_size = len(pd.read_csv(real_data_path)) + self.metric_list = metric_list + + def evaluate(self, syn_data): + metrics, extras = {}, {} + syn_data_cp = deepcopy(syn_data) + for metric in self.metric_list: + func = eval(f"self.evaluate_{metric}") + print(f"Evaluating {metric}") + out_metrics, out_extras = func(syn_data_cp) + metrics.update(out_metrics) + extras.update(out_extras) + return metrics, extras + + def evaluate_density(self, syn_data): + real_data = pd.read_csv(self.real_data_path) + real_data.columns = range(len(real_data.columns)) + syn_data.columns = range(len(syn_data.columns)) + + + info = deepcopy(self.info) + + y_only = len(syn_data.columns)==1 + if y_only: + target_col_idx = info['target_col_idx'][0] + syn_data = self.complete_y_only_data(syn_data, real_data, target_col_idx) + + metadata = info['metadata'] + metadata['columns'] = {int(key): value for key, value in metadata['columns'].items()} # ensure that keys are all integers? + + new_real_data, new_syn_data, metadata = reorder(real_data, syn_data, info) + + qual_report = QualityReport() + qual_report.generate(new_real_data, new_syn_data, metadata) + + diag_report = DiagnosticReport() + diag_report.generate(new_real_data, new_syn_data, metadata) + + quality = qual_report.get_properties() + diag = diag_report.get_properties() + + Shape = quality['Score'][0] + Trend = quality['Score'][1] + + Overall = (Shape + Trend) / 2 + + shape_details = qual_report.get_details(property_name='Column Shapes') + trend_details = qual_report.get_details(property_name='Column Pair Trends') + + if y_only: + Shape = shape_details['Score'].min() + out_metrics = { + "density/Shape": Shape, + "density/Trend": Trend, + "density/Overall": Overall, + } + out_extras = { + "shapes": shape_details, + "trends": trend_details + } + return out_metrics, out_extras + + def evaluate_mle(self, syn_data): + train = syn_data.to_numpy() + test = pd.read_csv(self.test_data_path).to_numpy() + val = pd.read_csv(self.val_data_path).to_numpy() if self.val_data_path else None + + info = deepcopy(self.info) + + task_type = info['task_type'] + + evaluator = get_evaluator(task_type) + + if task_type == 'regression': + best_r2_scores, best_rmse_scores = evaluator(train, test, info, val=val) + + overall_scores = {} + for score_name in ['best_r2_scores', 'best_rmse_scores']: + overall_scores[score_name] = {} + + scores = eval(score_name) + for method in scores: + name = method['name'] + method.pop('name') + overall_scores[score_name][name] = method + + else: + best_f1_scores, best_weighted_scores, best_auroc_scores, best_acc_scores, best_avg_scores = evaluator(train, test, info, val=val) + + overall_scores = {} + for score_name in ['best_f1_scores', 'best_weighted_scores', 'best_auroc_scores', 'best_acc_scores', 'best_avg_scores']: + overall_scores[score_name] = {} + + scores = eval(score_name) + for method in scores: + name = method['name'] + method.pop('name') + overall_scores[score_name][name] = method + + mle_score = overall_scores['best_rmse_scores']['XGBRegressor']['RMSE'] if task_type == 'regression' else overall_scores['best_auroc_scores']['XGBClassifier']['roc_auc'] + out_metrics = { + "mle": mle_score, + } + out_extras = { + "mle": overall_scores, + } + return out_metrics, out_extras + + def evaluate_c2st(self, syn_data): + info = deepcopy(self.info) + real_data = pd.read_csv(self.real_data_path) + + real_data.columns = range(len(real_data.columns)) + syn_data.columns = range(len(syn_data.columns)) + + metadata = info['metadata'] + metadata['columns'] = {int(key): value for key, value in metadata['columns'].items()} + + new_real_data, new_syn_data, metadata = reorder(real_data, syn_data, info) + + score = LogisticDetection.compute( + real_data=new_real_data, + synthetic_data=new_syn_data, + metadata=metadata + ) + + out_metrics = { + "c2st": score, + } + out_extras = {} + return out_metrics, out_extras + + def evaluate_dcr(self, syn_data): + info = deepcopy(self.info) + real_data = pd.read_csv(self.real_data_path) + test_data = pd.read_csv(self.test_data_path) + + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + task_type = info['task_type'] + if task_type == 'regression': + num_col_idx += target_col_idx + else: + cat_col_idx += target_col_idx + + num_ranges = [] + + real_data.columns = list(np.arange(len(real_data.columns))) + syn_data.columns = list(np.arange(len(real_data.columns))) + test_data.columns = list(np.arange(len(real_data.columns))) + for i in num_col_idx: + num_ranges.append(real_data[i].max() - real_data[i].min()) + + num_ranges = np.array(num_ranges) + + + num_real_data = real_data[num_col_idx] + cat_real_data = real_data[cat_col_idx] + num_syn_data = syn_data[num_col_idx] + cat_syn_data = syn_data[cat_col_idx] + num_test_data = test_data[num_col_idx] + cat_test_data = test_data[cat_col_idx] + + num_real_data_np = num_real_data.to_numpy() + cat_real_data_np = cat_real_data.to_numpy().astype('str') + num_syn_data_np = num_syn_data.to_numpy() + cat_syn_data_np = cat_syn_data.to_numpy().astype('str') + num_test_data_np = num_test_data.to_numpy() + cat_test_data_np = cat_test_data.to_numpy().astype('str') + + encoder = OneHotEncoder() + cat_complete_data_np = np.concatenate([cat_real_data_np, cat_test_data_np], axis=0) + encoder.fit(cat_complete_data_np) + # encoder.fit(cat_real_data_np) + + + cat_real_data_oh = encoder.transform(cat_real_data_np).toarray() + cat_syn_data_oh = encoder.transform(cat_syn_data_np).toarray() + cat_test_data_oh = encoder.transform(cat_test_data_np).toarray() + + num_real_data_np = num_real_data_np / num_ranges + num_syn_data_np = num_syn_data_np / num_ranges + num_test_data_np = num_test_data_np / num_ranges + + real_data_np = np.concatenate([num_real_data_np, cat_real_data_oh], axis=1) + syn_data_np = np.concatenate([num_syn_data_np, cat_syn_data_oh], axis=1) + test_data_np = np.concatenate([num_test_data_np, cat_test_data_oh], axis=1) + + device = self.device + + real_data_th = torch.tensor(real_data_np).to(device) + syn_data_th = torch.tensor(syn_data_np).to(device) + test_data_th = torch.tensor(test_data_np).to(device) + + dcrs_real = [] + dcrs_test = [] + batch_size = 10000 // cat_real_data_oh.shape[1] # This esitmation should make sure that dcr_real and dcr_test can be fit into 10GB GPU memory + + for i in tqdm(range((syn_data_th.shape[0] // batch_size) + 1)): + if i != (syn_data_th.shape[0] // batch_size): + batch_syn_data_th = syn_data_th[i*batch_size: (i+1) * batch_size] + else: + batch_syn_data_th = syn_data_th[i*batch_size:] + + dcr_real = (batch_syn_data_th[:, None] - real_data_th).abs().sum(dim = 2).min(dim = 1).values + dcr_test = (batch_syn_data_th[:, None] - test_data_th).abs().sum(dim = 2).min(dim = 1).values + dcrs_real.append(dcr_real) + dcrs_test.append(dcr_test) + + dcrs_real = torch.cat(dcrs_real) + dcrs_test = torch.cat(dcrs_test) + + score = (dcrs_real < dcrs_test).nonzero().shape[0] / dcrs_real.shape[0] + + out_metrics = { + "dcr": score, + } + out_extras = { + "dcr_real": dcrs_real.cpu().numpy(), + "dcr_test": dcrs_test.cpu().numpy(), + } + return out_metrics, out_extras + + + def plot_density(self, syn_data): + syn_data_cp = deepcopy(syn_data) + real_data = pd.read_csv(self.real_data_path) + info = deepcopy(self.info) + y_only = len(syn_data_cp.columns)==1 + if y_only: + target_col_idx = info['target_col_idx'][0] + target_col_name = info['column_names'][target_col_idx] + syn_data_cp = self.complete_y_only_data(syn_data_cp, real_data, target_col_name) + img = plot_density(syn_data_cp, real_data, info) + return img + + def complete_y_only_data(self, syn_data, real_data, target_col_idx): + syn_target_col = deepcopy(syn_data.iloc[:, 0]) + syn_data = deepcopy(real_data) + syn_data[target_col_idx] = syn_target_col + return syn_data + + +def reorder(real_data, syn_data, info): + num_col_idx = deepcopy(info['num_col_idx']) # BUG: info will be modified by += in the next few lines + cat_col_idx = deepcopy(info['cat_col_idx']) + target_col_idx = deepcopy(info['target_col_idx']) + + task_type = info['task_type'] + if task_type == 'regression': + num_col_idx += target_col_idx + else: + cat_col_idx += target_col_idx + + real_num_data = real_data[num_col_idx] + real_cat_data = real_data[cat_col_idx] + + new_real_data = pd.concat([real_num_data, real_cat_data], axis=1) + new_real_data.columns = range(len(new_real_data.columns)) + + syn_num_data = syn_data[num_col_idx] + syn_cat_data = syn_data[cat_col_idx] + + new_syn_data = pd.concat([syn_num_data, syn_cat_data], axis=1) + new_syn_data.columns = range(len(new_syn_data.columns)) + + + metadata = info['metadata'] + + columns = metadata['columns'] + metadata['columns'] = {} + + inverse_idx_mapping = info['inverse_idx_mapping'] + + + for i in range(len(new_real_data.columns)): + if i < len(num_col_idx): + metadata['columns'][i] = columns[num_col_idx[i]] + else: + metadata['columns'][i] = columns[cat_col_idx[i-len(num_col_idx)]] + + + return new_real_data, new_syn_data, metadata \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/models/flow_model.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/models/flow_model.py new file mode 100644 index 0000000000000000000000000000000000000000..536d0cd1311210bac6bbc91dcc31d0612ca053b6 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/models/flow_model.py @@ -0,0 +1,195 @@ +import torch.nn.functional as F +import torch +import numpy as np +from torchdiffeq import odeint_adjoint as odeint + + +class ExpVFM(torch.nn.Module): + def __init__( + self, + num_classes: np.array, + num_numerical_features: int, + vf_fn, + device=torch.device('cpu'), + **kwargs + ): + + super(ExpVFM, self).__init__() + + self.num_numerical_features = num_numerical_features + self.num_classes = num_classes # it as a vector [K1, K2, ..., Km] + self.num_classes_expanded = torch.from_numpy( + np.concatenate([num_classes[i].repeat(num_classes[i]) for i in range(len(num_classes))]) + ).to(device) if len(num_classes)>0 else torch.tensor([]).to(device).int() + self.neg_infinity = -1000000.0 + + offsets = np.cumsum(self.num_classes) + offsets = np.append([0], offsets) + self.slices_for_classes = [] + for i in range(1, len(offsets)): + self.slices_for_classes.append(np.arange(offsets[i - 1], offsets[i])) + self.offsets = torch.from_numpy(offsets).to(device) + + offsets = np.cumsum(self.num_classes) + np.arange(1, len(self.num_classes)+1) + offsets = np.append([0], offsets) + + self._vf_fn = vf_fn + self.device = device + + + def mixed_loss(self, x): + b = x.shape[0] + dev = x.device + + x_num = x[:, :self.num_numerical_features] + x_cat = x[:, self.num_numerical_features:].long() + + t = torch.rand(b, device=dev, dtype=x_num.dtype) + t = t[:, None] + + # Continuous interpolation + x_num_t = x_num + if x_num.shape[1] > 0: + noise = torch.randn_like(x_num) + x_num_t = t * x_num + (1 - t) * noise # + noise * sigma_num + + # Discrete interpolation + x_cat_oh = self.to_one_hot(x_cat).float() + x_cat_t = x_cat_oh + if x_cat.shape[1] > 0: + x_cat_t = t * x_cat_oh + (1 - t) * torch.randn_like(x_cat_oh) + + # Predict orignal data (distribution) + model_out_num, model_out_cat = self._vf_fn(x_num_t, x_cat_t, t.squeeze()) + + d_loss = torch.zeros((1,)).float() + c_loss = torch.zeros((1,)).float() + + # Compute the loss + if x_num.shape[1] > 0: + c_loss = self._mvgloss(model_out_num, x_num, t) + + if x_cat.shape[1] > 0: + d_loss = self._absorbed_closs(model_out_cat, x_cat, self._vf_fn.categories) + + return d_loss.mean(), c_loss.mean() + + def _mvgloss(self, mu_t, x_num_t, t): + n, k = mu_t.shape + dev = mu_t.device + dt = mu_t.dtype + + identity = torch.eye(k, device=dev, dtype=dt).unsqueeze(0).expand(n, -1, -1) + scale = 1 - (1 - 0.01) * t.unsqueeze(1) ** 2 + sigma = scale * identity + dist = torch.distributions.MultivariateNormal(mu_t, sigma) + return -dist.log_prob(x_num_t).mean() + + @torch.no_grad() + def sample(self, num_samples): + dev = self.device + dt = torch.float32 + d_in = self.num_numerical_features + sum(self.num_classes) + d_out = self.num_numerical_features + len(self.num_classes) + + x0 = torch.randn(num_samples, d_in, device=dev) + t = torch.tensor([0.0, 0.999]).to(dev) + vf = Velocity(self._vf_fn) + trajectory = odeint(vf, x0, t, method="dopri5", rtol=1e-5, atol=1e-5) + out = trajectory[1] + + sample = torch.zeros(num_samples, d_out, device=dev, dtype=dt) + sample[:, :self.num_numerical_features] = out[:, :self.num_numerical_features].to(torch.float32) + if sum(self.num_classes) != 0: + idx = self.num_numerical_features + for i, val in enumerate(self.num_classes): + col = self.num_numerical_features + i + sample[:, col] = torch.argmax(out[:, idx:idx + val], dim=1) + idx += val + assert val >= sample[:, col].max() >= 0, f"Sampled value {sample[:, col].max()} is out of range for categorical feature {i} with {val} classes." + + return sample.cpu() + + def sample_all(self, num_samples, batch_size, keep_nan_samples=False): + b = batch_size + + all_samples = [] + num_generated = 0 + while num_generated < num_samples: + print(f"Samples left to generate: {num_samples-num_generated}") + sample = self.sample(b) + mask_nan = torch.any(sample.isnan(), dim=1) + if keep_nan_samples: + # If the sample instances that contains Nan are decided to be kept, the row with Nan will be foreced to all zeros + sample = sample * (~mask_nan)[:, None] + else: + # Otherwise the instances with Nan will be eliminated + sample = sample[~mask_nan] + + all_samples.append(sample) + num_generated += sample.shape[0] + + x_gen = torch.cat(all_samples, dim=0)[:num_samples] + + return x_gen + + def to_one_hot(self, x_cat): + if len(self.num_classes) == 0: + return torch.zeros(x_cat.shape[0], 0, device=x_cat.device, dtype=torch.long) + x_cat_oh = torch.cat( + [F.one_hot(x_cat[:, i], num_classes=self.num_classes[i]) for i in range(len(self.num_classes))], + dim=-1 + ) + return x_cat_oh + + def _absorbed_closs(self, model_output, x0, cats): #, sigma, dsigma): + """ + alpha: (bs,) + """ + cum_sum =0 + losses = torch.zeros(len(cats), device=model_output.device) + for i, val in enumerate(cats): + dist = torch.distributions.Categorical(logits=model_output[:, cum_sum:cum_sum+val]) + losses[i] = -dist.log_prob(x0[:, i]).mean() + cum_sum += val + + loss = losses.sum() + return loss + + +class Velocity(torch.nn.Module): + def __init__(self, model): + super(Velocity, self).__init__() + self.model = model + + def forward(self, t, x): + t = t * torch.ones(x.shape[0]).to(x.device) + + x_num = x[:, :self.model.d_numerical] + x_cat = x[:, self.model.d_numerical:] + mu, logits = self.model(x_num, x_cat, t) + + # Numerical velocity + if self.model.d_numerical > 0: + v_num = (mu - (1 - 0.01) * x_num) / (1 - (1 - 0.01) * t.unsqueeze(1)) + else: + v_num = torch.zeros_like(x_num) + + # Categorical velocity: normalize logits into probability space before computing velocity + if len(self.model.categories) > 0: + v_cat_parts = [] + logit_idx = 0 + oh_idx = 0 + for k in self.model.categories: + probs_k = F.softmax(logits[:, logit_idx:logit_idx + k], dim=-1) + x_k = x_cat[:, oh_idx:oh_idx + k] + v_k = (probs_k - (1 - 0.01) * x_k) / (1 - (1 - 0.01) * t.unsqueeze(1)) + v_cat_parts.append(v_k) + logit_idx += k + oh_idx += k + v_cat = torch.cat(v_cat_parts, dim=1) + else: + v_cat = torch.zeros_like(x_cat) + + v_t = torch.cat([v_num, v_cat], dim=1) + return v_t \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/main_modules.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/main_modules.py new file mode 100644 index 0000000000000000000000000000000000000000..46dceb368af3302e55d5e448a2ffede4db122977 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/main_modules.py @@ -0,0 +1,102 @@ +from typing import Callable, Union + +from ef_vfm.modules.transformer import Reconstructor, Tokenizer, Transformer +import torch +import torch.nn as nn +import torch.optim + +ModuleType = Union[str, Callable[..., nn.Module]] + +class SiLU(nn.Module): + def forward(self, x): + return x * torch.sigmoid(x) + + +class PositionalEmbedding(torch.nn.Module): + def __init__(self, num_channels, max_positions=10000, endpoint=False): + super().__init__() + self.num_channels = num_channels + self.max_positions = max_positions + self.endpoint = endpoint + + def forward(self, x): + freqs = torch.arange(start=0, end=self.num_channels//2, dtype=torch.float32, device=x.device) + freqs = freqs / (self.num_channels // 2 - (1 if self.endpoint else 0)) + freqs = (1 / self.max_positions) ** freqs + x = x.ger(freqs.to(x.dtype)) + x = torch.cat([x.cos(), x.sin()], dim=1) + return x + + +class MLP(nn.Module): + def __init__(self, d_in, dim_t = 512, use_mlp=True): + super().__init__() + self.dim_t = dim_t + + self.proj = nn.Linear(d_in, dim_t) + + self.mlp = nn.Sequential( + nn.Linear(dim_t, dim_t * 2), + nn.SiLU(), + nn.Linear(dim_t * 2, dim_t * 2), + nn.SiLU(), + nn.Linear(dim_t * 2, dim_t), + nn.SiLU(), + nn.Linear(dim_t, d_in), + ) if use_mlp else nn.Linear(dim_t, d_in) + + self.map_noise = PositionalEmbedding(num_channels=dim_t) + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + self.use_mlp = use_mlp + + def forward(self, x, timesteps): + emb = self.map_noise(timesteps) + emb = emb.reshape(emb.shape[0], 2, -1).flip(1).reshape(*emb.shape) # swap sin/cos + emb = self.time_embed(emb) + + x = self.proj(x) + emb + return self.mlp(x) + + +class UniModMLP(nn.Module): + """ + Input: + x_num: [bs, d_numerical] + x_cat: [bs, len(categories)] + Output: + x_num_pred: [bs, d_numerical], the predicted mean for numerical data + x_cat_pred: [bs, sum(categories)], the predicted UNORMALIZED logits for categorical data + """ + def __init__( + self, d_numerical, categories, num_layers, d_token, + n_head = 1, factor = 4, bias = True, dim_t=512, use_mlp=True, + activation='gelu', **kwargs + ): + super().__init__() + self.d_numerical = d_numerical + self.categories = categories + + self.tokenizer = Tokenizer(d_numerical, categories, d_token, bias = bias) + self.encoder = Transformer(num_layers, d_token, n_head, d_token, factor, activation=activation) + d_in = d_token * (d_numerical + len(categories)) + self.mlp = MLP(d_in, dim_t=dim_t, use_mlp=use_mlp) + self.decoder = Transformer(num_layers, d_token, n_head, d_token, factor, activation=activation) + self.detokenizer = Reconstructor(d_numerical, categories, d_token) + + self.model = nn.ModuleList([self.tokenizer, self.encoder, self.mlp, self.decoder, self.detokenizer]) + + def forward(self, x_num, x_cat, timesteps): + e = self.tokenizer(x_num, x_cat) + decoder_input = e[:, 1:, :] # ignore the first CLS token. + y = self.encoder(decoder_input) + pred_y = self.mlp(y.reshape(y.shape[0], -1), timesteps) + pred_e = self.decoder(pred_y.reshape(*y.shape)) + x_num_pred, x_cat_pred = self.detokenizer(pred_e) + x_cat_pred = torch.cat(x_cat_pred, dim=-1) if len(x_cat_pred)>0 else torch.zeros_like(x_cat).to(x_num_pred.dtype) + + return x_num_pred, x_cat_pred diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/transformer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..98334864ad8befdc6e23fe5f64d5e50bf5907cee --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/modules/transformer.py @@ -0,0 +1,269 @@ +import torch +import torch.nn as nn +import torch.nn.init as nn_init +import torch.nn.functional as F +from torch import Tensor + +import math + +class Tokenizer(nn.Module): + + def __init__(self, d_numerical, categories, d_token, bias): + super().__init__() + if categories is None: + d_bias = d_numerical + self.category_offsets = None + self.category_embeddings = None + self.n_categories = 0 + else: + d_bias = d_numerical + len(categories) + category_offsets = torch.tensor([0] + list(categories[:-1])).cumsum(0) + category_ends = torch.tensor(list(categories)).cumsum(0) + self.register_buffer('category_offsets', category_offsets) + self.register_buffer('category_ends', category_ends) + self.cat_weight = nn.Parameter(Tensor(sum(categories), d_token)) + nn.init.kaiming_uniform_(self.cat_weight, a=math.sqrt(5)) + self.n_categories = len(categories) + + # take [CLS] token into account + self.weight = nn.Parameter(Tensor(d_numerical + 1, d_token)) + self.bias = nn.Parameter(Tensor(d_bias, d_token)) if bias else None + # The initialization is inspired by nn.Linear + nn_init.kaiming_uniform_(self.weight, a=math.sqrt(5)) + if self.bias is not None: + nn_init.kaiming_uniform_(self.bias, a=math.sqrt(5)) + + @property + def n_tokens(self): + return len(self.weight) + ( + 0 if self.category_offsets is None else len(self.category_offsets) + ) + + def forward(self, x_num, x_cat): + x_some = x_num if x_cat is None else x_cat + assert x_some is not None + x_num = torch.cat( + [torch.ones(len(x_some), 1, device=x_some.device)] # [CLS] + + ([] if x_num is None else [x_num]), + dim=1, + ) + + x = self.weight[None] * x_num[:, :, None] + + if x_cat is not None and self.n_categories > 0: + # Vectorized categorical token computation: one matmul per category + cat_tokens = [] + for start, end in zip(self.category_offsets, self.category_ends): + # x_cat[:, start:end] @ cat_weight[start:end] -> [batch, d_token] + cat_tokens.append( + (x_cat[:, start:end] @ self.cat_weight[start:end]).unsqueeze(1) + ) + x = torch.cat([x] + cat_tokens, dim=1) + + if self.bias is not None: + bias = torch.cat( + [ + torch.zeros(1, self.bias.shape[1], device=x.device), + self.bias, + ] + ) + x = x + bias[None] + + return x + + +class MultiheadAttention(nn.Module): + def __init__(self, d, n_heads, dropout, initialization = 'kaiming'): + + if n_heads > 1: + assert d % n_heads == 0 + assert initialization in ['xavier', 'kaiming'] + + super().__init__() + self.W_q = nn.Linear(d, d) + self.W_k = nn.Linear(d, d) + self.W_v = nn.Linear(d, d) + self.W_out = nn.Linear(d, d) if n_heads > 1 else None + self.n_heads = n_heads + self.dropout = nn.Dropout(dropout) if dropout else None + + for m in [self.W_q, self.W_k, self.W_v]: + if initialization == 'xavier' and (n_heads > 1 or m is not self.W_v): + # gain is needed since W_qkv is represented with 3 separate layers + nn_init.xavier_uniform_(m.weight, gain=1 / math.sqrt(2)) + nn_init.zeros_(m.bias) + if self.W_out is not None: + nn_init.zeros_(self.W_out.bias) + + def _reshape(self, x): + batch_size, n_tokens, d = x.shape + d_head = d // self.n_heads + return ( + x.reshape(batch_size, n_tokens, self.n_heads, d_head) + .transpose(1, 2) + .reshape(batch_size * self.n_heads, n_tokens, d_head) + ) + + def forward(self, x_q, x_kv, key_compression = None, value_compression = None): + + q, k, v = self.W_q(x_q), self.W_k(x_kv), self.W_v(x_kv) + for tensor in [q, k, v]: + assert tensor.shape[-1] % self.n_heads == 0 + if key_compression is not None: + assert value_compression is not None + k = key_compression(k.transpose(1, 2)).transpose(1, 2) + v = value_compression(v.transpose(1, 2)).transpose(1, 2) + else: + assert value_compression is None + + batch_size = len(q) + d_head_key = k.shape[-1] // self.n_heads + d_head_value = v.shape[-1] // self.n_heads + n_q_tokens = q.shape[1] + + q = self._reshape(q) + k = self._reshape(k) + + a = q @ k.transpose(1, 2) + b = math.sqrt(d_head_key) + attention = F.softmax(a/b , dim=-1) + + + if self.dropout is not None: + attention = self.dropout(attention) + x = attention @ self._reshape(v) + x = ( + x.reshape(batch_size, self.n_heads, n_q_tokens, d_head_value) + .transpose(1, 2) + .reshape(batch_size, n_q_tokens, self.n_heads * d_head_value) + ) + if self.W_out is not None: + x = self.W_out(x) + + return x + +class Transformer(nn.Module): + + def __init__( + self, + n_layers: int, + d_token: int, + n_heads: int, + d_out: int, + d_ffn_factor: int, + attention_dropout = 0.0, + ffn_dropout = 0.0, + residual_dropout = 0.0, + activation = 'relu', + prenormalization = True, + initialization = 'kaiming', + ): + super().__init__() + + def make_normalization(): + return nn.LayerNorm(d_token) + + d_hidden = int(d_token * d_ffn_factor) + self.layers = nn.ModuleList([]) + for layer_idx in range(n_layers): + layer = nn.ModuleDict( + { + 'attention': MultiheadAttention( + d_token, n_heads, attention_dropout, initialization + ), + 'linear0': nn.Linear( + d_token, d_hidden + ), + 'linear1': nn.Linear(d_hidden, d_token), + 'norm1': make_normalization(), + } + ) + if not prenormalization or layer_idx: + layer['norm0'] = make_normalization() + + self.layers.append(layer) + + _activations = { + 'relu': nn.ReLU, + 'gelu': nn.GELU, + 'silu': nn.SiLU, + } + if activation not in _activations: + raise ValueError(f"Unknown activation '{activation}'. Choose from: {list(_activations)}") + self.activation = _activations[activation]() + self.last_activation = _activations[activation]() + self.prenormalization = prenormalization + self.last_normalization = make_normalization() if prenormalization else None + self.ffn_dropout = ffn_dropout + self.residual_dropout = residual_dropout + self.head = nn.Linear(d_token, d_out) + + + def _start_residual(self, x, layer, norm_idx): + x_residual = x + if self.prenormalization: + norm_key = f'norm{norm_idx}' + if norm_key in layer: + x_residual = layer[norm_key](x_residual) + return x_residual + + def _end_residual(self, x, x_residual, layer, norm_idx): + if self.residual_dropout: + x_residual = F.dropout(x_residual, self.residual_dropout, self.training) + x = x + x_residual + if not self.prenormalization: + x = layer[f'norm{norm_idx}'](x) + return x + + def forward(self, x): + for layer_idx, layer in enumerate(self.layers): + is_last_layer = layer_idx + 1 == len(self.layers) + + x_residual = self._start_residual(x, layer, 0) + x_residual = layer['attention']( + # for the last attention, it is enough to process only [CLS] + x_residual, + x_residual, + ) + + x = self._end_residual(x, x_residual, layer, 0) + + x_residual = self._start_residual(x, layer, 1) + x_residual = layer['linear0'](x_residual) + x_residual = self.activation(x_residual) + if self.ffn_dropout: + x_residual = F.dropout(x_residual, self.ffn_dropout, self.training) + x_residual = layer['linear1'](x_residual) + x = self._end_residual(x, x_residual, layer, 1) + return x + + +class Reconstructor(nn.Module): + def __init__(self, d_numerical, categories, d_token): + super(Reconstructor, self).__init__() + + self.d_numerical = d_numerical + self.categories = categories + self.d_token = d_token + + self.weight = nn.Parameter(Tensor(d_numerical, d_token)) + nn.init.xavier_uniform_(self.weight, gain=1 / math.sqrt(2)) + self.cat_recons = nn.ModuleList() + + for d in categories: + recon = nn.Linear(d_token, d) + nn.init.xavier_uniform_(recon.weight, gain=1 / math.sqrt(2)) + self.cat_recons.append(recon) + + def forward(self, h): + h_num = h[:, :self.d_numerical] + h_cat = h[:, self.d_numerical:] + + recon_x_num = torch.mul(h_num, self.weight.unsqueeze(0)).sum(-1) + recon_x_cat = [] + + for i, recon in enumerate(self.cat_recons): + + recon_x_cat.append(recon(h_cat[:, i])) + + return recon_x_num, recon_x_cat diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/trainer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/trainer.py new file mode 100644 index 0000000000000000000000000000000000000000..eef113e930d00d7b80310b03b072384548fd31b0 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/ef_vfm/trainer.py @@ -0,0 +1,557 @@ +import os +import glob +import time +import torch +from torch.optim.lr_scheduler import ReduceLROnPlateau +import numpy as np +import pandas as pd +import json + +from copy import deepcopy + +from utils_train import update_ema + +from tqdm import tqdm + +BAR = "==============" +def print_with_bar(log_msg): + log_msg = BAR + log_msg + BAR + if "End" in log_msg: + log_msg += "\n" + print(log_msg) + +class Trainer: + def __init__( + self, flow, train_iter, dataset, test_dataset, metrics, logger, + lr, weight_decay, + steps, batch_size, check_val_every, + sample_batch_size, model_save_path, result_save_path, + num_samples_to_generate=None, + lr_scheduler='reduce_lr_on_plateau', + reduce_lr_patience=100, factor=0.9, + ema_decay=0.997, + closs_weight_schedule = "fixed", + c_lambda = 1.0, + d_lambda = 1.0, + max_grad_norm = 1.0, + warmup_epochs = 0, + device=torch.device('cuda:1'), + ckpt_path = None, + **kwargs + ): + self.flow = flow + self.ema_model = deepcopy(self.flow._vf_fn) + for param in self.ema_model.parameters(): + param.detach_() + + self.train_iter = train_iter + self.dataset = dataset + self.test_dataset = test_dataset + self.steps = steps + self.init_lr = lr + self.optimizer = torch.optim.AdamW(self.flow.parameters(), lr=lr, weight_decay=weight_decay) + self.ema_decay = ema_decay + self.lr_scheduler = lr_scheduler + self.scheduler = ReduceLROnPlateau(self.optimizer, mode='min', factor=factor, patience=reduce_lr_patience) + self.closs_weight_schedule = closs_weight_schedule + self.c_lambda = c_lambda + self.d_lambda = d_lambda + self.max_grad_norm = max_grad_norm + self.warmup_epochs = warmup_epochs + + self.batch_size = batch_size + self.sample_batch_size = sample_batch_size + self.num_samples_to_generate = num_samples_to_generate + self.metrics = metrics + self.logger = logger + self.check_val_every = check_val_every + + self.device = device + self.model_save_path = model_save_path + self.result_save_path = result_save_path + self.ckpt_path = ckpt_path + if self.ckpt_path is not None: + state_dicts = torch.load(self.ckpt_path, map_location=self.device) + self.flow._vf_fn.load_state_dict(state_dicts['vf_fn']) + print(f"Weights are loaded from {self.ckpt_path}") + + self.curr_epoch = int(os.path.basename(self.ckpt_path).split('_')[-1].split('.')[0]) if self.ckpt_path is not None else 0 + + def _anneal_lr(self, step): + frac_done = step / self.steps + lr = self.init_lr * (1 - frac_done) + for param_group in self.optimizer.param_groups: + param_group["lr"] = lr + + def _run_step(self, x, closs_weight, dloss_weight): + x = x.to(self.device) + + self.flow.train() + + self.optimizer.zero_grad() + + dloss, closs = self.flow.mixed_loss(x) + + loss = dloss_weight * dloss + closs_weight * closs + loss.backward() + if self.max_grad_norm > 0: + torch.nn.utils.clip_grad_norm_(self.flow.parameters(), self.max_grad_norm) + self.optimizer.step() + + return dloss, closs + + def compute_loss(self): # eval loss is not weighted + curr_dloss = 0.0 + curr_closs = 0.0 + curr_count = 0 + data_iter = self.train_iter + for batch in data_iter: + x = batch.float().to(self.device) + self.flow.eval() + with torch.no_grad(): + batch_dloss, batch_closs = self.flow.mixed_loss(x) + curr_dloss += batch_dloss.item() * len(x) + curr_closs += batch_closs.item() * len(x) + curr_count += len(x) + mloss = np.around(curr_dloss / curr_count, 4) + gloss = np.around(curr_closs / curr_count, 4) + return mloss, gloss + + def run_loop(self): + patience = 0 + closs_weight, dloss_weight = self.c_lambda, self.d_lambda + best_loss = np.inf + best_ema_loss = np.inf + best_val_loss = np.inf + start_time = time.time() + print_with_bar(f"Starting Trainin Loop, total number of epoch = {self.steps}") + # Set up wandb's step metric + self.logger.define_metric("epoch") + self.logger.define_metric("*", step_metric="epoch") + + start_epoch = self.curr_epoch + if start_epoch > 0: + print_with_bar(f"Resuming training from epoch {start_epoch}, with validation check every {self.check_val_every} epoches") + for epoch in range (start_epoch, self.steps): + self.curr_epoch = epoch+1 + # Set up pbar + pbar = tqdm(self.train_iter, total=len(self.train_iter)) + pbar.set_description(f"Epoch {epoch+1}/{self.steps}") + + # Compute the loss weights + if self.closs_weight_schedule == "fixed": + pass + elif self.closs_weight_schedule == "anneal": + frac_done = epoch / self.steps + closs_weight = self.c_lambda * (1 - frac_done) + else: + raise NotImplementedError(f"The continuous loss weight schedule {self.closs_weight_schedule} is not implemneted") + + # Training Step + curr_dloss = 0.0 + curr_closs = 0.0 + curr_count = 0 + curr_lr = self.optimizer.param_groups[0]['lr'] + for batch in pbar: + x = batch.float().to(self.device) + batch_dloss, batch_closs = self._run_step(x, closs_weight, dloss_weight) + curr_dloss += batch_dloss.item() * len(x) + curr_closs += batch_closs.item() * len(x) + curr_count += len(x) + pbar.set_postfix({ + "lr": curr_lr, + "DLoss": np.around(curr_dloss/curr_count, 4), + "CLoss": np.around(curr_closs/curr_count, 4), + "TotalLoss": np.around((curr_dloss + curr_closs)/curr_count, 4), + "closs_weight": closs_weight, + "dloss_weight": dloss_weight, + }) + + # Log training Loss + log_dict = {} + mloss = np.around(curr_dloss / curr_count, 4) + gloss = np.around(curr_closs / curr_count, 4) + total_loss = mloss + gloss + if np.isnan(gloss): + print('Finding Nan in gaussian loss') + break + loss_dict = { + "epoch": epoch + 1, + "lr": curr_lr, + "closs_weight": closs_weight, + "dloss_weight": dloss_weight, + "loss/c_loss": gloss, + "loss/d_loss": mloss, + "loss/total_loss": total_loss + } + log_dict.update(loss_dict) + + # Adjust learning rate (warmup overrides during early epochs) + if self.warmup_epochs > 0 and (epoch + 1) <= self.warmup_epochs: + warmup_lr = self.init_lr * (epoch + 1) / self.warmup_epochs + for param_group in self.optimizer.param_groups: + param_group["lr"] = warmup_lr + elif self.lr_scheduler == 'reduce_lr_on_plateau': + self.scheduler.step(total_loss) + elif self.lr_scheduler == 'anneal': + self._anneal_lr(epoch) + elif self.lr_scheduler == 'fixed': + pass + else: + raise NotImplementedError(f"LR scheduler with name '{self.lr_scheduler}' is not implemented") + + # Update EMA models + update_ema(self.ema_model.parameters(), self.flow._vf_fn.parameters(), rate=self.ema_decay) + + # Save ckpt base on the best training loss + if total_loss < best_loss and self.curr_epoch > 4000: + best_loss = total_loss + to_remove = glob.glob(os.path.join(self.model_save_path, f"best_model_*")) + if to_remove: + os.remove(to_remove[0]) + state_dicts = { + 'vf_fn': self.flow._vf_fn.state_dict(), + } + torch.save(state_dicts, os.path.join(self.model_save_path, f'best_model_{np.round(total_loss,4)}_{epoch+1}.pt')) + patience = 0 + else: + patience += 1 # increment patience if best loss is not surpassed + + # Compute and log EMA model loss + curr_model = self.to_ema_model() + ema_mloss, ema_gloss = self.compute_loss() + self.to_model(curr_model) + ema_total_loss = ema_mloss + ema_gloss + ema_loss_dict = { + "ema_loss/c_loss": ema_gloss, + "ema_loss/d_loss": ema_mloss, + "ema_loss/total_loss": ema_total_loss + } + + # Save the best ema ckpt + if ema_total_loss < best_ema_loss and self.curr_epoch > 4000: + best_ema_loss = ema_total_loss + to_remove = glob.glob(os.path.join(self.model_save_path, f"best_ema_model_*")) + if to_remove: + os.remove(to_remove[0]) + state_dicts = { + 'vf_fn': self.ema_model.state_dict(), + } + torch.save(state_dicts, os.path.join(self.model_save_path, f'best_ema_model_{np.round(ema_total_loss,4)}_{epoch+1}.pt')) + + # Evaluate Sample Quality + if (epoch+1) % self.check_val_every == 0: + state_dicts = { + 'vf_fn': self.flow._vf_fn.state_dict(), + } + torch.save(state_dicts, os.path.join(self.model_save_path, f'model_{epoch+1}.pt')) + + print_with_bar(f"Routine Generation Evaluation every {self.check_val_every}, currently at epoch #{epoch+1}, wiht total_loss={total_loss}.") + _plot_density = os.environ.get("EFVFM_ADAPTER_TRAIN", "").strip().lower() not in ("1", "true", "yes") + out_metrics, _, _ = self.evaluate_generation(save_metric_details=True, plot_density=_plot_density) + log_dict.update(out_metrics) + print(f"Eval Resutls of the Non-EMA model:\n {out_metrics}") + + # Evaluate the EMA model + torch.save(self.ema_model.state_dict(), os.path.join(self.model_save_path, f'ema_model_{epoch+1}.pt')) + ema_out_metrics, _, _ = self.evaluate_generation(ema=True, save_metric_details=True, plot_density=_plot_density) + log_dict.update({ + "ema": ema_out_metrics, + }) + print(f"Eval Resutls of the EMA model:\n {ema_out_metrics}") + # Submit logs + self.logger.log(log_dict) + + end_time = time.time() + print_with_bar(f"Ending Trainnig Loop, totoal training time = {end_time - start_time}") + self.logger.log({ + 'training_time': end_time - start_time + }) + + def report_test(self, num_runs): + save_dir = self.result_save_path + + shape_ = [] + trend_ = [] + mle_ = [] + c2st_ = [] + for i in range(num_runs): + print_with_bar(f"GENERAL Evaluation Run {i}") + out_metrics, extras, syn_df = self.evaluate_generation() + print(f"Results of Run {i} are: \n{out_metrics}") + shape_.append(out_metrics["density/Shape"]) + trend_.append(out_metrics["density/Trend"]) + mle_.append(out_metrics["mle"]) + c2st_.append(out_metrics["c2st"]) + # Save samples for quality evaluation + save_path = os.path.join(save_dir, "all_samples") + if not os.path.exists(save_path): + os.makedirs(save_path) + syn_df.to_csv(os.path.join(save_path, f"samples_{i}.csv"), index=False) + + shape_ = np.array(shape_) + trend_ = np.array(trend_) + mle_ = np.array(mle_) + c2st_ = np.array(c2st_) + + shape_error = (1 - shape_)*100 + trend_error = (1 - trend_)*100 + c2st_percent = c2st_ * 100 + + all_results = pd.DataFrame({ + "shape": shape_error, + "trend": trend_error, + "mle": mle_, + "c2st": c2st_percent, + }) + avg = all_results.mean(axis=0).round(3) + std = all_results.std(axis=0).round(3) + avg_std = pd.concat([avg, std], axis=1, ignore_index=True) + avg_std.columns = ["avg", "std"] + avg_std.index = [ + "shape", + "trend", + "mle", + "c2st", + ] + + # Savings + all_results.to_csv(f"{save_dir}/all_results.csv", index=True) + avg_std.to_csv(f"{save_dir}/avg_std.csv", index=True) + print_with_bar(f"The AVG over {num_runs} runs are: \n{avg_std}") + + def report_test_dcr(self, num_runs): + save_dir = self.result_save_path + + dcr_ = [] + dcr_real_ = [] + dcr_test_ = [] + for i in range(num_runs): + print_with_bar(f"DCR Evaluation Run {i}") + out_metrics, extras, syn_df = self.evaluate_generation() + print(f"Results of Run {i} are: \n{out_metrics}") + dcr_.append(out_metrics["dcr"]) + dcr_real_.append(extras["dcr_real"]) + dcr_test_.append(extras["dcr_test"]) + save_path = os.path.join(save_dir, "all_samples") + if not os.path.exists(save_path): + os.makedirs(save_path) + syn_df.to_csv(os.path.join(save_path, f"samples_{i}.csv"), index=False) + + dcr_ = np.array(dcr_) + + dcr_percent = dcr_ * 100 + + all_results = pd.DataFrame({ + "dcr": dcr_percent, + }) + avg = all_results.mean(axis=0).round(3) + std = all_results.std(axis=0).round(3) + avg_std = pd.concat([avg, std], axis=1, ignore_index=True) + avg_std.columns = ["avg", "std"] + avg_std.index = [ + "dcr", + ] + + # Savings + all_results.to_csv(f"{save_dir}/all_results.csv", index=True) + avg_std.to_csv(f"{save_dir}/avg_std.csv", index=True) + dcr_real = np.concatenate(dcr_real_, axis=0) + dcr_test = np.concatenate(dcr_test_, axis=0) + dcr_df = pd.DataFrame({ + "dcr_real": dcr_real, + "dcr_test": dcr_test + }) + dcr_df.to_csv(f"{save_dir}/dcr.csv", index=False) + + print_with_bar(f"The AVG over {num_runs} runs are: \n{avg_std}") + + def test(self): + _plot_density = os.environ.get("EFVFM_ADAPTER_TRAIN", "").strip().lower() not in ("1", "true", "yes") + out_metrics, _, _ = self.evaluate_generation(save_metric_details=True, plot_density=_plot_density) + print_with_bar(f"Results of the test are: \n{out_metrics}") + self.logger.log(out_metrics) + print(out_metrics) + + def evaluate_generation(self, save_metric_details=False, plot_density=False, ema=False): + self.flow.eval() + + # Sample a synthetic table + env_num_samples = os.environ.get("EFVFM_EVAL_NUM_SAMPLES", "").strip() + if self.num_samples_to_generate: + num_samples = self.num_samples_to_generate + elif env_num_samples: + num_samples = max(1, int(env_num_samples)) + else: + num_samples = self.metrics.real_data_size # By default, num_samples_to_generate is not specified. In this case, we generate the same number of samples as the real dataset. This approach is consistently used across all experiments in the paper. + syn_df = self.sample_synthetic(num_samples, ema=ema) + + # Save the sample + save_path = os.path.join(self.result_save_path, str(self.curr_epoch), "ema" if ema else "") + if not os.path.exists(save_path): + os.makedirs(save_path) + path = os.path.join(save_path, "samples.csv") + syn_df.to_csv(path, index=False) + print( + f"Samples are saved at {path}" + ) + + if os.environ.get("EFVFM_ADAPTER_SAMPLE_ONLY", "").strip().lower() in ("1", "true", "yes"): + return {}, {}, syn_df + + # Compute evaluation metrics on the sample + syn_df_loaded = pd.read_csv(os.path.join(save_path, "samples.csv")) # In the original tabsyn code, syn_data is implicitly casted into float.64 when it gets loaded with pd.read_csv in the evaluation script. If we don't cast, the density evluation for some columns (especially those with tailed and peaked distribution) will collapse. + out_metrics, extras = self.metrics.evaluate(syn_df_loaded) + + # Save metrics and metric details + path = os.path.join(save_path, "all_results.json") + with open(path, "w") as json_file: + json.dump(out_metrics, json_file, indent=4, separators=(", ", ": ")) # always locally save the output metrics + if save_metric_details: + for name, extra in extras.items(): + if isinstance(extra, pd.DataFrame): + extra.to_csv(os.path.join(save_path, f"{name}.csv")) + elif isinstance(extra, dict): + with open(os.path.join(save_path, f"{name}.json"), "w") as json_file: + json.dump(extra, json_file, indent=4, separators=(", ", ": ")) + else: + raise NotImplementedError(f"Extra file generated during evaluations has type {type(extra)}, and code to save this type of file is not implemented") + + # Plot density figures + if plot_density: + img = self.metrics.plot_density(syn_df_loaded) + path = os.path.join(save_path, "density_plots.png") + img.save(path) + print( + f"The density plots are saved at {path}" + ) + return out_metrics, extras, syn_df + + def sample_synthetic(self, num_samples, keep_nan_samples=True, ema=False): + if ema: + curr_model = self.to_ema_model() + + info = self.metrics.info + + print_with_bar(f"Starting Sampling, total samples to generate = {num_samples}") + start_time = time.time() + + syn_data = self.flow.sample_all(num_samples, self.sample_batch_size, keep_nan_samples=keep_nan_samples) + print(f"Shape of the generated sample = {syn_data.shape}") + + if keep_nan_samples: + num_all_zero_row = (syn_data.sum(dim=1) == 0).sum() + if num_all_zero_row: + print(f"The generated samples contain {num_all_zero_row} Nan instances!!!") + self.logger.log({ + 'num_Nan_sample': num_all_zero_row + }) + + # Recover tables + num_inverse = self.dataset.num_inverse + int_inverse = self.dataset.int_inverse + cat_inverse = self.dataset.cat_inverse + + syn_num, syn_cat, syn_target = split_num_cat_target(syn_data, info, num_inverse, int_inverse, cat_inverse) + syn_df = recover_data(syn_num, syn_cat, syn_target, info) + + idx_name_mapping = info['idx_name_mapping'] + idx_name_mapping = {int(key): value for key, value in idx_name_mapping.items()} + + syn_df.rename(columns = idx_name_mapping, inplace=True) + + end_time = time.time() + print_with_bar(f"Ending Sampling, totoal sampling time = {end_time - start_time}") + + if ema: + self.to_model(curr_model) + + return syn_df + + def to_ema_model(self): + curr_model = self.flow._vf_fn + self.flow._vf_fn = self.ema_model # temporarily install the ema parameters into the model + + return curr_model + + def to_model(self, curr_model): + self.flow._vf_fn = curr_model # give back the parameters + + +def _as_numpy_float32(x): + if x is None: + return np.array([], dtype=np.float32) + if isinstance(x, torch.Tensor): + x = x.detach().cpu().numpy() + return np.asarray(x, dtype=np.float32) + + +@torch.no_grad() +def split_num_cat_target(syn_data, info, num_inverse, int_inverse, cat_inverse): + task_type = info['task_type'] + + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + n_num_feat = len(num_col_idx) + n_cat_feat = len(cat_col_idx) + + if task_type == 'regression': + n_num_feat += len(target_col_idx) + else: + n_cat_feat += len(target_col_idx) + + syn_num = syn_data[:, :n_num_feat] + syn_cat = syn_data[:, n_num_feat:] + + if n_num_feat > 0: + syn_num = _as_numpy_float32(num_inverse(syn_num)) + syn_num = _as_numpy_float32(int_inverse(syn_num)) + else: + syn_num = np.zeros((syn_data.shape[0], 0), dtype=np.float32) + syn_cat = cat_inverse(syn_cat) + + + if info['task_type'] == 'regression': + syn_target = syn_num[:, :len(target_col_idx)] + syn_num = syn_num[:, len(target_col_idx):] + + else: + syn_target = syn_cat[:, :len(target_col_idx)] + syn_cat = syn_cat[:, len(target_col_idx):] + + return syn_num, syn_cat, syn_target + +def recover_data(syn_num, syn_cat, syn_target, info): + + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + + idx_mapping = info['idx_mapping'] + idx_mapping = {int(key): value for key, value in idx_mapping.items()} + + syn_df = pd.DataFrame() + + if info['task_type'] == 'regression': + for i in range(len(num_col_idx) + len(cat_col_idx) + len(target_col_idx)): + if i in set(num_col_idx): + syn_df[i] = syn_num[:, idx_mapping[i]] + elif i in set(cat_col_idx): + syn_df[i] = syn_cat[:, idx_mapping[i] - len(num_col_idx)] + else: + syn_df[i] = syn_target[:, idx_mapping[i] - len(num_col_idx) - len(cat_col_idx)] + + + else: + for i in range(len(num_col_idx) + len(cat_col_idx) + len(target_col_idx)): + if i in set(num_col_idx): + syn_df[i] = syn_num[:, idx_mapping[i]] + elif i in set(cat_col_idx): + syn_df[i] = syn_cat[:, idx_mapping[i] - len(num_col_idx)] + else: + syn_df[i] = syn_target[:, idx_mapping[i] - len(num_col_idx) - len(cat_col_idx)] + + return syn_df \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/eval_quality.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/eval_quality.py new file mode 100644 index 0000000000000000000000000000000000000000..c7f4f9409e5a207087ab59104d2f970a17341ba5 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/eval_quality.py @@ -0,0 +1,149 @@ +import glob +import numpy as np +import pandas as pd +import os +import sys +import json + +sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) +from sklearn.preprocessing import OneHotEncoder +from synthcity.metrics import eval_statistical +from synthcity.plugins.core.dataloader import GenericDataLoader + +pd.options.mode.chained_assignment = None + +import argparse + +parser = argparse.ArgumentParser() +parser.add_argument('--dataname', type=str) +parser.add_argument('--exp_name', type=str, default=None) + + +args = parser.parse_args() + +def evaluate_quality(real_path, syn_path, info_path): + with open(info_path, 'r') as f: + info = json.load(f) + + syn_data = pd.read_csv(syn_path) + real_data = pd.read_csv(real_path) + + + ''' Special treatment for default dataset and CoDi model ''' + + real_data.columns = range(len(real_data.columns)) + syn_data.columns = range(len(syn_data.columns)) + + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + if info['task_type'] == 'regression': + num_col_idx += target_col_idx + else: + cat_col_idx += target_col_idx + + num_real_data = real_data[num_col_idx] + cat_real_data = real_data[cat_col_idx] + + num_real_data_np = num_real_data.to_numpy() + cat_real_data_np = cat_real_data.to_numpy().astype('str') + + + num_syn_data = syn_data[num_col_idx] + cat_syn_data = syn_data[cat_col_idx] + + num_syn_data_np = num_syn_data.to_numpy() + + # cat_syn_data_np = np.array + cat_syn_data_np = cat_syn_data.to_numpy().astype('str') + + encoder = OneHotEncoder() + encoder.fit(cat_real_data_np) + + + cat_real_data_oh = encoder.transform(cat_real_data_np).toarray() + cat_syn_data_oh = encoder.transform(cat_syn_data_np).toarray() + + le_real_data = pd.DataFrame(np.concatenate((num_real_data_np, cat_real_data_oh), axis = 1)).astype(float) + le_real_num = pd.DataFrame(num_real_data_np).astype(float) + le_real_cat = pd.DataFrame(cat_real_data_oh).astype(float) + + + le_syn_data = pd.DataFrame(np.concatenate((num_syn_data_np, cat_syn_data_oh), axis = 1)).astype(float) + le_syn_num = pd.DataFrame(num_syn_data_np).astype(float) + le_syn_cat = pd.DataFrame(cat_syn_data_oh).astype(float) + + # Check for nan + if le_syn_data.isnull().values.any(): + nan_coordinate = np.isnan(le_syn_data.to_numpy()).nonzero() + nan_row = np.unique(nan_coordinate[0]) + print(f"Synthetic data contains NaN at row {nan_row}: ") + print(le_syn_data.iloc[nan_row]) + return None, None + + + np.set_printoptions(precision=4) + + result = [] + + print('=========== All Features ===========') + print('Data shape: ', le_syn_data.shape) + + X_syn_loader = GenericDataLoader(le_syn_data) + X_real_loader = GenericDataLoader(le_real_data) + + quality_evaluator = eval_statistical.AlphaPrecision() + qual_res = quality_evaluator.evaluate(X_real_loader, X_syn_loader) + qual_res = { + k: v for (k, v) in qual_res.items() if "naive" in k + } # use the naive implementation of AlphaPrecision + qual_score = np.mean(list(qual_res.values())) + + print('alpha precision: {:.6f}, beta recall: {:.6f}'.format(qual_res['delta_precision_alpha_naive'], qual_res['delta_coverage_beta_naive'] )) + + Alpha_Precision_all = qual_res['delta_precision_alpha_naive'] + Beta_Recall_all = qual_res['delta_coverage_beta_naive'] + + return Alpha_Precision_all, Beta_Recall_all + +if __name__ == '__main__': + exp_name = args.exp_name + assert exp_name is not None, "Experiment name must be provided" + dataname = args.dataname + data_dir = f'data/{dataname}' + info_path = f'{data_dir}/info.json' + real_path = f'synthetic/{dataname}/real.csv' + + sample_dir = f"eval/report_runs/{exp_name}/{dataname}/all_samples" + sample_paths = glob.glob(os.path.join(sample_dir, "*.csv")) + print(f"{len(sample_paths )} samples loaded from {sample_dir}") + + alphas, betas = [], [] + for syn_path in sample_paths: + alpha_precision, beta_recall = evaluate_quality(real_path, syn_path, info_path) + if (alpha_precision is None) or (beta_recall is None): + continue + alphas.append(alpha_precision) + betas.append(beta_recall) + + alphas = np.array(alphas) + betas = np.array(betas) + alpha_percent = alphas * 100 + beta_percent = betas * 100 + + quality = pd.DataFrame({ + 'alpha': alpha_percent, + 'beta': beta_percent + }) + avg = quality.mean(axis=0).round(2) + std = quality.std(axis=0).round(2) + quality_avg_std = pd.concat([avg, std], axis=1, ignore_index=True) + quality_avg_std.columns = ["avg", "std"] + quality_avg_std.index = ["alpha", "beta"] + + save_dir = os.path.dirname(sample_dir) + quality.to_csv(os.path.join(save_dir, "quality.csv"), index=True) + avg_std = pd.read_csv(os.path.join(save_dir, "avg_std.csv"), index_col=0) + avg_std = pd.concat([avg_std, quality_avg_std]) + print(avg_std) + avg_std.to_csv(os.path.join(save_dir, "avg_std.csv"), index=True) diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/mle.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/mle.py new file mode 100644 index 0000000000000000000000000000000000000000..0cfb8766d1bf207b3abe48a1142f7ef436a6eae8 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/mle.py @@ -0,0 +1,781 @@ +import numpy as np +import pandas as pd +from xgboost import XGBClassifier, XGBRegressor +from sklearn.ensemble import AdaBoostClassifier, RandomForestClassifier, RandomForestRegressor +from sklearn.linear_model import LogisticRegression, LinearRegression +from sklearn.neural_network import MLPClassifier, MLPRegressor +from sklearn.preprocessing import OneHotEncoder, LabelEncoder +from sklearn.tree import DecisionTreeClassifier +from sklearn.metrics import classification_report, accuracy_score, f1_score, precision_score, recall_score, roc_auc_score +from sklearn.metrics import explained_variance_score, mean_squared_error, mean_absolute_error, r2_score +from sklearn.model_selection import ParameterGrid +from sklearn.utils._testing import ignore_warnings +from sklearn.exceptions import ConvergenceWarning +import logging +from prdc import compute_prdc +from tqdm import tqdm + +CATEGORICAL = "categorical" +CONTINUOUS = "continuous" + +_MODELS = { + 'binclass': [ # 184 + # { + # 'class': DecisionTreeClassifier, # 48 + # 'kwargs': { + # 'max_depth': [4, 8, 16, 32], + # 'min_samples_split': [2, 4, 8], + # 'min_samples_leaf': [1, 2, 4, 8] + # } + # }, + # { + # 'class': AdaBoostClassifier, # 4 + # 'kwargs': { + # 'n_estimators': [10, 50, 100, 200] + # } + # }, + # { + # 'class': LogisticRegression, # 36 + # 'kwargs': { + # 'solver': ['lbfgs'], + # 'n_jobs': [-1], + # 'max_iter': [10, 50, 100, 200], + # 'C': [0.01, 0.1, 1.0], + # 'tol': [1e-01, 1e-02, 1e-04] + # } + # }, + # { + # 'class': MLPClassifier, # 12 + # 'kwargs': { + # 'hidden_layer_sizes': [(100, ), (200, ), (100, 100)], + # 'max_iter': [50, 100], + # 'alpha': [0.0001, 0.001] + # } + # }, + # { + # 'class': RandomForestClassifier, # 48 + # 'kwargs': { + # 'max_depth': [8, 16, None], + # 'min_samples_split': [2, 4, 8], + # 'min_samples_leaf': [1, 2, 4, 8], + # 'n_jobs': [-1] + + # } + # }, + { + 'class': XGBClassifier, # 36 + 'kwargs': { + 'n_estimators': [10, 50, 100], + 'min_child_weight': [1, 10], + 'max_depth': [5, 10, 20], + 'gamma': [0.0, 1.0], + 'objective': ['binary:logistic'], + 'nthread': [-1], + 'tree_method': ['gpu_hist'] + }, + } + + ], + 'multiclass': [ # 132 + + # { + # 'class': MLPClassifier, # 12 + # 'kwargs': { + # 'hidden_layer_sizes': [(100, ), (200, ), (100, 100)], + # 'max_iter': [50, 100], + # 'alpha': [0.0001, 0.001] + # } + # }, + # { + # 'class': DecisionTreeClassifier, # 48 + # 'kwargs': { + # 'max_depth': [4, 8, 16, 32], + # 'min_samples_split': [2, 4, 8], + # 'min_samples_leaf': [1, 2, 4, 8] + # } + # }, + # { + # 'class': RandomForestClassifier, # 36 + # 'kwargs': { + # 'max_depth': [8, 16, None], + # 'min_samples_split': [2, 4, 8], + # 'min_samples_leaf': [1, 2, 4, 8], + # 'n_jobs': [-1] + + # } + # }, + { + 'class': XGBClassifier, # 36 + 'kwargs': { + 'n_estimators': [10, 50, 100], + 'min_child_weight': [1, 10], + 'max_depth': [5, 10, 20], + 'gamma': [0.0, 1.0], + 'objective': ['binary:logistic'], + 'nthread': [-1], + 'tree_method': ['gpu_hist'] + } + } + + ], + 'regression': [ # 84 + # { + # 'class': LinearRegression, + # }, + # { + # 'class': MLPRegressor, # 12 + # 'kwargs': { + # 'hidden_layer_sizes': [(100, ), (200, ), (100, 100)], + # 'max_iter': [50, 100], + # 'alpha': [0.0001, 0.001] + # } + #}, + { + 'class': XGBRegressor, # 36 + 'kwargs': { + 'n_estimators': [10, 50, 100], + 'min_child_weight': [1, 10], + 'max_depth': [5, 10, 20], + 'gamma': [0.0, 1.0], + 'objective': ['reg:linear'], + 'nthread': [-1], + 'tree_method': ['gpu_hist'] + } + }, + # { + # 'class': RandomForestRegressor, # 36 + # 'kwargs': { + # 'max_depth': [8, 16, None], + # 'min_samples_split': [2, 4, 8], + # 'min_samples_leaf': [1, 2, 4, 8], + # 'n_jobs': [-1] + # } + # } + ] +} + +def feat_transform(data, info, label_encoder = None, encoders = None, cmax = None, cmin = None): + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + num_cols = len(num_col_idx + cat_col_idx + target_col_idx) + features = [] + + if not encoders: + encoders = dict() + for idx in range(num_cols): + col = data[:, idx] + + if idx in target_col_idx: + + if info['task_type'] != 'regression': + + if not label_encoder: + label_encoder = LabelEncoder() + label_encoder.fit(col) + + encoded_labels = label_encoder.transform(col) + labels = encoded_labels + else: + col = col.astype(np.float32) + labels = col.astype(np.float32) + + continue + + if idx in num_col_idx: + col = col.astype(np.float32) + + if not cmin: + cmin = col.min() + + if not cmax: + cmax = col.max() + + if cmin >= 0 and cmax >= 1e3: + feature = np.log(np.maximum(col, 1e-2)) + + else: + feature = (col - cmin) / (cmax - cmin) * 5 + + elif idx in cat_col_idx: + encoder = encoders.get(idx) + col = col.reshape(-1, 1) + if encoder: + feature = encoder.transform(col) + else: + # encoder = OneHotEncoder(sparse=False, handle_unknown='ignore') + encoder = OneHotEncoder(sparse_output=False, handle_unknown='ignore') # New in version 1.2: sparse was renamed to sparse_output + encoders[idx] = encoder + feature = encoder.fit_transform(col) + + + features.append(feature) + features = np.column_stack(features) + return features, labels, label_encoder, encoders, cmax, cmin + + +def prepare_ml_problem(train, test, info, val=None): + # test_X, test_y, label_encoder, encoders = feat_transform(test, info) + # train_X, train_y, _, _ = feat_transform(train, info, label_encoder, encoders) + + train_X, train_y, label_encoder, encoders, cmax, cmin = feat_transform(train, info) + test_X, test_y, _, _ , _, _ = feat_transform(test, info, label_encoder, encoders, cmax, cmin) + + if val is not None: + val_X, val_y, _, _, _, _ = feat_transform(val, info, label_encoder, encoders, cmax, cmin) + else: + total_train_num = train_X.shape[0] + val_num = int(total_train_num / 9) + + total_train_idx = np.arange(total_train_num) + np.random.shuffle(total_train_idx) + train_idx = total_train_idx[val_num:] + val_idx = total_train_idx[:val_num] + + + + # val_X, val_y = train_X[val_idx], train_y[val_idx] + # train_X, train_y = train_X[train_idx], train_y[train_idx] + + # model = _MODELS[info['task_type']] + + # return train_X, train_y, train_X, train_y, test_X, test_y, model + + + + val_X, val_y = train_X[val_idx], train_y[val_idx] + train_X, train_y = train_X[train_idx], train_y[train_idx] + + model = _MODELS[info['task_type']] + + return train_X, train_y, val_X, val_y, test_X, test_y, model + +class FeatureMaker: + + def __init__(self, metadata, label_column='label', label_type='int', sample=50000): + self.columns = metadata['columns'] + self.label_column = label_column + self.label_type = label_type + self.sample = sample + self.encoders = dict() + + def make_features(self, data): + data = data.copy() + np.random.shuffle(data) + data = data[:self.sample] + + features = [] + labels = [] + + for index, cinfo in enumerate(self.columns): + col = data[:, index] + if cinfo['name'] == self.label_column: + if self.label_type == 'int': + labels = col.astype(int) + elif self.label_type == 'float': + labels = col.astype(float) + else: + assert 0, 'unkown label type' + continue + + if cinfo['type'] == CONTINUOUS: + cmin = cinfo['min'] + cmax = cinfo['max'] + if cmin >= 0 and cmax >= 1e3: + feature = np.log(np.maximum(col, 1e-2)) + + else: + feature = (col - cmin) / (cmax - cmin) * 5 + + else: + if cinfo['size'] <= 2: + feature = col + + else: + encoder = self.encoders.get(index) + col = col.reshape(-1, 1) + if encoder: + feature = encoder.transform(col) + else: + encoder = OneHotEncoder(sparse=False, handle_unknown='ignore') + self.encoders[index] = encoder + feature = encoder.fit_transform(col) + + features.append(feature) + + features = np.column_stack(features) + + return features, labels + + +def _prepare_ml_problem(train, val, test, metadata, eval): + fm = FeatureMaker(metadata) + x_trains, y_trains = [], [] + + for i in train: + x_train, y_train = fm.make_features(i) + x_trains.append(x_train) + y_trains.append(y_train) + + x_val, y_val = fm.make_features(val) + if eval is None: + x_test = None + y_test = None + else: + x_test, y_test = fm.make_features(test) + model = _MODELS[metadata['problem_type']] + + return x_trains, y_trains, x_val, y_val, x_test, y_test, model + + +def _weighted_f1(y_test, pred): + report = classification_report(y_test, pred, output_dict=True) + classes = list(report.keys())[:-3] + proportion = [ report[i]['support'] / len(y_test) for i in classes] + weighted_f1 = np.sum(list(map(lambda i, prop: report[i]['f1-score']* (1-prop)/(len(classes)-1), classes, proportion))) + return weighted_f1 + + +@ignore_warnings(category=ConvergenceWarning) +def _evaluate_multi_classification(train, test, info, val=None): + x_trains, y_trains, x_valid, y_valid, x_test, y_test, classifiers = prepare_ml_problem(train, test, info, val=val) + best_f1_scores = [] + unique_labels = np.unique(y_trains) + + + best_f1_scores = [] + best_weighted_scores = [] + best_auroc_scores = [] + best_acc_scores = [] + best_avg_scores = [] + + for model_spec in classifiers: + model_class = model_spec['class'] + model_kwargs = model_spec.get('kwargs', dict()) + model_repr = model_class.__name__ + + unique_labels = np.unique(y_trains) + + param_set = list(ParameterGrid(model_kwargs)) + + results = [] + for param in tqdm(param_set): + model = model_class(**param) + + try: + model.fit(x_trains, y_trains) + except: + pass + + if len(unique_labels) != len(np.unique(y_valid)): + pred = [unique_labels[0]] * len(x_valid) + pred_prob = np.array([1.] * len(x_valid)) + else: + pred = model.predict(x_valid) + pred_prob = model.predict_proba(x_valid) + + macro_f1 = f1_score(y_valid, pred, average='macro') + weighted_f1 = _weighted_f1(y_valid, pred) + acc = accuracy_score(y_valid, pred) + + # 3. auroc + # size = [a["size"] for a in metadata["columns"] if a["name"] == "label"][0] + size = len(set(unique_labels)) + rest_label = set(range(size)) - set(unique_labels) + tmp = [] + j = 0 + for i in range(size): + if i in rest_label: + tmp.append(np.array([0] * y_valid.shape[0])[:,np.newaxis]) + else: + try: + tmp.append(pred_prob[:,[j]]) + except: + tmp.append(pred_prob[:, np.newaxis]) + j += 1 + + roc_auc = roc_auc_score(np.eye(size)[y_valid], np.hstack(tmp), multi_class='ovr') + + results.append( + { + "name": model_repr, + "param": param, + "macro_f1": macro_f1, + "weighted_f1": weighted_f1, + "roc_auc": roc_auc, + "accuracy": acc + } + ) + + results = pd.DataFrame(results) + results['avg'] = results.loc[:, ['macro_f1', 'weighted_f1', 'roc_auc']].mean(axis=1) + best_f1_param = results.param[results.macro_f1.idxmax()] + best_weighted_param = results.param[results.weighted_f1.idxmax()] + best_auroc_param = results.param[results.roc_auc.idxmax()] + best_acc_param = results.param[results.accuracy.idxmax()] + best_avg_param = results.param[results.avg.idxmax()] + + + # test the best model + results = pd.DataFrame(results) + # best_param = results.param[results.macro_f1.idxmax()] + + def _calc(best_model): + best_scores = [] + + x_train = x_trains + y_train = y_trains + + try: + best_model.fit(x_train, y_train) + except: + pass + + if len(unique_labels) != len(np.unique(y_test)): + pred = [unique_labels[0]] * len(x_test) + pred_prob = np.array([1.] * len(x_test)) + else: + pred = best_model.predict(x_test) + pred_prob = best_model.predict_proba(x_test) + + macro_f1 = f1_score(y_test, pred, average='macro') + weighted_f1 = _weighted_f1(y_test, pred) + acc = accuracy_score(y_test, pred) + + # 3. auroc + size = len(set(unique_labels)) + rest_label = set(range(size)) - set(unique_labels) + tmp = [] + j = 0 + for i in range(size): + if i in rest_label: + tmp.append(np.array([0] * y_test.shape[0])[:,np.newaxis]) + else: + try: + tmp.append(pred_prob[:,[j]]) + except: + tmp.append(pred_prob[:, np.newaxis]) + j += 1 + roc_auc = roc_auc_score(np.eye(size)[y_test], np.hstack(tmp), multi_class='ovr') + + best_scores.append( + { + "name": model_repr, + "macro_f1": macro_f1, + "weighted_f1": weighted_f1, + "roc_auc": roc_auc, + "accuracy": acc + } + ) + return pd.DataFrame(best_scores) + + def _df(dataframe): + return { + "name": model_repr, + "macro_f1": dataframe.macro_f1.values[0], + "roc_auc": dataframe.roc_auc.values[0], + "weighted_f1": dataframe.weighted_f1.values[0], + "accuracy": dataframe.accuracy.values[0], + } + + best_f1_scores.append(_df(_calc(model_class(**best_f1_param)))) + best_weighted_scores.append(_df(_calc(model_class(**best_weighted_param)))) + best_auroc_scores.append(_df(_calc(model_class(**best_auroc_param)))) + best_acc_scores.append(_df(_calc(model_class(**best_acc_param)))) + best_avg_scores.append(_df(_calc(model_class(**best_avg_param)))) + + return best_f1_scores, best_weighted_scores, best_auroc_scores, best_acc_scores, best_avg_scores + +@ignore_warnings(category=ConvergenceWarning) +def _evaluate_binary_classification(train, test, info, val=None): + x_trains, y_trains, x_valid, y_valid, x_test, y_test, classifiers = prepare_ml_problem(train, test, info, val=val) + + unique_labels = np.unique(y_trains) + + best_f1_scores = [] + best_weighted_scores = [] + best_auroc_scores = [] + best_acc_scores = [] + best_avg_scores = [] + + for model_spec in classifiers: + + model_class = model_spec['class'] + model_kwargs = model_spec.get('kwargs', dict()) + model_repr = model_class.__name__ + + unique_labels = np.unique(y_trains) + + param_set = list(ParameterGrid(model_kwargs)) + + results = [] + for param in tqdm(param_set): + model = model_class(**param) + + try: + model.fit(x_trains, y_trains) + except ValueError: + pass + + if len(unique_labels) == 1: + pred = [unique_labels[0]] * len(x_valid) + pred_prob = np.array([1.] * len(x_valid)) + else: + pred = model.predict(x_valid) + pred_prob = model.predict_proba(x_valid) + + binary_f1 = f1_score(y_valid, pred, average='binary') + weighted_f1 = _weighted_f1(y_valid, pred) + acc = accuracy_score(y_valid, pred) + precision = precision_score(y_valid, pred, average='binary') + recall = recall_score(y_valid, pred, average='binary') + macro_f1 = f1_score(y_valid, pred, average='macro') + + # auroc + size = 2 + rest_label = set(range(size)) - set(unique_labels) + tmp = [] + j = 0 + for i in range(size): + if i in rest_label: + tmp.append(np.array([0] * y_valid.shape[0])[:,np.newaxis]) + else: + try: + tmp.append(pred_prob[:,[j]]) + except: + tmp.append(pred_prob[:, np.newaxis]) + j += 1 + roc_auc = roc_auc_score(np.eye(size)[y_valid], np.hstack(tmp)) + + results.append( + { + "name": model_repr, + "param": param, + "binary_f1": binary_f1, + "weighted_f1": weighted_f1, + "roc_auc": roc_auc, + "accuracy": acc, + "precision": precision, + "recall": recall, + "macro_f1": macro_f1 + } + ) + + + # test the best model + results = pd.DataFrame(results) + results['avg'] = results.loc[:, ['binary_f1', 'weighted_f1', 'roc_auc']].mean(axis=1) + best_f1_param = results.param[results.binary_f1.idxmax()] + best_weighted_param = results.param[results.weighted_f1.idxmax()] + best_auroc_param = results.param[results.roc_auc.idxmax()] + best_acc_param = results.param[results.accuracy.idxmax()] + best_avg_param = results.param[results.avg.idxmax()] + + + def _calc(best_model): + best_scores = [] + + best_model.fit(x_trains, y_trains) + + if len(unique_labels) == 1: + pred = [unique_labels[0]] * len(x_test) + pred_prob = np.array([1.] * len(x_test)) + else: + pred = best_model.predict(x_test) + pred_prob = best_model.predict_proba(x_test) + + binary_f1 = f1_score(y_test, pred, average='binary') + weighted_f1 = _weighted_f1(y_test, pred) + acc = accuracy_score(y_test, pred) + precision = precision_score(y_test, pred, average='binary') + recall = recall_score(y_test, pred, average='binary') + macro_f1 = f1_score(y_test, pred, average='macro') + + # auroc + size = 2 + rest_label = set(range(size)) - set(unique_labels) + tmp = [] + j = 0 + for i in range(size): + if i in rest_label: + tmp.append(np.array([0] * y_test.shape[0])[:,np.newaxis]) + else: + try: + tmp.append(pred_prob[:,[j]]) + except: + tmp.append(pred_prob[:, np.newaxis]) + j += 1 + try: + roc_auc = roc_auc_score(np.eye(size)[y_test], np.hstack(tmp)) + except ValueError: + tmp[1] = tmp[1].reshape(20000, 1) + roc_auc = roc_auc_score(np.eye(size)[y_test], np.hstack(tmp)) + + best_scores.append( + { + "name": model_repr, + # "param": param, + "binary_f1": binary_f1, + "weighted_f1": weighted_f1, + "roc_auc": roc_auc, + "accuracy": acc, + "precision": precision, + "recall": recall, + "macro_f1": macro_f1 + } + ) + + return pd.DataFrame(best_scores) + def _df(dataframe): + return { + "name": model_repr, + "binary_f1": dataframe.binary_f1.values[0], + "roc_auc": dataframe.roc_auc.values[0], + "weighted_f1": dataframe.weighted_f1.values[0], + "accuracy": dataframe.accuracy.values[0], + } + + best_f1_scores.append(_df(_calc(model_class(**best_f1_param)))) + best_weighted_scores.append(_df(_calc(model_class(**best_weighted_param)))) + best_auroc_scores.append(_df(_calc(model_class(**best_auroc_param)))) + best_acc_scores.append(_df(_calc(model_class(**best_acc_param)))) + best_avg_scores.append(_df(_calc(model_class(**best_avg_param)))) + + return best_f1_scores, best_weighted_scores, best_auroc_scores, best_acc_scores, best_avg_scores + +@ignore_warnings(category=ConvergenceWarning) +def _evaluate_regression(train, test, info, val=None): + + x_trains, y_trains, x_valid, y_valid, x_test, y_test, regressors = prepare_ml_problem(train, test, info, val=val) + + + best_r2_scores = [] + best_ev_scores = [] + best_mae_scores = [] + best_rmse_scores = [] + best_avg_scores = [] + + y_trains = np.log(np.clip(y_trains, 1, 20000)) + y_test = np.log(np.clip(y_test, 1, 20000)) + + for model_spec in regressors: + model_class = model_spec['class'] + model_kwargs = model_spec.get('kwargs', dict()) + model_repr = model_class.__name__ + + param_set = list(ParameterGrid(model_kwargs)) + + results = [] + for param in tqdm(param_set): + model = model_class(**param) + model.fit(x_trains, y_trains) + pred = model.predict(x_valid) + + r2 = r2_score(y_valid, pred) + explained_variance = explained_variance_score(y_valid, pred) + mean_squared = mean_squared_error(y_valid, pred) + root_mean_squared = np.sqrt(mean_squared) + mean_absolute = mean_absolute_error(y_valid, pred) + + results.append( + { + "name": model_repr, + "param": param, + "r2": r2, + "explained_variance": explained_variance, + "mean_squared": mean_squared, + "mean_absolute": mean_absolute, + "rmse": root_mean_squared + } + ) + + results = pd.DataFrame(results) + # results['avg'] = results.loc[:, ['r2', 'rmse']].mean(axis=1) + best_r2_param = results.param[results.r2.idxmax()] + best_ev_param = results.param[results.explained_variance.idxmax()] + best_mae_param = results.param[results.mean_absolute.idxmin()] + best_rmse_param = results.param[results.rmse.idxmin()] + # best_avg_param = results.param[results.avg.idxmax()] + + def _calc(best_model): + best_scores = [] + x_train, y_train = x_trains, y_trains + + best_model.fit(x_train, y_train) + pred = best_model.predict(x_test) + + r2 = r2_score(y_test, pred) + explained_variance = explained_variance_score(y_test, pred) + mean_squared = mean_squared_error(y_test, pred) + root_mean_squared = np.sqrt(mean_squared) + mean_absolute = mean_absolute_error(y_test, pred) + + best_scores.append( + { + "name": model_repr, + "param": param, + "r2": r2, + "explained_variance": explained_variance, + "mean_squared": mean_squared, + "mean_absolute": mean_absolute, + "rmse": root_mean_squared + } + ) + + return pd.DataFrame(best_scores) + + def _df(dataframe): + return { + "name": model_repr, + "r2": dataframe.r2.values[0].astype(float), + "explained_variance": dataframe.explained_variance.values[0].astype(float), + "MAE": dataframe.mean_absolute.values[0].astype(float), + "RMSE": dataframe.rmse.values[0].astype(float), + } + + best_r2_scores.append(_df(_calc(model_class(**best_r2_param)))) + best_ev_scores.append(_df(_calc(model_class(**best_ev_param)))) + best_mae_scores.append(_df(_calc(model_class(**best_mae_param)))) + best_rmse_scores.append(_df(_calc(model_class(**best_rmse_param)))) + + return best_r2_scores, best_rmse_scores + +@ignore_warnings(category=ConvergenceWarning) +def compute_diversity(train, fake): + nearest_k = 5 + if train.shape[0] >= 50000: + num = np.random.randint(0, train.shape[0], 50000) + real_features = train[num] + fake_features_lst = [i[num] for i in fake] + else: + num = train.shape[0] + real_features = train[:num] + fake_features_lst = [i[:num] for i in fake] + scores = [] + for i, data in enumerate(fake_features_lst): + fake_features = data + metrics = compute_prdc(real_features=real_features, + fake_features=fake_features, + nearest_k=nearest_k) + metrics['i'] = i + scores.append(metrics) + return pd.DataFrame(scores).mean(axis=0), pd.DataFrame(scores).std(axis=0) + +_EVALUATORS = { + 'binclass': _evaluate_binary_classification, + 'multiclass': _evaluate_multi_classification, + 'regression': _evaluate_regression +} + +def get_evaluator(problem_type): + return _EVALUATORS[problem_type] + + +def compute_scores(train, test, synthesized_data, metadata, eval): + a, b, c = _EVALUATORS[metadata['problem_type']](train=train, test=test, fake=synthesized_data, metadata=metadata, eval=eval) + if eval is None: + return a.mean(axis=0), a.std(axis=0), a[['name','param']] + else: + return a.mean(axis=0), a.std(axis=0) + diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_dataload.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_dataload.py new file mode 100644 index 0000000000000000000000000000000000000000..d5561f456cdc32ca553f00c01f1c4b868aef37cb --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_dataload.py @@ -0,0 +1,111 @@ +# coding=utf-8 +# Copyright 2020 The Google Research Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# pylint: skip-file +"""Return training and evaluation/test datasets from config files.""" +import torch +import numpy as np +import pandas as pd +from tabular_transformer import GeneralTransformer +import json +import logging +import os + +CATEGORICAL = "categorical" +CONTINUOUS = "continuous" + +LOGGER = logging.getLogger(__name__) + +DATA_PATH = os.path.join(os.path.dirname(__file__), 'tabular_datasets') + +def _load_json(path): + with open(path) as json_file: + return json.load(json_file) + + +def _load_file(filename, loader): + local_path = os.path.join(DATA_PATH, filename) + + if loader == np.load: + return loader(local_path, allow_pickle=True) + return loader(local_path) + + +def _get_columns(metadata): + categorical_columns = list() + + for column_idx, column in enumerate(metadata['columns']): + if column['type'] == CATEGORICAL: + categorical_columns.append(column_idx) + + return categorical_columns + + +def load_data(name): + data_dir = f'data/{name}' + info_path = f'{data_dir}/info.json' + + train = pd.read_csv(f'{data_dir}/train.csv').to_numpy() + test = pd.read_csv(f'{data_dir}/test.csv').to_numpy() + + with open(f'{data_dir}/info.json', 'r') as f: + info = json.load(f) + + task_type = info['task_type'] + + num_cols = info['num_col_idx'] + cat_cols = info['cat_col_idx'] + target_cols = info['target_col_idx'] + + if task_type != 'regression': + cat_cols = cat_cols + target_cols + + return train, test, (cat_cols, info) + + +def get_dataset(FLAGS, evaluation=False): + + batch_size = FLAGS.training_batch_size if not evaluation else FLAGS.eval_batch_size + + if batch_size % torch.cuda.device_count() != 0: + raise ValueError(f'Batch sizes ({batch_size} must be divided by' + f'the number of devices ({torch.cuda.device_count()})') + + + # Create dataset builders for tabular data. + train, test, cols = load_data(FLAGS.dataname) + cols_idx = list(np.arange(train.shape[1])) + dis_idx = cols[0] + con_idx = [x for x in cols_idx if x not in dis_idx] + + #split continuous and categorical + train_con = train[:,con_idx] + train_dis = train[:,dis_idx] + + #new index + cat_idx_ = list(np.arange(train_dis.shape[1]))[:len(cols[0])] + + transformer_con = GeneralTransformer() + transformer_dis = GeneralTransformer() + + transformer_con.fit(train_con, []) + transformer_dis.fit(train_dis, cat_idx_) + + train_con_data = transformer_con.transform(train_con) + train_dis_data = transformer_dis.transform(train_dis) + + + return train, train_con_data, train_dis_data, test, (transformer_con, transformer_dis, cols[1]), con_idx, dis_idx + \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_transformer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..571e86a298d4b973484c7fd488819e86b5f14d30 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/mle/tabular_transformer.py @@ -0,0 +1,110 @@ +import numpy as np +import pandas as pd + +CATEGORICAL = "categorical" +CONTINUOUS = "continuous" + +class Transformer: + + @staticmethod + def get_metadata(data, categorical_columns=tuple()): + meta = [] + + df = pd.DataFrame(data) + for index in df: + column = df[index] + + if index in categorical_columns: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": CATEGORICAL, + "size": len(mapper), + "i2s": mapper + }) + else: + meta.append({ + "name": index, + "type": CONTINUOUS, + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self, data, categorical_columns=tuple()): + raise NotImplementedError + + def transform(self, data): + raise NotImplementedError + + def inverse_transform(self, data): + raise NotImplementedError + + +class GeneralTransformer(Transformer): + + def __init__(self, act='tanh'): + self.act = act + self.meta = None + self.output_dim = None + + def fit(self, data, categorical_columns=tuple()): + self.meta = self.get_metadata(data, categorical_columns) + self.output_dim = 0 + for info in self.meta: + if info['type'] in [CONTINUOUS]: + self.output_dim += 1 + else: + self.output_dim += info['size'] + + def transform(self, data): + data_t = [] + self.output_info = [] + for id_, info in enumerate(self.meta): + col = data[:, id_] + if info['type'] == CONTINUOUS: + col = (col - (info['min'])) / (info['max'] - info['min']) + if self.act == 'tanh': + col = col * 2 - 1 + data_t.append(col.reshape([-1, 1])) + self.output_info.append((1, self.act)) + + else: + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, col)) + col_t[np.arange(len(data)), idx] = 1 + data_t.append(col_t) + self.output_info.append((info['size'], 'softmax')) + + return np.concatenate(data_t, axis=1) + + def inverse_transform(self, data): + if self.meta[1]['type'] == CONTINUOUS: + data_t = np.zeros([len(data), len(self.meta)]) + else: + dtype = np.dtype('U50') + data_t = np.empty([len(data), len(self.meta)], dtype=dtype) + + + data = data.copy() + for id_, info in enumerate(self.meta): + + if info['type'] == CONTINUOUS: + current = data[:, 0] + data = data[:, 1:] + + if self.act == 'tanh': + current = (current + 1) / 2 + + current = np.clip(current, 0, 1) + data_t[:, id_] = current * (info['max'] - info['min']) + info['min'] + + else: + current = data[:, :info['size']] + data = data[:, info['size']:] + idx = np.argmax(current, axis=1) + recovered = list(map(info['i2s'].__getitem__, idx)) + + data_t[:, id_] = recovered + return data_t diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/visualize_density.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/visualize_density.py new file mode 100644 index 0000000000000000000000000000000000000000..d7ee36fac552e916bbb238796e2fb2af1ebe5d50 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/eval/visualize_density.py @@ -0,0 +1,85 @@ +# %% +import numpy as np +import pandas as pd +import torch +import os + +import json + +# Metrics +from sdmetrics.visualization import get_column_plot + +import plotly.io as pio +from PIL import Image +from io import BytesIO + +from tqdm import tqdm +import argparse + +def main(args): + dataname = args.dataname + sample_file_name = args.sample_file_name + + syn_path = f'synthetic/{dataname}/{sample_file_name}' + real_path = f'synthetic/{dataname}/real.csv' + + syn_data = pd.read_csv(syn_path) + real_data = pd.read_csv(real_path) + + print((real_data[:2])) + + data_dir = f'data/{dataname}' + with open(f'{data_dir}/info.json', 'r') as f: + info = json.load(f) + + big_img = plot_density(syn_data, real_data, info) + + save_dir = f"eval/density_graphs/{dataname}" + if not os.path.exists(save_dir): + os.makedirs(save_dir) + save_path = os.path.join(save_dir, sample_file_name.replace('.csv', '.png')) + big_img.save(save_path) + print(f"Saved density graph to {save_path}") + +def plot_density(syn_data, real_data, info, num_per_row=3): + column_names = info['column_names'] + num_cat = len(column_names) + num_col = num_per_row + num_row = (num_cat-1)//num_col+1 + + imgs = [] + for i, col in tqdm(enumerate(column_names), total = len(column_names)): + # plot_type = 'bar' if i in info['cat_col_idx'] else 'distplot' + plot_type = 'bar' if info['metadata']['columns'][str(i)]['sdtype'] == 'categorical' else 'distplot' + if plot_type == 'distplot' and (syn_data[col][0] == syn_data[col]).all(): # to tackle a very weird bug + # If the continuous data all aggregate at a single value, get_column_plot() cannot plot a density curve for it. + # So, we perturb one entry of the cont data by a small amount + print(f"\n ALERT: the generated samples column_{i} with name '{col}' all has the same value of {syn_data[col][0]} \n") + syn_data[col][0] += 1e-5 + fig = get_column_plot( + real_data=real_data, + synthetic_data=syn_data, + column_name=col, + plot_type=plot_type + ) + + img_bytes = pio.to_image(fig, format='png') + img = Image.open(BytesIO(img_bytes)) + imgs.append(img) + + width, height = imgs[0].size + big_img = Image.new('RGB', (width * num_col, height * num_row)) + for i, img in enumerate(imgs): + coordinate = (i%num_col * width, i//num_col * height) + big_img.paste(img, coordinate) + return big_img + +if __name__ == '__main__': + parser = argparse.ArgumentParser() + + parser.add_argument('--dataname', type=str, default='adult') + parser.add_argument('--sample_file_name', type=str, default='tabsyn.csv') + + args = parser.parse_args() + + main(args) \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/main.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/main.py new file mode 100644 index 0000000000000000000000000000000000000000..30864194b14d60566efcbb2c997e95bc3351f49b --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/main.py @@ -0,0 +1,32 @@ +import torch +from ef_vfm.main import main as ef_vfm_main +import argparse + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description='Training of EF-VFM (TabbyFlow) for tabular data generation') + + # General configs + parser.add_argument('--dataname', type=str, default='adult', help='Name dataset, one of those in data/ dir') + parser.add_argument('--mode', type=str, default='train', help='train or test') + parser.add_argument('--method', type=str, default='ef_vfm', help='Currently we only release our model EF-VFM. Baselines will be released soon.') + parser.add_argument('--gpu', type=int, default=0, help='GPU index') + parser.add_argument('--debug', action='store_true', help='Enable debug mode') + parser.add_argument('--no_wandb', action='store_true', help='disable wandb') + parser.add_argument('--exp_name', type=str, default=None, help='Experiment name, used to name log directories and the wandb run name') + parser.add_argument('--deterministic', action='store_true', help='Whether to make the entire process deterministic, i.e., fix global random seeds') + + # Configs for testing ef_vfm + parser.add_argument('--num_samples_to_generate', type=int, default=None, help='Number of samples to be generated while testing') + parser.add_argument('--ckpt_path', type=str, default=None, help='Path to the model checkpoint to be tested') + parser.add_argument('--report', action='store_true', help="Report testing mode: this mode sequentially runs test runs and report the avg and std") + parser.add_argument('--num_runs', type=int, default=20, help="Number of runs to be averaged in the report testing mode") + + args = parser.parse_args() + + # check cuda + if args.gpu != -1 and torch.cuda.is_available(): + args.device = f'cuda:{args.gpu}' + else: + args.device = 'cpu' + + ef_vfm_main(args) \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/process_dataset.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/process_dataset.py new file mode 100644 index 0000000000000000000000000000000000000000..38004d944f5ebe15a1147df0bc9e0e1abdef3ed5 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/process_dataset.py @@ -0,0 +1,492 @@ +import numpy as np +import pandas as pd +import os +import sys +import json +import argparse + +from sklearn.preprocessing import OrdinalEncoder +from sklearn import model_selection + +TYPE_TRANSFORM ={ + 'float', np.float32, + 'str', str, + 'int', int +} + +INFO_PATH = 'data/Info' + +parser = argparse.ArgumentParser(description='process dataset') + +# General configs +parser.add_argument('--dataname', type=str, default=None, help='Name of dataset.') +args = parser.parse_args() + +def preprocess_beijing(): + with open(f'{INFO_PATH}/beijing.json', 'r') as f: + info = json.load(f) + + data_path = info['raw_data_path'] + + data_df = pd.read_csv(data_path) + columns = data_df.columns + + data_df = data_df[columns[1:]] + + + df_cleaned = data_df.dropna() + df_cleaned.to_csv(info['data_path'], index = False) + +def preprocess_beijing_dcr(): + with open(f'{INFO_PATH}/beijing_dcr.json', 'r') as f: + info = json.load(f) + + data_path = info['raw_data_path'] + + data_df = pd.read_csv(data_path) + columns = data_df.columns + + data_df = data_df[columns[1:]] + + df_cleaned = data_df.dropna() + df_cleaned.to_csv(info['data_path'], index = False) + +def preprocess_news(remove_cat=False): + name = 'news' if not remove_cat else 'news_nocat' + with open(f'{INFO_PATH}/{name}.json', 'r') as f: + info = json.load(f) + + data_path = info['raw_data_path'] + data_df = pd.read_csv(data_path) + data_df = data_df.drop('url', axis=1) + + columns = np.array(data_df.columns.tolist()) + + cat_columns1 = columns[list(range(12,18))] + cat_columns2 = columns[list(range(30,38))] + + if not remove_cat: + cat_col1 = data_df[cat_columns1].astype(int).to_numpy().argmax(axis = 1) + cat_col2 = data_df[cat_columns2].astype(int).to_numpy().argmax(axis = 1) + + data_df = data_df.drop(cat_columns2, axis=1) + data_df = data_df.drop(cat_columns1, axis=1) + + if not remove_cat: + data_df['data_channel'] = cat_col1 + data_df['weekday'] = cat_col2 + + data_save_path = f'data/{name}/{name}.csv' + data_df.to_csv(f'{data_save_path}', index = False) + + columns = np.array(data_df.columns.tolist()) + num_columns = columns[list(range(45))] + cat_columns = ['data_channel', 'weekday'] if not remove_cat else [] + target_columns = columns[[45]] + + info['num_col_idx'] = list(range(45)) + info['cat_col_idx'] = [46, 47] if not remove_cat else [] + info['target_col_idx'] = [45] + info['data_path'] = data_save_path + + with open(f'{INFO_PATH}/{name}.json', 'w') as file: + json.dump(info, file, indent=4) + +def preprocess_news_dcr(remove_cat=False): + name = 'news_dcr' if not remove_cat else 'news_nocat_dcr' + with open(f'{INFO_PATH}/{name}.json', 'r') as f: + info = json.load(f) + + data_path = info['raw_data_path'] + data_df = pd.read_csv(data_path) + data_df = data_df.drop('url', axis=1) + + columns = np.array(data_df.columns.tolist()) + + cat_columns1 = columns[list(range(12,18))] + cat_columns2 = columns[list(range(30,38))] + + if not remove_cat: + cat_col1 = data_df[cat_columns1].astype(int).to_numpy().argmax(axis = 1) + cat_col2 = data_df[cat_columns2].astype(int).to_numpy().argmax(axis = 1) + + data_df = data_df.drop(cat_columns2, axis=1) + data_df = data_df.drop(cat_columns1, axis=1) + + if not remove_cat: + data_df['data_channel'] = cat_col1 + data_df['weekday'] = cat_col2 + + data_save_path = f'data/{name}/{name}.csv' + data_df.to_csv(f'{data_save_path}', index = False) + + columns = np.array(data_df.columns.tolist()) + num_columns = columns[list(range(45))] + cat_columns = ['data_channel', 'weekday'] if not remove_cat else [] + target_columns = columns[[45]] + + info['num_col_idx'] = list(range(45)) + info['cat_col_idx'] = [46, 47] if not remove_cat else [] + info['target_col_idx'] = [45] + info['data_path'] = data_save_path + + with open(f'{INFO_PATH}/{name}.json', 'w') as file: + json.dump(info, file, indent=4) + + +def get_column_name_mapping(data_df, num_col_idx, cat_col_idx, target_col_idx, column_names = None): + + if not column_names: + column_names = np.array(data_df.columns.tolist()) + + idx_mapping = {} + + curr_num_idx = 0 + curr_cat_idx = len(num_col_idx) + curr_target_idx = curr_cat_idx + len(cat_col_idx) + + for idx in range(len(column_names)): + + if idx in num_col_idx: + idx_mapping[int(idx)] = curr_num_idx + curr_num_idx += 1 + elif idx in cat_col_idx: + idx_mapping[int(idx)] = curr_cat_idx + curr_cat_idx += 1 + else: + idx_mapping[int(idx)] = curr_target_idx + curr_target_idx += 1 + + inverse_idx_mapping = {} + for k, v in idx_mapping.items(): + inverse_idx_mapping[int(v)] = k + + idx_name_mapping = {} + + for i in range(len(column_names)): + idx_name_mapping[int(i)] = column_names[i] + + return idx_mapping, inverse_idx_mapping, idx_name_mapping + + +def train_val_test_split(data_df, cat_columns, num_train = 0, num_test = 0): + total_num = data_df.shape[0] + idx = np.arange(total_num) + + seed = 1234 + + while True: + np.random.seed(seed) + np.random.shuffle(idx) + + train_idx = idx[:num_train] + test_idx = idx[-num_test:] + + train_df = data_df.loc[train_idx] + test_df = data_df.loc[test_idx] + + flag = 0 + for i in cat_columns: + if len(set(train_df[i])) != len(set(data_df[i])): + flag = 1 + break + + if flag == 0: + break + else: + seed += 1 + + return train_df, test_df, seed + + +def process_data(name): + + if name == 'news': + preprocess_news() + elif name == 'news_nocat': + preprocess_news(remove_cat=True) + elif name == 'news_dcr': + preprocess_news_dcr() + elif name == 'beijing': + preprocess_beijing() + elif name == 'beijing_dcr': + preprocess_beijing_dcr() + + with open(f'{INFO_PATH}/{name}.json', 'r') as f: + info = json.load(f) + + data_path = info['data_path'] + if info['file_type'] == 'csv': + data_df = pd.read_csv(data_path, header = info['header']) + + elif info['file_type'] == 'xls': + data_df = pd.read_excel(data_path, sheet_name='Data', header=1) + data_df = data_df.drop('ID', axis=1) + + num_data = data_df.shape[0] + + column_names = info['column_names'] if info['column_names'] else data_df.columns.tolist() + + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + num_columns = [column_names[i] for i in num_col_idx] + cat_columns = [column_names[i] for i in cat_col_idx] + target_columns = [column_names[i] for i in target_col_idx] + + idx_mapping, inverse_idx_mapping, idx_name_mapping = get_column_name_mapping(data_df, num_col_idx, cat_col_idx, target_col_idx, column_names) + + has_val = bool(info['val_path']) + val_df = pd.DataFrame(columns=data_df.columns).astype(data_df.dtypes) # by default (val_path is not provided), set val_Df to be empty + if info['test_path']: + + # if testing data is given + test_path = info['test_path'] + + if "adult" in name: # BUG: currently data saved at adult's test_path cannot be directly loaded. Consider integrate the following code to a preprocesing function for adult + with open(test_path, 'r') as f: + lines = f.readlines()[1:] + test_save_path = f'data/{name}/test.data' + if not os.path.exists(test_save_path): + with open(test_save_path, 'a') as f1: + for line in lines: + save_line = line.strip('\n').strip('.') + f1.write(f'{save_line}\n') + + test_df = pd.read_csv(test_save_path, header = None) + else: + test_df = pd.read_csv(test_path, header = info['header']) + + if has_val: # currently you cannot have a val path without a test path + val_path = info['val_path'] + val_df = pd.read_csv(val_path, header = info['header']) + + train_df = data_df + + if "dcr" in name and "diabetes" not in name: # create 50/50 splits for dcr datasets; no need for this for diabetes dataset as it's done in preprocessing + complete_df = pd.concat([train_df, test_df, val_df], axis = 0, ignore_index=True) + num_data = complete_df.shape[0] + num_train = int(num_data*0.5) + num_test = num_data - num_train + complete_df.rename(columns = idx_name_mapping, inplace=True) + train_df, test_df, seed = train_val_test_split(complete_df, cat_columns, num_train, num_test) + + else: + # Train/ Test Split, 90% Training (50% for dcr eval exclusively), 10% Testing (Validation set will be selected from Training set) + if "dcr" in name: + num_train = int(num_data*0.5) + else: + num_train = int(num_data*0.9) + num_test = num_data - num_train + + train_df, test_df, seed = train_val_test_split(data_df, cat_columns, num_train, num_test) + + complete_df = pd.concat([train_df, test_df, val_df], axis = 0) + name_idx_mapping = {val: key for key, val in idx_name_mapping.items()} + int_columns = [] + int_col_idx = [] + int_col_idx_wrt_num = [] + for i, col_idx in enumerate(num_col_idx): + col = column_names[col_idx] + col_data = complete_df.iloc[:,col_idx] + is_int = (col_data%1 == 0).all() + if is_int: + int_columns.append(col) + int_col_idx.append(name_idx_mapping[col]) + int_col_idx_wrt_num.append(i) + info['int_col_idx'] = int_col_idx + info['int_columns'] = int_columns + info['int_col_idx_wrt_num'] = int_col_idx_wrt_num + + train_df.columns = range(len(train_df.columns)) + test_df.columns = range(len(test_df.columns)) + val_df.columns = range(len(val_df.columns)) + + print(name, train_df.shape, val_df.shape, test_df.shape, data_df.shape) + + col_info = {} + + for col_idx in num_col_idx: + col_info[col_idx] = {} + col_info['type'] = 'numerical' + col_info['max'] = float(train_df[col_idx].max()) + col_info['min'] = float(train_df[col_idx].min()) + + for col_idx in cat_col_idx: + col_info[col_idx] = {} + col_info['type'] = 'categorical' + col_info['categorizes'] = list(set(train_df[col_idx])) + + for col_idx in target_col_idx: + if info['task_type'] == 'regression': + col_info[col_idx] = {} + col_info['type'] = 'numerical' + col_info['max'] = float(train_df[col_idx].max()) + col_info['min'] = float(train_df[col_idx].min()) + else: + col_info[col_idx] = {} + col_info['type'] = 'categorical' + col_info['categorizes'] = list(set(train_df[col_idx])) + + info['column_info'] = col_info + + train_df.rename(columns = idx_name_mapping, inplace=True) + test_df.rename(columns = idx_name_mapping, inplace=True) + val_df.rename(columns = idx_name_mapping, inplace=True) + + for col in num_columns: + if (train_df[col] == ' ?').sum() > 0: + print(col) + import pdb; pdb.set_trace() + if (train_df[col] == '?').sum() > 0: + print(col) + import pdb; pdb.set_trace() + train_df.loc[train_df[col] == '?', col] = np.nan + for col in cat_columns: + train_df.loc[train_df[col] == '?', col] = 'nan' + for col in num_columns: + if (test_df[col] == ' ?').sum() > 0: + print(col) + import pdb; pdb.set_trace() + if (test_df[col] == '?').sum() > 0: + print(col) + import pdb; pdb.set_trace() + test_df.loc[test_df[col] == '?', col] = np.nan + for col in cat_columns: + test_df.loc[test_df[col] == '?', col] = 'nan' + for col in num_columns: + val_df.loc[val_df[col] == '?', col] = np.nan + for col in cat_columns: + val_df.loc[val_df[col] == '?', col] = 'nan' + + if train_df.isna().any().any(): + print("Training data contains nan in the numerical cols") + import pdb; pdb.set_trace() + + X_num_train = train_df[num_columns].to_numpy().astype(np.float32) + X_cat_train = train_df[cat_columns].to_numpy() + y_train = train_df[target_columns].to_numpy() + + X_num_test = test_df[num_columns].to_numpy().astype(np.float32) + X_cat_test = test_df[cat_columns].to_numpy() + y_test = test_df[target_columns].to_numpy() + + X_num_val = val_df[num_columns].to_numpy().astype(np.float32) + X_cat_val = val_df[cat_columns].to_numpy() + y_val = val_df[target_columns].to_numpy() + + save_dir = f'data/{name}' + np.save(f'{save_dir}/X_num_train.npy', X_num_train) + np.save(f'{save_dir}/X_cat_train.npy', X_cat_train) + np.save(f'{save_dir}/y_train.npy', y_train) + + np.save(f'{save_dir}/X_num_test.npy', X_num_test) + np.save(f'{save_dir}/X_cat_test.npy', X_cat_test) + np.save(f'{save_dir}/y_test.npy', y_test) + + if has_val: + np.save(f'{save_dir}/X_num_val.npy', X_num_val) + np.save(f'{save_dir}/X_cat_val.npy', X_cat_val) + np.save(f'{save_dir}/y_val.npy', y_val) + + train_df[num_columns] = train_df[num_columns].astype(np.float32) + test_df[num_columns] = test_df[num_columns].astype(np.float32) + val_df[num_columns] = val_df[num_columns].astype(np.float32) + + train_df.to_csv(f'{save_dir}/train.csv', index = False) + test_df.to_csv(f'{save_dir}/test.csv', index = False) + if has_val: + val_df.to_csv(f'{save_dir}/val.csv', index = False) + + if not os.path.exists(f'synthetic/{name}'): + os.makedirs(f'synthetic/{name}') + + train_df.to_csv(f'synthetic/{name}/real.csv', index = False) + test_df.to_csv(f'synthetic/{name}/test.csv', index = False) + + if has_val: + val_df.to_csv(f'synthetic/{name}/val.csv', index = False) + + print('Numerical', X_num_train.shape) + print('Categorical', X_cat_train.shape) + + info['column_names'] = column_names + info['train_num'] = train_df.shape[0] + info['test_num'] = test_df.shape[0] + info['val_num'] = val_df.shape[0] + + info['idx_mapping'] = idx_mapping + info['inverse_idx_mapping'] = inverse_idx_mapping + info['idx_name_mapping'] = idx_name_mapping + + metadata = {'columns': {}} + task_type = info['task_type'] + num_col_idx = info['num_col_idx'] + cat_col_idx = info['cat_col_idx'] + target_col_idx = info['target_col_idx'] + + for i in num_col_idx: + metadata['columns'][i] = {} + metadata['columns'][i]['sdtype'] = 'numerical' + metadata['columns'][i]['computer_representation'] = 'Float' + + for i in cat_col_idx: + metadata['columns'][i] = {} + metadata['columns'][i]['sdtype'] = 'categorical' + + if task_type == 'regression': + + for i in target_col_idx: + metadata['columns'][i] = {} + metadata['columns'][i]['sdtype'] = 'numerical' + metadata['columns'][i]['computer_representation'] = 'Float' + + else: + for i in target_col_idx: + metadata['columns'][i] = {} + metadata['columns'][i]['sdtype'] = 'categorical' + + info['metadata'] = metadata + + with open(f'{save_dir}/info.json', 'w') as file: + json.dump(info, file, indent=4) + + print(f'Processing and Saving {name} Successfully!') + + print(name) + print('Total', info['train_num'] + info['test_num']) + print('Train', info['train_num']) + print('Val', info['val_num']) + print('Test', info['test_num']) + if info['task_type'] == 'regression': + num = len(info['num_col_idx'] + info['target_col_idx']) + cat = len(info['cat_col_idx']) + else: + cat = len(info['cat_col_idx'] + info['target_col_idx']) + num = len(info['num_col_idx']) + print('Num', num) + print('Int', len(info['int_col_idx'])) + print('Cat', cat) + +if __name__ == "__main__": + + if args.dataname: + process_data(args.dataname) + else: + for name in [ + 'adult', + 'default', + 'shoppers', + 'magic', + 'beijing', + 'news', + 'news_nocat', + 'adult_dcr', + 'default_dcr', + 'shoppers_dcr', + 'beijing_dcr', + 'news_dcr', + ]: + process_data(name) + diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/pyproject.toml b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/pyproject.toml new file mode 100644 index 0000000000000000000000000000000000000000..57737114306b42c08aa9fb800a23b6f746693bab --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/pyproject.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc2d5c09fdbd3457c0f7cdd1a92c8e44ea3b2ff1316a2b718865fb7e8059da36 +size 1029 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/__init__.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..07d7a4057f36847f7accf4ca148d590d8b4fc80f --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/__init__.py @@ -0,0 +1,11 @@ +import torch +from icecream import install + +torch.set_num_threads(1) +install() + +from . import env # noqa +from .data import * # noqa +from .env import * # noqa +from .metrics import * # noqa +from .util import * # noqa \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/data.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/data.py new file mode 100644 index 0000000000000000000000000000000000000000..c6906ba122d1ff276b7f475b7f6e7c3440580654 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/data.py @@ -0,0 +1,780 @@ +import hashlib +from collections import Counter +from copy import deepcopy +from dataclasses import astuple, dataclass, replace +from importlib.resources import path +from pathlib import Path +from typing import Any, Literal, Optional, Union, cast, Tuple, Dict, List + +import numpy as np +import pandas as pd +from sklearn.model_selection import train_test_split +from sklearn.pipeline import make_pipeline +import sklearn.preprocessing +import torch +import os +from category_encoders import LeaveOneOutEncoder +from sklearn.impute import SimpleImputer +from sklearn.preprocessing import StandardScaler +from scipy.spatial.distance import cdist + +from . import env, util +from .metrics import calculate_metrics as calculate_metrics_ +from .util import TaskType, load_json + +ArrayDict = Dict[str, np.ndarray] +TensorDict = Dict[str, torch.Tensor] + + +CAT_MISSING_VALUE = 'nan' +CAT_RARE_VALUE = '__rare__' +Normalization = Literal['standard', 'quantile', 'minmax'] +NumNanPolicy = Literal['drop-rows', 'mean'] +CatNanPolicy = Literal['most_frequent'] +CatEncoding = Literal['one-hot', 'counter'] +YPolicy = Literal['default'] +DEQUANT_DIST = Literal['uniform', 'beta', 'round', 'none'] + + +class StandardScaler1d(StandardScaler): + def partial_fit(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().partial_fit(X[:, None], *args, **kwargs) + + def transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().transform(X[:, None], *args, **kwargs).squeeze(1) + + def inverse_transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().inverse_transform(X[:, None], *args, **kwargs).squeeze(1) + + +def get_category_sizes(X: Union[torch.Tensor, np.ndarray]) -> List[int]: + XT = X.T.cpu().tolist() if isinstance(X, torch.Tensor) else X.T.tolist() + return [len(set(x)) for x in XT] + + +@dataclass(frozen=False) +class Dataset: + X_num: Optional[ArrayDict] + X_cat: Optional[ArrayDict] + y: ArrayDict + int_col_idx_wrt_num: list + y_info: Dict[str, Any] + task_type: TaskType + n_classes: Optional[int] + + @classmethod + def from_dir(cls, dir_: Union[Path, str]) -> 'Dataset': + dir_ = Path(dir_) + splits = [k for k in ['train', 'test'] if dir_.joinpath(f'y_{k}.npy').exists()] + + def load(item) -> ArrayDict: + return { + x: cast(np.ndarray, np.load(dir_ / f'{item}_{x}.npy', allow_pickle=True)) # type: ignore[code] + for x in splits + } + + if Path(dir_ / 'info.json').exists(): + info = util.load_json(dir_ / 'info.json') + else: + info = None + return Dataset( + load('X_num') if dir_.joinpath('X_num_train.npy').exists() else None, + load('X_cat') if dir_.joinpath('X_cat_train.npy').exists() else None, + load('y'), + {}, + TaskType(info['task_type']), + info.get('n_classes'), + ) + + @property + def is_binclass(self) -> bool: + return self.task_type == TaskType.BINCLASS + + @property + def is_multiclass(self) -> bool: + return self.task_type == TaskType.MULTICLASS + + @property + def is_regression(self) -> bool: + return self.task_type == TaskType.REGRESSION + + @property + def n_num_features(self) -> int: + return 0 if self.X_num is None else self.X_num['train'].shape[1] + + @property + def n_cat_features(self) -> int: + return 0 if self.X_cat is None else self.X_cat['train'].shape[1] + + @property + def n_features(self) -> int: + return self.n_num_features + self.n_cat_features + + def size(self, part: Optional[str]) -> int: + return sum(map(len, self.y.values())) if part is None else len(self.y[part]) + + @property + def nn_output_dim(self) -> int: + if self.is_multiclass: + assert self.n_classes is not None + return self.n_classes + else: + return 1 + + def get_category_sizes(self, part: str) -> List[int]: + return [] if self.X_cat is None else get_category_sizes(self.X_cat[part]) + + def calculate_metrics( + self, + predictions: Dict[str, np.ndarray], + prediction_type: Optional[str], + ) -> Dict[str, Any]: + metrics = { + x: calculate_metrics_( + self.y[x], predictions[x], self.task_type, prediction_type, self.y_info + ) + for x in predictions + } + if self.task_type == TaskType.REGRESSION: + score_key = 'rmse' + score_sign = -1 + else: + score_key = 'accuracy' + score_sign = 1 + for part_metrics in metrics.values(): + part_metrics['score'] = score_sign * part_metrics[score_key] + return metrics + +def change_val(dataset: Dataset, val_size: float = 0.2): + # should be done before transformations + + y = np.concatenate([dataset.y['train'], dataset.y['val']], axis=0) + + ixs = np.arange(y.shape[0]) + if dataset.is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + + dataset.y['train'] = y[train_ixs] + dataset.y['val'] = y[val_ixs] + + if dataset.X_num is not None: + X_num = np.concatenate([dataset.X_num['train'], dataset.X_num['val']], axis=0) + dataset.X_num['train'] = X_num[train_ixs] + dataset.X_num['val'] = X_num[val_ixs] + + if dataset.X_cat is not None: + X_cat = np.concatenate([dataset.X_cat['train'], dataset.X_cat['val']], axis=0) + dataset.X_cat['train'] = X_cat[train_ixs] + dataset.X_cat['val'] = X_cat[val_ixs] + + return dataset + +def num_process_nans(dataset: Dataset, policy: Optional[NumNanPolicy]) -> Dataset: + + assert dataset.X_num is not None + nan_masks = {k: np.isnan(v) for k, v in dataset.X_num.items()} + if not any(x.any() for x in nan_masks.values()): # type: ignore[code] + # assert policy is None + print('No NaNs in numerical features, skipping') + return dataset + + assert policy is not None + if policy == 'drop-rows': + valid_masks = {k: ~v.any(1) for k, v in nan_masks.items()} + assert valid_masks[ + 'test' + ].all(), 'Cannot drop test rows, since this will affect the final metrics.' + new_data = {} + for data_name in ['X_num', 'X_cat', 'y']: + data_dict = getattr(dataset, data_name) + if data_dict is not None: + new_data[data_name] = { + k: v[valid_masks[k]] for k, v in data_dict.items() + } + dataset = replace(dataset, **new_data) + elif policy == 'mean': + new_values = np.nanmean(dataset.X_num['train'], axis=0) + X_num = deepcopy(dataset.X_num) + for k, v in X_num.items(): + num_nan_indices = np.where(nan_masks[k]) + v[num_nan_indices] = np.take(new_values, num_nan_indices[1]) + dataset = replace(dataset, X_num=X_num) + else: + assert util.raise_unknown('policy', policy) + return dataset + + +# Inspired by: https://github.com/yandex-research/rtdl/blob/a4c93a32b334ef55d2a0559a4407c8306ffeeaee/lib/data.py#L20 +def normalize( + X: ArrayDict, normalization: Normalization, seed: Optional[int], return_normalizer : bool = False +) -> ArrayDict: + X_train = X['train'] + if normalization == 'standard': + normalizer = sklearn.preprocessing.StandardScaler() + elif normalization == 'minmax': + normalizer = sklearn.preprocessing.MinMaxScaler() + elif normalization == 'quantile': + normalizer = sklearn.preprocessing.QuantileTransformer( + output_distribution='normal', + n_quantiles=max(min(X['train'].shape[0] // 30, 1000), 10), + subsample=int(1e9), + random_state=seed, + ) + # noise = 1e-3 + # if noise > 0: + # assert seed is not None + # stds = np.std(X_train, axis=0, keepdims=True) + # noise_std = noise / np.maximum(stds, noise) # type: ignore[code] + # X_train = X_train + noise_std * np.random.default_rng(seed).standard_normal( + # X_train.shape + # ) + else: + util.raise_unknown('normalization', normalization) + + normalizer.fit(X_train) + if return_normalizer: + return {k: normalizer.transform(v) for k, v in X.items()}, normalizer + return {k: normalizer.transform(v) for k, v in X.items()} + +class dequantizer: + def __init__( + self, + dequant_dist: DEQUANT_DIST, + int_col_idx_wrt_num: list, + int_dequant_factor: float, + # return_dequantizer: bool = False + ): + self.dequant_dist = dequant_dist + self.int_col_idx_wrt_num = int_col_idx_wrt_num + self.int_dequant_factor = int_dequant_factor + def transform(self, X): + X_int = X[:, self.int_col_idx_wrt_num] + if self.dequant_dist == 'uniform': + X[:, self.int_col_idx_wrt_num] = X_int+ np.random.uniform(size=X_int.shape) * self.int_dequant_factor + elif self.dequant_dist == 'beta': + X[:, self.int_col_idx_wrt_num] = X_int + np.random.beta(self.int_dequant_factor, self.int_dequant_factor, size=X_int.shape) - 0.5 + elif self.dequant_dist in ['round', 'none']: + pass + return X + def inverse_transform(self, X): + X_int = X[:, self.int_col_idx_wrt_num] + if self.dequant_dist == 'uniform': + X[:, self.int_col_idx_wrt_num] = np.floor(X_int) + elif self.dequant_dist == 'beta': + X[:, self.int_col_idx_wrt_num] = np.rint(X_int) + elif self.dequant_dist == 'round': + X[:, self.int_col_idx_wrt_num] = np.rint(X_int) + elif self.dequant_dist == 'none': + pass + return X + + + # if return_dequantizer: + # return {k: transform(v) for k, v in X.items()}, inverse_transform + # return {k: transform(v) for k, v in X.items()} + +def cat_process_nans(X: ArrayDict, policy: Optional[CatNanPolicy]) -> ArrayDict: + assert X is not None + nan_masks = {k: v == CAT_MISSING_VALUE for k, v in X.items()} + if any(x.any() for x in nan_masks.values()): # type: ignore[code] + if policy is None: + X_new = X + elif policy == 'most_frequent': + imputer = SimpleImputer(missing_values=CAT_MISSING_VALUE, strategy=policy) # type: ignore[code] + imputer.fit(X['train']) + X_new = {k: cast(np.ndarray, imputer.transform(v)) for k, v in X.items()} + else: + util.raise_unknown('categorical NaN policy', policy) + else: + assert policy is None + X_new = X + return X_new + + +def cat_drop_rare(X: ArrayDict, min_frequency: float) -> ArrayDict: + assert 0.0 < min_frequency < 1.0 + min_count = round(len(X['train']) * min_frequency) + X_new = {x: [] for x in X} + for column_idx in range(X['train'].shape[1]): + counter = Counter(X['train'][:, column_idx].tolist()) + popular_categories = {k for k, v in counter.items() if v >= min_count} + for part in X_new: + X_new[part].append( + [ + (x if x in popular_categories else CAT_RARE_VALUE) + for x in X[part][:, column_idx].tolist() + ] + ) + return {k: np.array(v).T for k, v in X_new.items()} + + +def cat_encode( + X: ArrayDict, + encoding: Optional[CatEncoding], + y_train: Optional[np.ndarray], + seed: Optional[int], + return_encoder : bool = False +) -> Tuple[ArrayDict, bool, Optional[Any]]: # (X, is_converted_to_numerical) + if encoding != 'counter': + y_train = None + + # Step 1. Map strings to 0-based ranges + + if encoding is None: + unknown_value = np.iinfo('int64').max - 3 + oe = sklearn.preprocessing.OrdinalEncoder( + handle_unknown='use_encoded_value', # type: ignore[code] + unknown_value=unknown_value, # type: ignore[code] + dtype='int64', # type: ignore[code] + ).fit(X['train']) + encoder = make_pipeline(oe) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + max_values = X['train'].max(axis=0) + for part in X.keys(): + if part == 'train': continue + for column_idx in range(X[part].shape[1]): + X[part][X[part][:, column_idx] == unknown_value, column_idx] = ( + max_values[column_idx] + 1 + ) + if return_encoder: + return (X, False, encoder) + return (X, False) + + # Step 2. Encode. + + elif encoding == 'one-hot': + ohe = sklearn.preprocessing.OneHotEncoder( + handle_unknown='ignore', sparse_output=False, dtype=np.float32 # type: ignore[code] + ) + encoder = make_pipeline(ohe) + + # encoder.steps.append(('ohe', ohe)) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + + elif encoding == 'counter': + assert y_train is not None + assert seed is not None + loe = LeaveOneOutEncoder(sigma=0.1, random_state=seed, return_df=False) + encoder.steps.append(('loe', loe)) + encoder.fit(X['train'], y_train) + X = {k: encoder.transform(v).astype('float32') for k, v in X.items()} # type: ignore[code] + if not isinstance(X['train'], pd.DataFrame): + X = {k: v.values for k, v in X.items()} # type: ignore[code] + else: + util.raise_unknown('encoding', encoding) + + if return_encoder: + return X, True, encoder # type: ignore[code] + return (X, True) + + +def build_target( + y: ArrayDict, policy: Optional[YPolicy], task_type: TaskType +) -> Tuple[ArrayDict, Dict[str, Any]]: + info: Dict[str, Any] = {'policy': policy} + if policy is None: + pass + elif policy == 'default': + if task_type == TaskType.REGRESSION: + mean, std = float(y['train'].mean()), float(y['train'].std()) + y = {k: (v - mean) / std for k, v in y.items()} + info['mean'] = mean + info['std'] = std + else: + util.raise_unknown('policy', policy) + return y, info + + +@dataclass(frozen=True) +class Transformations: + seed: int = 0 + normalization: Optional[Normalization] = None + num_nan_policy: Optional[NumNanPolicy] = None + cat_nan_policy: Optional[CatNanPolicy] = None + cat_min_frequency: Optional[float] = None + cat_encoding: Optional[CatEncoding] = None + y_policy: Optional[YPolicy] = 'default' + dequant_dist: Optional[DEQUANT_DIST] = None + int_dequant_factor: Optional[float] = 0.0 + + +def transform_dataset( + dataset: Dataset, + transformations: Transformations, + cache_dir: Optional[Path], + return_transforms: bool = False +) -> Dataset: + # WARNING: the order of transformations matters. Moreover, the current + # implementation is not ideal in that sense. + if cache_dir is not None: + transformations_md5 = hashlib.md5( + str(transformations).encode('utf-8') + ).hexdigest() + transformations_str = '__'.join(map(str, astuple(transformations))) + cache_path = ( + cache_dir / f'cache__{transformations_str}__{transformations_md5}.pickle' + ) + if cache_path.exists(): + cache_transformations, value = util.load_pickle(cache_path) + if transformations == cache_transformations: + print( + f"Using cached features: {cache_dir.name + '/' + cache_path.name}" + ) + return value + else: + raise RuntimeError(f'Hash collision for {cache_path}') + else: + cache_path = None + + if dataset.X_num is not None: + dataset = num_process_nans(dataset, transformations.num_nan_policy) + + num_transform = None + int_transform = None + cat_transform = None + X_num = dataset.X_num + + int_col_idx_wrt_num = dataset.int_col_idx_wrt_num + if X_num is not None and int_col_idx_wrt_num and transformations.dequant_dist is not None: + int_transform = dequantizer( + transformations.dequant_dist, + int_col_idx_wrt_num, + transformations.int_dequant_factor, + ) + X_num = {k: int_transform.transform(v) for k, v in X_num.items()} + + if X_num is not None and transformations.normalization is not None: + has_num = all([x.shape[1]>0 for x in dataset.X_num.values()]) + if has_num: + X_num, num_transform = normalize( + X_num, + transformations.normalization, + transformations.seed, + return_normalizer=True + ) + num_transform = num_transform + + if dataset.X_cat is None: + assert transformations.cat_nan_policy is None + assert transformations.cat_min_frequency is None + # assert transformations.cat_encoding is None + X_cat = None + else: + has_cat = all([x.shape[1]>0 for x in dataset.X_cat.values()]) + if not has_cat: + assert transformations.cat_nan_policy is None + assert transformations.cat_min_frequency is None + X_cat = dataset.X_cat + for split in X_cat.keys(): # a patch to make sure that the empty array is transformed into int dtype + X_cat[split] = X_cat[split].astype(np.int64) + else: + X_cat = cat_process_nans(dataset.X_cat, transformations.cat_nan_policy) + + if transformations.cat_min_frequency is not None: + X_cat = cat_drop_rare(X_cat, transformations.cat_min_frequency) + X_cat, is_num, cat_transform = cat_encode( + X_cat, + transformations.cat_encoding, + dataset.y['train'], + transformations.seed, + return_encoder=True + ) + + if is_num: + X_num = ( + X_cat + if X_num is None + else {x: np.hstack([X_num[x], X_cat[x]]) for x in X_num} + ) + X_cat = None + + + y, y_info = build_target(dataset.y, transformations.y_policy, dataset.task_type) + + dataset = replace(dataset, X_num=X_num, X_cat=X_cat, y=y, y_info=y_info) + dataset.num_transform = num_transform + dataset.int_transform = int_transform + dataset.cat_transform = cat_transform + + if cache_path is not None: + util.dump_pickle((transformations, dataset), cache_path) + # if return_transforms: + # return dataset, num_transform, cat_transform + return dataset + + +def build_dataset( + path: Union[str, Path], + transformations: Transformations, + cache: bool +) -> Dataset: + path = Path(path) + dataset = Dataset.from_dir(path) + return transform_dataset(dataset, transformations, path if cache else None) + + +def prepare_tensors( + dataset: Dataset, device: Union[str, torch.device] +) -> Tuple[Optional[TensorDict], Optional[TensorDict], TensorDict]: + X_num, X_cat, Y = ( + None if x is None else {k: torch.as_tensor(v) for k, v in x.items()} + for x in [dataset.X_num, dataset.X_cat, dataset.y] + ) + if device.type != 'cpu': + X_num, X_cat, Y = ( + None if x is None else {k: v.to(device) for k, v in x.items()} + for x in [X_num, X_cat, Y] + ) + assert X_num is not None + assert Y is not None + if not dataset.is_multiclass: + Y = {k: v.float() for k, v in Y.items()} + return X_num, X_cat, Y + +############### +## DataLoader## +############### + +class TabDataset(torch.utils.data.Dataset): + def __init__( + self, dataset : Dataset, split : Literal['train', 'val', 'test'] + ): + super().__init__() + + self.X_num = torch.from_numpy(dataset.X_num[split]) if dataset.X_num is not None else None + self.X_cat = torch.from_numpy(dataset.X_cat[split]) if dataset.X_cat is not None else None + self.y = torch.from_numpy(dataset.y[split]) + + assert self.y is not None + assert self.X_num is not None or self.X_cat is not None + + def __len__(self): + return len(self.y) + + def __getitem__(self, idx): + out_dict = { + 'y': self.y[idx].long() if self.y is not None else None, + } + + x = np.empty((0,)) + if self.X_num is not None: + x = self.X_num[idx] + if self.X_cat is not None: + x = torch.cat([x, self.X_cat[idx]], dim=0) + return x.float(), out_dict + +def prepare_dataloader( + dataset : Dataset, + split : str, + batch_size: int, +): + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader( + torch_dataset, + batch_size=batch_size, + shuffle=(split == 'train'), + num_workers=1, + ) + while True: + yield from loader + +def prepare_torch_dataloader( + dataset : Dataset, + split : str, + shuffle : bool, + batch_size: int, +) -> torch.utils.data.DataLoader: + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader(torch_dataset, batch_size=batch_size, shuffle=shuffle, num_workers=1) + + return loader + +def dataset_from_csv(paths : Dict[str, str], cat_features, target, T): + assert 'train' in paths + y = {} + X_num = {} + X_cat = {} if len(cat_features) else None + for split in paths.keys(): + df = pd.read_csv(paths[split]) + y[split] = df[target].to_numpy().astype(float) + if X_cat is not None: + X_cat[split] = df[cat_features].to_numpy().astype(str) + X_num[split] = df.drop(cat_features + [target], axis=1).to_numpy().astype(float) + + dataset = Dataset(X_num, X_cat, y, {}, None, len(np.unique(y['train']))) + return transform_dataset(dataset, T, None) + +class FastTensorDataLoader: + """ + A DataLoader-like object for a set of tensors that can be much faster than + TensorDataset + DataLoader because dataloader grabs individual indices of + the dataset and calls cat (slow). + Source: https://discuss.pytorch.org/t/dataloader-much-slower-than-manual-batching/27014/6 + """ + def __init__(self, *tensors, batch_size=32, shuffle=False): + """ + Initialize a FastTensorDataLoader. + :param *tensors: tensors to store. Must have the same length @ dim 0. + :param batch_size: batch size to load. + :param shuffle: if True, shuffle the data *in-place* whenever an + iterator is created out of this object. + :returns: A FastTensorDataLoader. + """ + assert all(t.shape[0] == tensors[0].shape[0] for t in tensors) + self.tensors = tensors + + self.dataset_len = self.tensors[0].shape[0] + self.batch_size = batch_size + self.shuffle = shuffle + + # Calculate # batches + n_batches, remainder = divmod(self.dataset_len, self.batch_size) + if remainder > 0: + n_batches += 1 + self.n_batches = n_batches + def __iter__(self): + if self.shuffle: + r = torch.randperm(self.dataset_len) + self.tensors = [t[r] for t in self.tensors] + self.i = 0 + return self + + def __next__(self): + if self.i >= self.dataset_len: + raise StopIteration + batch = tuple(t[self.i:self.i+self.batch_size] for t in self.tensors) + self.i += self.batch_size + return batch + + def __len__(self): + return self.n_batches + +def prepare_fast_dataloader( + D : Dataset, + split : str, + batch_size: int +): + + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + dataloader = FastTensorDataLoader(X, batch_size=batch_size, shuffle=(split=='train')) + while True: + yield from dataloader + +def prepare_fast_torch_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + return dataloader + +def round_columns(X_real, X_synth, columns): + for col in columns: + uniq = np.unique(X_real[:,col]) + dist = cdist(X_synth[:, col][:, np.newaxis].astype(float), uniq[:, np.newaxis].astype(float)) + X_synth[:, col] = uniq[dist.argmin(axis=1)] + return X_synth + +def concat_features(D : Dataset): + if D.X_num is None: + assert D.X_cat is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_cat.items()} + elif D.X_cat is None: + assert D.X_num is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_num.items()} + else: + X = { + part: pd.concat( + [ + pd.DataFrame(D.X_num[part], columns=range(D.n_num_features)), + pd.DataFrame( + D.X_cat[part], + columns=range(D.n_num_features, D.n_features), + ), + ], + axis=1, + ) + for part in D.y.keys() + } + + return X + +def concat_to_pd(X_num, X_cat, y): + if X_num is None: + return pd.concat([ + pd.DataFrame(X_cat, columns=list(range(X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + if X_cat is not None: + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(X_cat, columns=list(range(X_num.shape[1], X_num.shape[1] + X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + +def read_pure_data(path, split='train'): + y = np.load(os.path.join(path, f'y_{split}.npy'), allow_pickle=True) + X_num = None + X_cat = None + if os.path.exists(os.path.join(path, f'X_num_{split}.npy')): + X_num = np.load(os.path.join(path, f'X_num_{split}.npy'), allow_pickle=True) + if os.path.exists(os.path.join(path, f'X_cat_{split}.npy')): + X_cat = np.load(os.path.join(path, f'X_cat_{split}.npy'), allow_pickle=True) + + return X_num, X_cat, y + +def read_changed_val(path, val_size=0.2): + path = Path(path) + X_num_train, X_cat_train, y_train = read_pure_data(path, 'train') + X_num_val, X_cat_val, y_val = read_pure_data(path, 'val') + is_regression = load_json(path / 'info.json')['task_type'] == 'regression' + + y = np.concatenate([y_train, y_val], axis=0) + + ixs = np.arange(y.shape[0]) + if is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + y_train = y[train_ixs] + y_val = y[val_ixs] + + if X_num_train is not None: + X_num = np.concatenate([X_num_train, X_num_val], axis=0) + X_num_train = X_num[train_ixs] + X_num_val = X_num[val_ixs] + + if X_cat_train is not None: + X_cat = np.concatenate([X_cat_train, X_cat_val], axis=0) + X_cat_train = X_cat[train_ixs] + X_cat_val = X_cat[val_ixs] + + return X_num_train, X_cat_train, y_train, X_num_val, X_cat_val, y_val + +############# + +def load_dataset_info(dataset_dir_name: str) -> Dict[str, Any]: + path = Path("data/" + dataset_dir_name) + info = util.load_json(path / 'info.json') + info['size'] = info['train_size'] + info['val_size'] + info['test_size'] + info['n_features'] = info['n_num_features'] + info['n_cat_features'] + info['path'] = path + return info \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/env.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/env.py new file mode 100644 index 0000000000000000000000000000000000000000..0b9dd619f31450414a9b31585aa58b9121834fbe --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/env.py @@ -0,0 +1,39 @@ +""" +Have not used in TabDDPM project. +""" + +import datetime +import os +import shutil +import typing as ty +from pathlib import Path + +PROJ = Path('tab-ddpm/').absolute().resolve() +EXP = PROJ / 'exp' +DATA = PROJ / 'data' + + +def get_path(path: ty.Union[str, Path]) -> Path: + if isinstance(path, str): + path = Path(path) + if not path.is_absolute(): + path = PROJ / path + return path.resolve() + + +def get_relative_path(path: ty.Union[str, Path]) -> Path: + return get_path(path).relative_to(PROJ) + + +def duplicate_path( + src: ty.Union[str, Path], alternative_project_dir: ty.Union[str, Path] +) -> None: + src = get_path(src) + alternative_project_dir = get_path(alternative_project_dir) + dst = alternative_project_dir / src.relative_to(PROJ) + dst.parent.mkdir(parents=True, exist_ok=True) + if dst.exists(): + dst = dst.with_name( + dst.name + '_' + datetime.datetime.now().strftime('%Y%m%dT%H%M%S') + ) + (shutil.copytree if src.is_dir() else shutil.copyfile)(src, dst) \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/metrics.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/metrics.py new file mode 100644 index 0000000000000000000000000000000000000000..188a9be3f8e9d59b07688aa189a876660dbef7cd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/metrics.py @@ -0,0 +1,157 @@ +import enum +from typing import Any, Optional, Tuple, Dict, Union, cast +from functools import partial + +import numpy as np +import scipy.special +import sklearn.metrics as skm + +from . import util +from .util import TaskType + + +class PredictionType(enum.Enum): + LOGITS = 'logits' + PROBS = 'probs' + +class MetricsReport: + def __init__(self, report: dict, task_type: TaskType): + self._res = {k: {} for k in report.keys()} + if task_type in (TaskType.BINCLASS, TaskType.MULTICLASS): + self._metrics_names = ["acc", "f1"] + for k in report.keys(): + self._res[k]["acc"] = report[k]["accuracy"] + self._res[k]["f1"] = report[k]["macro avg"]["f1-score"] + if task_type == TaskType.BINCLASS: + self._res[k]["roc_auc"] = report[k]["roc_auc"] + self._metrics_names.append("roc_auc") + + elif task_type == TaskType.REGRESSION: + self._metrics_names = ["r2", "rmse"] + for k in report.keys(): + self._res[k]["r2"] = report[k]["r2"] + self._res[k]["rmse"] = report[k]["rmse"] + else: + raise "Unknown TaskType!" + + def get_splits_names(self) -> list[str]: + return self._res.keys() + + def get_metrics_names(self) -> list[str]: + return self._metrics_names + + def get_metric(self, split: str, metric: str) -> float: + return self._res[split][metric] + + def get_val_score(self) -> float: + return self._res["val"]["r2"] if "r2" in self._res["val"] else self._res["val"]["f1"] + + def get_test_score(self) -> float: + return self._res["test"]["r2"] if "r2" in self._res["test"] else self._res["test"]["f1"] + + def print_metrics(self) -> None: + res = { + "val": {k: np.around(self._res["val"][k], 4) for k in self._res["val"]}, + "test": {k: np.around(self._res["test"][k], 4) for k in self._res["test"]} + } + + print("*"*100) + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + + return res + +class SeedsMetricsReport: + def __init__(self): + self._reports = [] + + def add_report(self, report: MetricsReport) -> None: + self._reports.append(report) + + def get_mean_std(self) -> dict: + res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + res[split][metric] = [x.get_metric(split, metric) for x in self._reports] + + agg_res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + for k, f in [("count", len), ("mean", np.mean), ("std", np.std)]: + agg_res[split][f"{metric}-{k}"] = f(res[split][metric]) + self._res = res + self._agg_res = agg_res + + return agg_res + + def print_result(self) -> dict: + res = {split: {k: float(np.around(self._agg_res[split][k], 4)) for k in self._agg_res[split]} for split in ["val", "test"]} + print("="*100) + print("EVAL RESULTS:") + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + print("="*100) + return res + +def calculate_rmse( + y_true: np.ndarray, y_pred: np.ndarray, std = None) -> float: + rmse = skm.mean_squared_error(y_true, y_pred) ** 0.5 + if std is not None: + rmse *= std + return rmse + + +def _get_labels_and_probs( + y_pred: np.ndarray, task_type: TaskType, prediction_type: Optional[PredictionType] +) -> Tuple[np.ndarray, Optional[np.ndarray]]: + assert task_type in (TaskType.BINCLASS, TaskType.MULTICLASS) + + if prediction_type is None: + return y_pred, None + + if prediction_type == PredictionType.LOGITS: + probs = ( + scipy.special.expit(y_pred) + if task_type == TaskType.BINCLASS + else scipy.special.softmax(y_pred, axis=1) + ) + elif prediction_type == PredictionType.PROBS: + probs = y_pred + else: + util.raise_unknown('prediction_type', prediction_type) + + assert probs is not None + labels = np.round(probs) if task_type == TaskType.BINCLASS else probs.argmax(axis=1) + return labels.astype('int64'), probs + + +def calculate_metrics( + y_true: np.ndarray, + y_pred: np.ndarray, + task_type: Union[str, TaskType], + prediction_type: Optional[Union[str, PredictionType]], + y_info: Dict[str, Any], +) -> Dict[str, Any]: + # Example: calculate_metrics(y_true, y_pred, 'binclass', 'logits', {}) + task_type = TaskType(task_type) + if prediction_type is not None: + prediction_type = PredictionType(prediction_type) + + if task_type == TaskType.REGRESSION: + assert prediction_type is None + assert 'std' in y_info + rmse = calculate_rmse(y_true, y_pred, y_info['std']) + r2 = skm.r2_score(y_true, y_pred) + result = {'rmse': rmse, 'r2': r2} + else: + labels, probs = _get_labels_and_probs(y_pred, task_type, prediction_type) + result = cast( + Dict[str, Any], skm.classification_report(y_true, labels, output_dict=True) + ) + if task_type == TaskType.BINCLASS: + result['roc_auc'] = skm.roc_auc_score(y_true, probs) + return result \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/util.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/util.py new file mode 100644 index 0000000000000000000000000000000000000000..e105c961803b3bf0f8282e673eed8e84eaaa3891 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/src/util.py @@ -0,0 +1,347 @@ +import argparse +import atexit +import enum +import json +import os +import pickle +import shutil +import sys +import time +import uuid +from copy import deepcopy +from dataclasses import asdict, fields, is_dataclass +from pathlib import Path +from pprint import pprint +from typing import Any, Callable, List, Dict, Type, Optional, Tuple, TypeVar, Union, cast, get_args, get_origin + +import __main__ +import numpy as np +import tomli +import tomli_w +import torch +import typing as ty + +from . import env + +RawConfig = Dict[str, Any] +Report = Dict[str, Any] +T = TypeVar('T') + + +class Part(enum.Enum): + TRAIN = 'train' + VAL = 'val' + TEST = 'test' + + def __str__(self) -> str: + return self.value + + +class TaskType(enum.Enum): + BINCLASS = 'binclass' + MULTICLASS = 'multiclass' + REGRESSION = 'regression' + + def __str__(self) -> str: + return self.value + + + +def update_training_log(training_log, data, metrics): + def _update(log_part, data_part): + for k, v in data_part.items(): + if isinstance(v, dict): + _update(log_part.setdefault(k, {}), v) + elif isinstance(v, list): + log_part.setdefault(k, []).extend(v) + else: + log_part.setdefault(k, []).append(v) + + _update(training_log, data) + transposed_metrics = {} + for part, part_metrics in metrics.items(): + for metric_name, value in part_metrics.items(): + transposed_metrics.setdefault(metric_name, {})[part] = value + _update(training_log, transposed_metrics) + + +def raise_unknown(unknown_what: str, unknown_value: Any): + raise ValueError(f'Unknown {unknown_what}: {unknown_value}') + + +def _replace(data, condition, value): + def do(x): + if isinstance(x, dict): + return {k: do(v) for k, v in x.items()} + elif isinstance(x, list): + return [do(y) for y in x] + else: + return value if condition(x) else x + + return do(data) + + +_CONFIG_NONE = '__none__' + + +def unpack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x == _CONFIG_NONE, None)) + return config + + +def pack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x is None, _CONFIG_NONE)) + return config + + +def load_config(path: Union[Path, str]) -> Any: + with open(path, 'rb') as f: + return unpack_config(tomli.load(f)) + + +def dump_config(config: Any, path: Union[Path, str]) -> None: + with open(path, 'wb') as f: + tomli_w.dump(pack_config(config), f) + # check that there are no bugs in all these "pack/unpack" things + assert config == load_config(path) + + +def load_json(path: Union[Path, str], **kwargs) -> Any: + return json.loads(Path(path).read_text(), **kwargs) + + +def dump_json(x: Any, path: Union[Path, str], **kwargs) -> None: + kwargs.setdefault('indent', 4) + Path(path).write_text(json.dumps(x, **kwargs) + '\n') + + +def load_pickle(path: Union[Path, str], **kwargs) -> Any: + return pickle.loads(Path(path).read_bytes(), **kwargs) + + +def dump_pickle(x: Any, path: Union[Path, str], **kwargs) -> None: + Path(path).write_bytes(pickle.dumps(x, **kwargs)) + + +def load(path: Union[Path, str], **kwargs) -> Any: + return globals()[f'load_{Path(path).suffix[1:]}'](Path(path), **kwargs) + + +def dump(x: Any, path: Union[Path, str], **kwargs) -> Any: + return globals()[f'dump_{Path(path).suffix[1:]}'](x, Path(path), **kwargs) + + +def _get_output_item_path( + path: Union[str, Path], filename: str, must_exist: bool +) -> Path: + path = env.get_path(path) + if path.suffix == '.toml': + path = path.with_suffix('') + if path.is_dir(): + path = path / filename + else: + assert path.name == filename + assert path.parent.exists() + if must_exist: + assert path.exists() + return path + + +def load_report(path: Path) -> Report: + return load_json(_get_output_item_path(path, 'report.json', True)) + + +def dump_report(report: dict, path: Path) -> None: + dump_json(report, _get_output_item_path(path, 'report.json', False)) + + +def load_predictions(path: Path) -> Dict[str, np.ndarray]: + with np.load(_get_output_item_path(path, 'predictions.npz', True)) as predictions: + return {x: predictions[x] for x in predictions} + + +def dump_predictions(predictions: Dict[str, np.ndarray], path: Path) -> None: + np.savez(_get_output_item_path(path, 'predictions.npz', False), **predictions) + + +def dump_metrics(metrics: Dict[str, Any], path: Path) -> None: + dump_json(metrics, _get_output_item_path(path, 'metrics.json', False)) + + +def load_checkpoint(path: Path, *args, **kwargs) -> Dict[str, np.ndarray]: + return torch.load( + _get_output_item_path(path, 'checkpoint.pt', True), *args, **kwargs + ) + + +def get_device() -> torch.device: + if torch.cuda.is_available(): + assert os.environ.get('CUDA_VISIBLE_DEVICES') is not None + return torch.device('cuda:0') + else: + return torch.device('cpu') + + +def _print_sep(c, size=100): + print(c * size) + + +_LAST_SNAPSHOT_TIME = None + + +def backup_output(output_dir: Path) -> None: + backup_dir = os.environ.get('TMP_OUTPUT_PATH') + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if backup_dir is None: + assert snapshot_dir is None + return + assert snapshot_dir is not None + + try: + relative_output_dir = output_dir.relative_to(env.PROJ) + except ValueError: + return + + for dir_ in [backup_dir, snapshot_dir]: + new_output_dir = dir_ / relative_output_dir + prev_backup_output_dir = new_output_dir.with_name(new_output_dir.name + '_prev') + new_output_dir.parent.mkdir(exist_ok=True, parents=True) + if new_output_dir.exists(): + new_output_dir.rename(prev_backup_output_dir) + shutil.copytree(output_dir, new_output_dir) + # the case for evaluate.py which automatically creates configs + if output_dir.with_suffix('.toml').exists(): + shutil.copyfile( + output_dir.with_suffix('.toml'), new_output_dir.with_suffix('.toml') + ) + if prev_backup_output_dir.exists(): + shutil.rmtree(prev_backup_output_dir) + + global _LAST_SNAPSHOT_TIME + if _LAST_SNAPSHOT_TIME is None or time.time() - _LAST_SNAPSHOT_TIME > 10 * 60: + import nirvana_dl.snapshot # type: ignore[code] + + nirvana_dl.snapshot.dump_snapshot() + _LAST_SNAPSHOT_TIME = time.time() + print('The snapshot was saved!') + + +def _get_scores(metrics: Dict[str, Dict[str, Any]]) -> Optional[Dict[str, float]]: + return ( + {k: v['score'] for k, v in metrics.items()} + if 'score' in next(iter(metrics.values())) + else None + ) + + +def format_scores(metrics: Dict[str, Dict[str, Any]]) -> str: + return ' '.join( + f"[{x}] {metrics[x]['score']:.3f}" + for x in ['test', 'val', 'train'] + if x in metrics + ) + + +def finish(output_dir: Path, report: dict) -> None: + print() + _print_sep('=') + + metrics = report.get('metrics') + if metrics is not None: + scores = _get_scores(metrics) + if scores is not None: + dump_json(scores, output_dir / 'scores.json') + print(format_scores(metrics)) + _print_sep('-') + + dump_report(report, output_dir) + json_output_path = os.environ.get('JSON_OUTPUT_FILE') + if json_output_path: + try: + key = str(output_dir.relative_to(env.PROJ)) + except ValueError: + pass + else: + json_output_path = Path(json_output_path) + try: + json_data = json.loads(json_output_path.read_text()) + except (FileNotFoundError, json.decoder.JSONDecodeError): + json_data = {} + json_data[key] = load_json(output_dir / 'report.json') + json_output_path.write_text(json.dumps(json_data, indent=4)) + shutil.copyfile( + json_output_path, + os.path.join(os.environ['SNAPSHOT_PATH'], 'json_output.json'), + ) + + output_dir.joinpath('DONE').touch() + backup_output(output_dir) + print(f'Done! | {report.get("time")} | {output_dir}') + _print_sep('=') + print() + + +def from_dict(datacls: Type[T], data: dict) -> T: + assert is_dataclass(datacls) + data = deepcopy(data) + for field in fields(datacls): + if field.name not in data: + continue + if is_dataclass(field.type): + data[field.name] = from_dict(field.type, data[field.name]) + elif ( + get_origin(field.type) is Union + and len(get_args(field.type)) == 2 + and get_args(field.type)[1] is type(None) + and is_dataclass(get_args(field.type)[0]) + ): + if data[field.name] is not None: + data[field.name] = from_dict(get_args(field.type)[0], data[field.name]) + return datacls(**data) + + +def replace_factor_with_value( + config: RawConfig, + key: str, + reference_value: int, + bounds: Tuple[float, float], +) -> None: + factor_key = key + '_factor' + if factor_key not in config: + assert key in config + else: + assert key not in config + factor = config.pop(factor_key) + assert bounds[0] <= factor <= bounds[1] + config[key] = int(factor * reference_value) + + +def get_temporary_copy(path: Union[str, Path]) -> Path: + path = env.get_path(path) + assert not path.is_dir() and not path.is_symlink() + tmp_path = path.with_name( + path.stem + '___' + str(uuid.uuid4()).replace('-', '') + path.suffix + ) + shutil.copyfile(path, tmp_path) + atexit.register(lambda: tmp_path.unlink()) + return tmp_path + + +def get_python(): + python = Path('python3.9') + return str(python) if python.exists() else 'python' + +def get_catboost_config(real_data_path, is_cv=False): + ds_name = Path(real_data_path).name + C = load_json(f'tuned_models/catboost/{ds_name}_cv.json') + return C + +def get_categories(X_train_cat): + return ( + None + if X_train_cat is None + else [ + len(set(X_train_cat[:, i])) + for i in range(X_train_cat.shape[1]) + ] + ) \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/real.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/real.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/real.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/test.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/val.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/synthetic/pipeline_c12/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/conftest.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/conftest.py new file mode 100644 index 0000000000000000000000000000000000000000..f06feabdb2e28287232689c91868cc8e58730387 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/conftest.py @@ -0,0 +1,193 @@ +import pytest +import numpy as np +import torch +import torch.nn.functional as F +from unittest.mock import MagicMock + + +# --------------- dimension configs --------------- + +@pytest.fixture +def dims(): + """Standard mixed-data dimensions.""" + return {"d_numerical": 4, "categories": np.array([3, 5, 2]), "batch_size": 8, "d_token": 16} + + +@pytest.fixture +def dims_numerical_only(): + """Numerical-only scenario (no categorical features).""" + return {"d_numerical": 5, "categories": None, "batch_size": 8, "d_token": 16} + + +@pytest.fixture +def dims_single(): + """Minimal scenario: 1 numerical, 1 categorical with 2 classes.""" + return {"d_numerical": 1, "categories": np.array([2]), "batch_size": 4, "d_token": 8} + + +# --------------- dummy input factory --------------- + +@pytest.fixture +def make_dummy_inputs(): + """Factory: returns (x_num, x_cat_onehot, x_cat_int, timesteps) from any dims.""" + def _make(d_numerical, categories, batch_size): + torch.manual_seed(42) + x_num = torch.randn(batch_size, d_numerical) + if categories is not None and len(categories) > 0: + cat_parts = [] + for k in categories: + indices = torch.randint(0, k, (batch_size,)) + cat_parts.append(F.one_hot(indices, k).float()) + x_cat_onehot = torch.cat(cat_parts, dim=1) + x_cat_int = torch.stack( + [torch.randint(0, k, (batch_size,)) for k in categories], dim=1 + ) + else: + x_cat_onehot = None + x_cat_int = None + timesteps = torch.rand(batch_size) + return x_num, x_cat_onehot, x_cat_int, timesteps + return _make + + +# --------------- model factories --------------- + +@pytest.fixture +def make_tokenizer(): + from ef_vfm.modules.transformer import Tokenizer + def _make(d_numerical, categories, d_token, bias=True): + cats = list(categories) if categories is not None else None + return Tokenizer(d_numerical, cats, d_token, bias) + return _make + + +@pytest.fixture +def make_transformer(): + from ef_vfm.modules.transformer import Transformer + def _make(d_token, n_layers=2, n_heads=1, d_ffn_factor=4, activation='gelu'): + return Transformer(n_layers, d_token, n_heads, d_token, d_ffn_factor, activation=activation) + return _make + + +@pytest.fixture +def make_reconstructor(): + from ef_vfm.modules.transformer import Reconstructor + def _make(d_numerical, categories, d_token): + cats = list(categories) if categories is not None else [] + return Reconstructor(d_numerical, cats, d_token) + return _make + + +@pytest.fixture +def make_mlp(): + from ef_vfm.modules.main_modules import MLP + def _make(d_in, dim_t=128, use_mlp=True): + return MLP(d_in, dim_t=dim_t, use_mlp=use_mlp) + return _make + + +@pytest.fixture +def make_unimodmlp(): + from ef_vfm.modules.main_modules import UniModMLP + def _make(d_numerical, categories, d_token=16, n_layers=1, n_head=1, + factor=4, dim_t=64, activation='gelu'): + cats = list(categories) if categories is not None else [] + return UniModMLP( + d_numerical, cats, n_layers, d_token, + n_head=n_head, factor=factor, dim_t=dim_t, activation=activation, + ) + return _make + + +@pytest.fixture +def make_flow_model(): + from ef_vfm.modules.main_modules import UniModMLP + from ef_vfm.models.flow_model import ExpVFM + def _make(d_numerical, categories, d_token=16, n_layers=1, dim_t=64): + cats_list = list(categories) if categories is not None else [] + cats_np = np.array(cats_list) + model = UniModMLP( + d_numerical, cats_list, n_layers, d_token, + n_head=1, factor=4, dim_t=dim_t, activation='gelu', + ) + flow = ExpVFM( + num_classes=cats_np, + num_numerical_features=d_numerical, + vf_fn=model, + device=torch.device('cpu'), + ) + return flow + return _make + + +@pytest.fixture +def make_trainer(): + """Factory: creates a minimal Trainer with mocked external dependencies.""" + from ef_vfm.modules.main_modules import UniModMLP + from ef_vfm.models.flow_model import ExpVFM + from ef_vfm.trainer import Trainer + + def _make(d_numerical=4, categories=np.array([3, 5, 2]), + lr=0.001, max_grad_norm=1.0, warmup_epochs=0, + lr_scheduler='reduce_lr_on_plateau', steps=10, tmp_path=None): + + cats_list = list(categories) if categories is not None else [] + cats_np = np.array(cats_list) + + model = UniModMLP( + d_numerical, cats_list, 1, 16, + n_head=1, factor=4, dim_t=64, activation='gelu', + ) + flow = ExpVFM( + num_classes=cats_np, + num_numerical_features=d_numerical, + vf_fn=model, + device=torch.device('cpu'), + ) + + # Build a small synthetic dataset: [N, d_num + len(cats)] with int cat indices + n_samples = 32 + x_num = torch.randn(n_samples, d_numerical) + if len(cats_list) > 0: + x_cat = torch.stack( + [torch.randint(0, k, (n_samples,)) for k in cats_list], dim=1 + ).float() + data = torch.cat([x_num, x_cat], dim=1) + else: + data = x_num + + dataset = torch.utils.data.TensorDataset(data) + train_iter = torch.utils.data.DataLoader(dataset, batch_size=8, shuffle=False) + # DataLoader wraps in tuples; Trainer expects raw tensors, so use a wrapper + class _UnwrapLoader: + def __init__(self, loader): + self._loader = loader + def __iter__(self): + for (batch,) in self._loader: + yield batch + def __len__(self): + return len(self._loader) + + save_path = str(tmp_path) if tmp_path else "/tmp" + trainer = Trainer( + flow=flow, + train_iter=_UnwrapLoader(train_iter), + dataset=MagicMock(), + test_dataset=MagicMock(), + metrics=MagicMock(), + logger=MagicMock(), + lr=lr, + weight_decay=0, + steps=steps, + batch_size=8, + check_val_every=steps + 1, # never evaluate during test + sample_batch_size=8, + model_save_path=save_path, + result_save_path=save_path, + lr_scheduler=lr_scheduler, + max_grad_norm=max_grad_norm, + warmup_epochs=warmup_epochs, + device=torch.device('cpu'), + ) + return trainer + return _make diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_attention.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_attention.py new file mode 100644 index 0000000000000000000000000000000000000000..6082db42ad2dff94440f4cc07659c57cf6326de4 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_attention.py @@ -0,0 +1,51 @@ +import pytest +import torch +from ef_vfm.modules.transformer import MultiheadAttention + + +def test_output_shape_single_head(): + attn = MultiheadAttention(d=16, n_heads=1, dropout=0.0) + x = torch.randn(4, 5, 16) + out = attn(x, x) + assert out.shape == (4, 5, 16) + + +def test_output_shape_multi_head(): + attn = MultiheadAttention(d=16, n_heads=4, dropout=0.0) + x = torch.randn(4, 5, 16) + out = attn(x, x) + assert out.shape == (4, 5, 16) + + +def test_no_W_out_single_head(): + attn = MultiheadAttention(d=16, n_heads=1, dropout=0.0) + assert attn.W_out is None + + +def test_W_out_exists_multi_head(): + attn = MultiheadAttention(d=16, n_heads=4, dropout=0.0) + assert attn.W_out is not None + + +def test_cross_attention_diff_seq_len(): + attn = MultiheadAttention(d=16, n_heads=1, dropout=0.0) + x_q = torch.randn(4, 3, 16) + x_kv = torch.randn(4, 7, 16) + out = attn(x_q, x_kv) + assert out.shape == (4, 3, 16) # output seq_len matches query + + +def test_invalid_d_nheads_raises(): + with pytest.raises(AssertionError): + MultiheadAttention(d=15, n_heads=4, dropout=0.0) + + +def test_gradient_flows(): + attn = MultiheadAttention(d=16, n_heads=2, dropout=0.0) + x = torch.randn(4, 5, 16, requires_grad=True) + out = attn(x, x) + out.sum().backward() + assert x.grad is not None and x.grad.abs().sum() > 0 + for name in ['W_q', 'W_k', 'W_v']: + param = getattr(attn, name) + assert param.weight.grad is not None and param.weight.grad.abs().sum() > 0 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_config.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_config.py new file mode 100644 index 0000000000000000000000000000000000000000..95c723f64388fe1259f0ba62f0ad8c6cf1051455 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_config.py @@ -0,0 +1,62 @@ +import os +from pathlib import Path + +from src.util import load_config +from ef_vfm.modules.main_modules import UniModMLP + + +CONFIG_PATH = Path(__file__).resolve().parent.parent / "ef_vfm" / "configs" / "ef_vfm_configs.toml" + + +def test_load_config_returns_dict(): + config = load_config(CONFIG_PATH) + assert isinstance(config, dict) + + +def test_config_has_expected_sections(): + config = load_config(CONFIG_PATH) + for key in ['data', 'unimodmlp_params', 'train', 'sample']: + assert key in config, f"Missing section '{key}'" + + +def test_unimodmlp_params_complete(): + config = load_config(CONFIG_PATH) + params = config['unimodmlp_params'] + required = ['num_layers', 'd_token', 'n_head', 'factor', 'bias', 'dim_t', 'use_mlp', 'activation'] + for key in required: + assert key in params, f"Missing param '{key}' in unimodmlp_params" + + +def test_activation_value_is_valid(): + config = load_config(CONFIG_PATH) + activation = config['unimodmlp_params']['activation'] + assert activation in ('relu', 'gelu', 'silu'), f"Invalid activation '{activation}'" + + +def test_train_main_has_new_params(): + """Verify the recently added config params are present.""" + config = load_config(CONFIG_PATH) + train = config['train']['main'] + assert 'max_grad_norm' in train + assert 'warmup_epochs' in train + assert isinstance(train['max_grad_norm'], (int, float)) + assert isinstance(train['warmup_epochs'], (int, float)) + + +def test_config_values_create_model(): + config = load_config(CONFIG_PATH) + params = config['unimodmlp_params'] + # Use dummy dimensions; the point is that config params are valid for the constructor + model = UniModMLP( + d_numerical=4, + categories=[3, 5, 2], + num_layers=params['num_layers'], + d_token=params['d_token'], + n_head=params['n_head'], + factor=params['factor'], + bias=params['bias'], + dim_t=params['dim_t'], + use_mlp=params['use_mlp'], + activation=params['activation'], + ) + assert model is not None diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_flow_model.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_flow_model.py new file mode 100644 index 0000000000000000000000000000000000000000..2bdc72bf2388cc70b56389463bdfd322b8badced --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_flow_model.py @@ -0,0 +1,219 @@ +import torch +import numpy as np +from unittest.mock import patch + +from ef_vfm.models.flow_model import ExpVFM, Velocity +from ef_vfm.modules.main_modules import UniModMLP + + +# ---- mixed_loss tests ---- + +def test_mixed_loss_returns_two_scalars(make_flow_model, make_dummy_inputs, dims): + d = dims + flow = make_flow_model(d["d_numerical"], d["categories"]) + _, _, x_cat_int, _ = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num = torch.randn(d["batch_size"], d["d_numerical"]) + x = torch.cat([x_num, x_cat_int.float()], dim=1) + d_loss, c_loss = flow.mixed_loss(x) + assert d_loss.dim() == 0 or d_loss.numel() == 1 + assert c_loss.dim() == 0 or c_loss.numel() == 1 + + +def test_mixed_loss_finite(make_flow_model, make_dummy_inputs, dims): + d = dims + flow = make_flow_model(d["d_numerical"], d["categories"]) + _, _, x_cat_int, _ = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num = torch.randn(d["batch_size"], d["d_numerical"]) + x = torch.cat([x_num, x_cat_int.float()], dim=1) + d_loss, c_loss = flow.mixed_loss(x) + assert torch.isfinite(d_loss).all() + assert torch.isfinite(c_loss).all() + + +def test_mixed_loss_gradients_flow(make_flow_model, make_dummy_inputs, dims): + d = dims + flow = make_flow_model(d["d_numerical"], d["categories"]) + _, _, x_cat_int, _ = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num = torch.randn(d["batch_size"], d["d_numerical"]) + x = torch.cat([x_num, x_cat_int.float()], dim=1) + d_loss, c_loss = flow.mixed_loss(x) + total = d_loss + c_loss + total.backward() + grads = [p.grad for p in flow.parameters() if p.grad is not None] + assert len(grads) > 0 + + +def test_mixed_loss_numerical_only(make_flow_model, make_dummy_inputs, dims_numerical_only): + d = dims_numerical_only + flow = make_flow_model(d["d_numerical"], d["categories"]) + x = torch.randn(d["batch_size"], d["d_numerical"]) + d_loss, c_loss = flow.mixed_loss(x) + assert d_loss.item() == 0.0 # no discrete features + assert c_loss.item() > 0.0 + + +# ---- sample tests (with mocked odeint) ---- + +def _make_flow(d_numerical, categories): + cats_list = list(categories) if categories is not None else [] + cats_np = np.array(cats_list) + model = UniModMLP(d_numerical, cats_list, 1, 16, n_head=1, factor=4, dim_t=64, activation='gelu') + return ExpVFM(cats_np, d_numerical, model, device=torch.device('cpu')) + + +def test_sample_output_shape(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + d_in = d["d_numerical"] + sum(d["categories"]) + n = 5 + fake_trajectory = torch.randn(2, n, d_in) + with patch("ef_vfm.models.flow_model.odeint", return_value=fake_trajectory): + result = flow.sample(n) + d_out = d["d_numerical"] + len(d["categories"]) + assert result.shape == (n, d_out) + + +def test_sample_categorical_in_range(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + d_in = d["d_numerical"] + sum(d["categories"]) + n = 16 + fake_trajectory = torch.randn(2, n, d_in) + with patch("ef_vfm.models.flow_model.odeint", return_value=fake_trajectory): + result = flow.sample(n) + for i, k in enumerate(d["categories"]): + col = d["d_numerical"] + i + assert (result[:, col] >= 0).all() + assert (result[:, col] < k).all() + + +def test_sample_returns_cpu(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + d_in = d["d_numerical"] + sum(d["categories"]) + fake_trajectory = torch.randn(2, 4, d_in) + with patch("ef_vfm.models.flow_model.odeint", return_value=fake_trajectory): + result = flow.sample(4) + assert result.device == torch.device('cpu') + + +def test_sample_single_sample(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + d_in = d["d_numerical"] + sum(d["categories"]) + fake_trajectory = torch.randn(2, 1, d_in) + with patch("ef_vfm.models.flow_model.odeint", return_value=fake_trajectory): + result = flow.sample(1) + d_out = d["d_numerical"] + len(d["categories"]) + assert result.shape == (1, d_out) + + +# ---- to_one_hot tests ---- + +def test_to_one_hot_shape(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + cats = d["categories"] + x_cat = torch.stack([torch.randint(0, k, (8,)) for k in cats], dim=1) + oh = flow.to_one_hot(x_cat) + assert oh.shape == (8, sum(cats)) + + +def test_to_one_hot_roundtrip(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + cats = d["categories"] + x_cat = torch.stack([torch.randint(0, k, (8,)) for k in cats], dim=1) + oh = flow.to_one_hot(x_cat) + # Recover indices via argmax per category slice + idx = 0 + for i, k in enumerate(cats): + recovered = oh[:, idx:idx + k].argmax(dim=1) + assert torch.equal(recovered, x_cat[:, i]) + idx += k + + +def test_to_one_hot_binary_values(dims): + d = dims + flow = _make_flow(d["d_numerical"], d["categories"]) + cats = d["categories"] + x_cat = torch.stack([torch.randint(0, k, (8,)) for k in cats], dim=1) + oh = flow.to_one_hot(x_cat) + assert set(oh.unique().tolist()).issubset({0, 1}) + + +# ---- Regression tests ---- + +def test_regression_d_in_no_extra_len(): + """d_in must be num_numerical + sum(num_classes), NOT + len(num_classes).""" + d_numerical = 4 + categories = np.array([3, 5, 2]) + flow = _make_flow(d_numerical, categories) + expected_d_in = d_numerical + sum(categories) # 14, not 17 + assert flow.num_numerical_features + sum(flow.num_classes) == expected_d_in + + +def test_regression_sampling_indices_correct(): + """Categorical argmax must go to columns [d_num, d_num+1, ...], not [0, 1, ...].""" + d_numerical = 4 + categories = np.array([3, 5, 2]) + n = 10 + d_in = d_numerical + sum(categories) + d_out = d_numerical + len(categories) + + # Simulate the post-processing from sample() + out = torch.randn(n, d_in) + sample = torch.zeros(n, d_out) + sample[:, :d_numerical] = out[:, :d_numerical] + + idx = d_numerical # correct starting index + for i, val in enumerate(categories): + col = d_numerical + i # correct column + sample[:, col] = torch.argmax(out[:, idx:idx + val], dim=1) + idx += val + + # Numerical columns must be untouched + assert torch.allclose(sample[:, :d_numerical], out[:, :d_numerical]) + # Categorical columns at correct positions + for i, val in enumerate(categories): + col = d_numerical + i + assert (sample[:, col] >= 0).all() + assert (sample[:, col] < val).all() + + +def test_regression_d_out_correct(): + """d_out must be d_num + len(categories).""" + d_numerical = 4 + categories = np.array([3, 5, 2]) + flow = _make_flow(d_numerical, categories) + expected_d_out = d_numerical + len(categories) # 7 + assert expected_d_out == 7 + + +# ---- Velocity tests ---- + +def test_velocity_output_shape(dims): + d = dims + cats_list = list(d["categories"]) + model = UniModMLP(d["d_numerical"], cats_list, 1, d["d_token"], + n_head=1, factor=4, dim_t=64, activation='gelu') + vel = Velocity(model) + d_in = d["d_numerical"] + sum(d["categories"]) + x = torch.randn(d["batch_size"], d_in) + t = torch.tensor(0.5) + out = vel(t, x) + assert out.shape == (d["batch_size"], d_in) + + +def test_velocity_scalar_t_broadcast(dims): + d = dims + cats_list = list(d["categories"]) + model = UniModMLP(d["d_numerical"], cats_list, 1, d["d_token"], + n_head=1, factor=4, dim_t=64, activation='gelu') + vel = Velocity(model) + d_in = d["d_numerical"] + sum(d["categories"]) + x = torch.randn(d["batch_size"], d_in) + # Scalar t should work (gets broadcast internally) + t = torch.tensor(0.3) + out = vel(t, x) + assert out.shape == x.shape diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_mlp.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_mlp.py new file mode 100644 index 0000000000000000000000000000000000000000..0cf9ad4d6832d792cb65a1bb01bdc784385f9fcd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_mlp.py @@ -0,0 +1,85 @@ +import torch +import torch.nn as nn +from ef_vfm.modules.main_modules import MLP, PositionalEmbedding + + +# ---- PositionalEmbedding tests ---- + +def test_positional_embedding_shape(): + pe = PositionalEmbedding(num_channels=64) + x = torch.rand(8) + out = pe(x) + assert out.shape == (8, 64) + + +def test_positional_embedding_bounded(): + pe = PositionalEmbedding(num_channels=64) + x = torch.rand(8) + out = pe(x) + assert out.min() >= -1.0 + assert out.max() <= 1.0 + + +def test_positional_embedding_deterministic(): + pe = PositionalEmbedding(num_channels=64) + x = torch.tensor([0.1, 0.5, 0.9]) + out1 = pe(x) + out2 = pe(x) + assert torch.equal(out1, out2) + + +def test_positional_embedding_different_timesteps(): + pe = PositionalEmbedding(num_channels=64) + t1 = torch.tensor([0.1]) + t2 = torch.tensor([0.9]) + assert not torch.allclose(pe(t1), pe(t2)) + + +# ---- MLP tests ---- + +def test_mlp_output_shape(make_mlp): + mlp = make_mlp(d_in=32, dim_t=64) + x = torch.randn(8, 32) + t = torch.rand(8) + out = mlp(x, t) + assert out.shape == (8, 32) + + +def test_mlp_use_mlp_true(make_mlp): + mlp = make_mlp(d_in=32, dim_t=64, use_mlp=True) + assert isinstance(mlp.mlp, nn.Sequential) + + +def test_mlp_use_mlp_false(make_mlp): + mlp = make_mlp(d_in=32, dim_t=64, use_mlp=False) + assert isinstance(mlp.mlp, nn.Linear) + + +def test_mlp_time_conditioning(make_mlp): + mlp = make_mlp(d_in=32, dim_t=64) + mlp.eval() + x = torch.randn(4, 32) + t1 = torch.zeros(4) + t2 = torch.ones(4) + out1 = mlp(x, t1) + out2 = mlp(x, t2) + assert not torch.allclose(out1, out2) + + +def test_mlp_gradient_flows(make_mlp): + mlp = make_mlp(d_in=32, dim_t=64) + x = torch.randn(4, 32) + t = torch.rand(4) + out = mlp(x, t) + out.sum().backward() + assert mlp.proj.weight.grad is not None and mlp.proj.weight.grad.abs().sum() > 0 + assert mlp.map_noise.num_channels == 64 # sanity check on PE config + + +def test_mlp_different_dim_t(make_mlp): + for dim_t in [32, 128, 256]: + mlp = make_mlp(d_in=16, dim_t=dim_t) + x = torch.randn(4, 16) + t = torch.rand(4) + out = mlp(x, t) + assert out.shape == (4, 16) diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_reconstructor.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_reconstructor.py new file mode 100644 index 0000000000000000000000000000000000000000..cdc39880d19f644fb8ac6b457af6a8cb3d83cbfa --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_reconstructor.py @@ -0,0 +1,51 @@ +import torch +import numpy as np +from ef_vfm.modules.transformer import Reconstructor + + +def test_output_shapes_mixed(make_reconstructor, dims): + d = dims + r = make_reconstructor(d["d_numerical"], d["categories"], d["d_token"]) + seq_len = d["d_numerical"] + len(d["categories"]) + h = torch.randn(d["batch_size"], seq_len, d["d_token"]) + x_num, x_cat = r(h) + assert x_num.shape == (d["batch_size"], d["d_numerical"]) + assert len(x_cat) == len(d["categories"]) + for i, k in enumerate(d["categories"]): + assert x_cat[i].shape == (d["batch_size"], k) + + +def test_categorical_count(make_reconstructor, dims): + d = dims + r = make_reconstructor(d["d_numerical"], d["categories"], d["d_token"]) + seq_len = d["d_numerical"] + len(d["categories"]) + h = torch.randn(d["batch_size"], seq_len, d["d_token"]) + _, x_cat = r(h) + assert len(x_cat) == len(d["categories"]) + + +def test_empty_categories(make_reconstructor): + r = make_reconstructor(4, np.array([]), 16) + h = torch.randn(8, 4, 16) + x_num, x_cat = r(h) + assert x_num.shape == (8, 4) + assert len(x_cat) == 0 + + +def test_weight_shape(make_reconstructor, dims): + d = dims + r = make_reconstructor(d["d_numerical"], d["categories"], d["d_token"]) + assert r.weight.shape == (d["d_numerical"], d["d_token"]) + + +def test_gradient_flows(make_reconstructor, dims): + d = dims + r = make_reconstructor(d["d_numerical"], d["categories"], d["d_token"]) + seq_len = d["d_numerical"] + len(d["categories"]) + h = torch.randn(d["batch_size"], seq_len, d["d_token"]) + x_num, x_cat = r(h) + loss = x_num.sum() + sum(c.sum() for c in x_cat) + loss.backward() + assert r.weight.grad is not None and r.weight.grad.abs().sum() > 0 + for recon in r.cat_recons: + assert recon.weight.grad is not None diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_tokenizer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_tokenizer.py new file mode 100644 index 0000000000000000000000000000000000000000..ea8c55737d473605c2bb1c87f0394fad64baeb18 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_tokenizer.py @@ -0,0 +1,85 @@ +import torch +import numpy as np + + +def test_forward_shape_mixed(make_tokenizer, make_dummy_inputs, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"]) + x_num, x_cat_oh, _, _ = make_dummy_inputs(dims["d_numerical"], dims["categories"], dims["batch_size"]) + out = tok(x_num, x_cat_oh) + expected_seq = 1 + dims["d_numerical"] + len(dims["categories"]) + assert out.shape == (dims["batch_size"], expected_seq, dims["d_token"]) + + +def test_forward_shape_numerical_only(make_tokenizer, make_dummy_inputs, dims_numerical_only): + d = dims_numerical_only + tok = make_tokenizer(d["d_numerical"], d["categories"], d["d_token"]) + x_num, _, _, _ = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + out = tok(x_num, None) + expected_seq = 1 + d["d_numerical"] + assert out.shape == (d["batch_size"], expected_seq, d["d_token"]) + + +def test_forward_shape_single_feature(make_tokenizer, make_dummy_inputs, dims_single): + d = dims_single + tok = make_tokenizer(d["d_numerical"], d["categories"], d["d_token"]) + x_num, x_cat_oh, _, _ = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + out = tok(x_num, x_cat_oh) + expected_seq = 1 + d["d_numerical"] + len(d["categories"]) + assert out.shape == (d["batch_size"], expected_seq, d["d_token"]) + + +def test_n_tokens_property(make_tokenizer, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"]) + expected = dims["d_numerical"] + 1 + len(dims["categories"]) + assert tok.n_tokens == expected + + +def test_n_tokens_numerical_only(make_tokenizer, dims_numerical_only): + d = dims_numerical_only + tok = make_tokenizer(d["d_numerical"], d["categories"], d["d_token"]) + assert tok.n_tokens == d["d_numerical"] + 1 + + +def test_cls_token_position(make_tokenizer, make_dummy_inputs, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"], bias=False) + x_num, x_cat_oh, _, _ = make_dummy_inputs(dims["d_numerical"], dims["categories"], dims["batch_size"]) + out = tok(x_num, x_cat_oh) + # CLS token: ones * weight[0], so all batch rows should have the same CLS token + cls_tokens = out[:, 0, :] + assert torch.allclose(cls_tokens[0], cls_tokens[1]) + assert torch.allclose(cls_tokens[0], tok.weight[0]) + + +def test_bias_vs_no_bias(make_tokenizer, make_dummy_inputs, dims): + d = dims + tok_bias = make_tokenizer(d["d_numerical"], d["categories"], d["d_token"], bias=True) + tok_no_bias = make_tokenizer(d["d_numerical"], d["categories"], d["d_token"], bias=False) + assert tok_bias.bias is not None + assert tok_no_bias.bias is None + + +def test_category_offsets_values(make_tokenizer): + cats = np.array([3, 5, 2]) + tok = make_tokenizer(4, cats, 16) + assert torch.equal(tok.category_offsets, torch.tensor([0, 3, 8])) + assert torch.equal(tok.category_ends, torch.tensor([3, 8, 10])) + + +def test_cat_weight_shape(make_tokenizer, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"]) + assert tok.cat_weight.shape == (sum(dims["categories"]), dims["d_token"]) + + +def test_weight_shape(make_tokenizer, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"]) + assert tok.weight.shape == (dims["d_numerical"] + 1, dims["d_token"]) + + +def test_gradient_flows(make_tokenizer, make_dummy_inputs, dims): + tok = make_tokenizer(dims["d_numerical"], dims["categories"], dims["d_token"]) + x_num, x_cat_oh, _, _ = make_dummy_inputs(dims["d_numerical"], dims["categories"], dims["batch_size"]) + out = tok(x_num, x_cat_oh) + out.sum().backward() + assert tok.weight.grad is not None and tok.weight.grad.abs().sum() > 0 + assert tok.cat_weight.grad is not None and tok.cat_weight.grad.abs().sum() > 0 + assert tok.bias.grad is not None and tok.bias.grad.abs().sum() > 0 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_trainer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_trainer.py new file mode 100644 index 0000000000000000000000000000000000000000..592c538d2aa1f8f34098a0d7c6c4fc0b1f0c5ddf --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_trainer.py @@ -0,0 +1,98 @@ +import torch +import numpy as np + + +# ---- Gradient clipping tests ---- + +def test_grad_clipping_applied(make_trainer, tmp_path): + trainer = make_trainer(max_grad_norm=0.5, tmp_path=tmp_path) + batch = next(iter(trainer.train_iter)) + trainer._run_step(batch, closs_weight=1.0, dloss_weight=1.0) + # After clipping, total gradient norm should be <= max_grad_norm (with tolerance) + total_norm = torch.nn.utils.clip_grad_norm_(trainer.flow.parameters(), float('inf')) + # Gradients were already clipped in _run_step, then optimizer.step() zeroed them. + # So we re-run to check: do a fresh forward-backward without step + trainer.optimizer.zero_grad() + dloss, closs = trainer.flow.mixed_loss(batch.to(trainer.device)) + (dloss + closs).backward() + torch.nn.utils.clip_grad_norm_(trainer.flow.parameters(), 0.5) + total_norm = 0.0 + for p in trainer.flow.parameters(): + if p.grad is not None: + total_norm += p.grad.data.norm(2).item() ** 2 + total_norm = total_norm ** 0.5 + assert total_norm <= 0.5 + 1e-6 + + +def test_grad_clipping_disabled(make_trainer, tmp_path): + trainer = make_trainer(max_grad_norm=0, tmp_path=tmp_path) + assert trainer.max_grad_norm == 0 + + +def test_run_step_returns_losses(make_trainer, tmp_path): + trainer = make_trainer(tmp_path=tmp_path) + batch = next(iter(trainer.train_iter)) + dloss, closs = trainer._run_step(batch, closs_weight=1.0, dloss_weight=1.0) + assert isinstance(dloss, torch.Tensor) + assert isinstance(closs, torch.Tensor) + assert torch.isfinite(dloss) + assert torch.isfinite(closs) + + +# ---- LR warmup tests ---- + +def test_warmup_lr_linear_ramp(make_trainer, tmp_path): + init_lr = 0.01 + warmup = 5 + trainer = make_trainer(lr=init_lr, warmup_epochs=warmup, tmp_path=tmp_path) + # Simulate warmup epochs + for epoch in range(warmup): + expected_lr = init_lr * (epoch + 1) / warmup + if trainer.warmup_epochs > 0 and (epoch + 1) <= trainer.warmup_epochs: + warmup_lr = trainer.init_lr * (epoch + 1) / trainer.warmup_epochs + for pg in trainer.optimizer.param_groups: + pg["lr"] = warmup_lr + actual_lr = trainer.optimizer.param_groups[0]["lr"] + assert abs(actual_lr - expected_lr) < 1e-8, f"Epoch {epoch}: expected {expected_lr}, got {actual_lr}" + + +def test_warmup_overrides_scheduler(make_trainer, tmp_path): + trainer = make_trainer(warmup_epochs=10, lr_scheduler='reduce_lr_on_plateau', tmp_path=tmp_path) + initial_lr = trainer.optimizer.param_groups[0]["lr"] + # During warmup, scheduler.step should NOT be called (we just set LR directly) + # Simulate epoch 1 warmup + warmup_lr = trainer.init_lr * 1 / trainer.warmup_epochs + for pg in trainer.optimizer.param_groups: + pg["lr"] = warmup_lr + assert trainer.optimizer.param_groups[0]["lr"] == warmup_lr + assert warmup_lr < initial_lr # warmup starts lower + + +def test_no_warmup_when_zero(make_trainer, tmp_path): + trainer = make_trainer(warmup_epochs=0, tmp_path=tmp_path) + assert trainer.warmup_epochs == 0 + # LR should be the init_lr from the start + assert trainer.optimizer.param_groups[0]["lr"] == trainer.init_lr + + +# ---- LR scheduler tests ---- + +def test_anneal_lr(make_trainer, tmp_path): + trainer = make_trainer(lr=0.01, steps=100, lr_scheduler='anneal', tmp_path=tmp_path) + trainer._anneal_lr(50) + expected = 0.01 * (1 - 50 / 100) + assert abs(trainer.optimizer.param_groups[0]["lr"] - expected) < 1e-8 + + +# ---- EMA tests ---- + +def test_ema_model_created(make_trainer, tmp_path): + trainer = make_trainer(tmp_path=tmp_path) + # EMA model should exist and have same structure as flow._vf_fn + assert trainer.ema_model is not None + ema_params = list(trainer.ema_model.parameters()) + model_params = list(trainer.flow._vf_fn.parameters()) + assert len(ema_params) == len(model_params) + # EMA params should be detached (requires_grad=False) + for p in ema_params: + assert not p.requires_grad diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_transformer.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ff56e884615e818841fbb912f8ef4e9961729197 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_transformer.py @@ -0,0 +1,73 @@ +import pytest +import torch +from ef_vfm.modules.transformer import Transformer + + +def test_output_shape_preserved(make_transformer): + t = make_transformer(d_token=16, n_layers=2) + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_activation_gelu(make_transformer): + t = make_transformer(d_token=16, activation='gelu') + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_activation_silu(make_transformer): + t = make_transformer(d_token=16, activation='silu') + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_activation_relu(make_transformer): + t = make_transformer(d_token=16, activation='relu') + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_invalid_activation_raises(): + with pytest.raises(ValueError, match="Unknown activation"): + Transformer(2, 16, 1, 16, 4, activation='bad') + + +def test_prenorm_first_layer_no_norm0(): + t = Transformer(2, 16, 1, 16, 4, prenormalization=True) + assert 'norm0' not in t.layers[0] + # Second layer should have norm0 + assert 'norm0' in t.layers[1] + + +def test_no_prenorm_all_layers_have_norm0(): + t = Transformer(2, 16, 1, 16, 4, prenormalization=False) + for layer in t.layers: + assert 'norm0' in layer + + +def test_single_layer(): + t = Transformer(1, 16, 1, 16, 4) + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_multi_layer(): + t = Transformer(4, 16, 1, 16, 4) + x = torch.randn(4, 5, 16) + out = t(x) + assert out.shape == x.shape + + +def test_gradient_flows(make_transformer): + t = make_transformer(d_token=16, n_layers=2) + x = torch.randn(4, 5, 16, requires_grad=True) + out = t(x) + out.sum().backward() + assert x.grad is not None and x.grad.abs().sum() > 0 + # Check gradients through at least the first layer's linear0 + assert t.layers[0]['linear0'].weight.grad is not None diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_unimodmlp.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_unimodmlp.py new file mode 100644 index 0000000000000000000000000000000000000000..d935e7c48dba78fd7e4821287628aa861aa6d1b4 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_unimodmlp.py @@ -0,0 +1,72 @@ +import torch +import numpy as np + + +def test_forward_shapes_mixed(make_unimodmlp, make_dummy_inputs, dims): + d = dims + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + x_num, x_cat_oh, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num_pred, x_cat_pred = model(x_num, x_cat_oh, t) + assert x_num_pred.shape == (d["batch_size"], d["d_numerical"]) + assert x_cat_pred.shape == (d["batch_size"], sum(d["categories"])) + + +def test_forward_shapes_numerical_only(make_unimodmlp, make_dummy_inputs, dims_numerical_only): + d = dims_numerical_only + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + x_num, _, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_cat = torch.zeros(d["batch_size"], 0) + x_num_pred, x_cat_pred = model(x_num, x_cat, t) + assert x_num_pred.shape == (d["batch_size"], d["d_numerical"]) + # When no categories, cat_pred should be zeros with shape matching x_cat + assert x_cat_pred.shape[0] == d["batch_size"] + assert torch.all(x_cat_pred == 0) + + +def test_forward_shapes_single_feature(make_unimodmlp, make_dummy_inputs, dims_single): + d = dims_single + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + x_num, x_cat_oh, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num_pred, x_cat_pred = model(x_num, x_cat_oh, t) + assert x_num_pred.shape == (d["batch_size"], d["d_numerical"]) + assert x_cat_pred.shape == (d["batch_size"], sum(d["categories"])) + + +def test_d_in_computation(make_unimodmlp, dims): + d = dims + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + expected = d["d_token"] * (d["d_numerical"] + len(d["categories"])) + assert model.mlp.proj.in_features == expected + + +def test_output_dtypes(make_unimodmlp, make_dummy_inputs, dims): + d = dims + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + x_num, x_cat_oh, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num_pred, x_cat_pred = model(x_num, x_cat_oh, t) + assert x_num_pred.dtype == torch.float32 + assert x_cat_pred.dtype == torch.float32 + + +def test_gradient_flows_end_to_end(make_unimodmlp, make_dummy_inputs, dims): + d = dims + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"]) + x_num, x_cat_oh, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + x_num_pred, x_cat_pred = model(x_num, x_cat_oh, t) + loss = x_num_pred.sum() + x_cat_pred.sum() + loss.backward() + params_with_grad = sum(1 for p in model.parameters() if p.grad is not None and p.grad.abs().sum() > 0) + total_params = sum(1 for _ in model.parameters()) + # Transformer.head is defined but unused in forward(), so not all params get gradients + assert params_with_grad > total_params * 0.8, f"Only {params_with_grad}/{total_params} params got gradients" + + +def test_different_activations(make_unimodmlp, make_dummy_inputs, dims): + d = dims + x_num, x_cat_oh, _, t = make_dummy_inputs(d["d_numerical"], d["categories"], d["batch_size"]) + for act in ['relu', 'gelu', 'silu']: + model = make_unimodmlp(d["d_numerical"], d["categories"], d_token=d["d_token"], activation=act) + x_num_pred, x_cat_pred = model(x_num, x_cat_oh, t) + assert x_num_pred.shape == (d["batch_size"], d["d_numerical"]) + assert torch.isfinite(x_num_pred).all() + assert torch.isfinite(x_cat_pred).all() diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_utils.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_utils.py new file mode 100644 index 0000000000000000000000000000000000000000..fbce0db0ac74052a4038dee89fd753b9d97717aa --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/tests/test_utils.py @@ -0,0 +1,49 @@ +import torch +import numpy as np + +from utils_train import update_ema, concat_y_to_X + + +# ---- update_ema tests ---- + +def test_update_ema_basic(): + target = [torch.tensor([1.0, 2.0])] + source = [torch.tensor([3.0, 4.0])] + target[0].requires_grad_(False) + rate = 0.9 + update_ema(target, source, rate=rate) + expected = 0.9 * torch.tensor([1.0, 2.0]) + 0.1 * torch.tensor([3.0, 4.0]) + assert torch.allclose(target[0], expected) + + +def test_update_ema_rate_zero(): + target = [torch.tensor([1.0, 2.0])] + source = [torch.tensor([3.0, 4.0])] + target[0].requires_grad_(False) + update_ema(target, source, rate=0.0) + assert torch.allclose(target[0], torch.tensor([3.0, 4.0])) + + +def test_update_ema_rate_one(): + target = [torch.tensor([1.0, 2.0])] + source = [torch.tensor([3.0, 4.0])] + target[0].requires_grad_(False) + update_ema(target, source, rate=1.0) + assert torch.allclose(target[0], torch.tensor([1.0, 2.0])) + + +# ---- concat_y_to_X tests ---- + +def test_concat_y_to_X_with_X(): + X = np.array([[1, 2], [3, 4]]) + y = np.array([10, 20]) + result = concat_y_to_X(X, y) + expected = np.array([[10, 1, 2], [20, 3, 4]]) + np.testing.assert_array_equal(result, expected) + + +def test_concat_y_to_X_without_X(): + y = np.array([10, 20, 30]) + result = concat_y_to_X(None, y) + expected = np.array([[10], [20], [30]]) + np.testing.assert_array_equal(result, expected) diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/utils_train.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/utils_train.py new file mode 100644 index 0000000000000000000000000000000000000000..f00c40d190a763f011526ef4aa11e5e960ce2b7b --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime/utils_train.py @@ -0,0 +1,183 @@ +import numpy as np +import os + +import src +from torch.utils.data import Dataset + +import torch + + +class TabularDataset(Dataset): + def __init__(self, X_num, X_cat): + self.X_num = X_num + self.X_cat = X_cat + + def __getitem__(self, index): + this_num = self.X_num[index] + this_cat = self.X_cat[index] + + sample = (this_num, this_cat) + + return sample + + def __len__(self): + return self.X_num.shape[0] + +class EFVFMDataset(Dataset): + def __init__(self, dataname, data_dir, info, isTrain=True, dequant_dist='none', int_dequant_factor=0.0): + self.dataname = dataname + self.data_dir = data_dir + self.info = info + self.isTrain = isTrain + + X_num, X_cat, categories, d_numerical, num_inverse, int_inverse, cat_inverse = preprocess(data_dir, dequant_dist, int_dequant_factor, task_type = info['task_type'], inverse=True) + categories = np.array(categories) + + X_train_num, _ = X_num + X_train_cat, _ = X_cat + + X_train_num, X_test_num = X_num + X_train_cat, X_test_cat = X_cat + + X_train_num, X_test_num = torch.tensor(X_train_num).float(), torch.tensor(X_test_num).float() + X_train_cat, X_test_cat = torch.tensor(X_train_cat), torch.tensor(X_test_cat) + + self.X = torch.cat((X_train_num, X_train_cat), dim=1) if isTrain else torch.cat((X_test_num, X_test_cat), dim=1) + self.num_inverse = num_inverse + self.int_inverse = int_inverse + self.cat_inverse = cat_inverse + self.d_numerical = d_numerical + self.categories = categories + + def __getitem__(self, index): + return self.X[index] + + def __len__(self): + return self.X.shape[0] + +def preprocess(dataset_path, dequant_dist='none', int_dequant_factor=0.0, task_type = 'binclass', inverse = False, cat_encoding = None, concat = True): + + T_dict = {} + + T_dict['normalization'] = "quantile" + T_dict['num_nan_policy'] = 'mean' + T_dict['cat_nan_policy'] = None + T_dict['cat_min_frequency'] = None + T_dict['cat_encoding'] = cat_encoding + T_dict['y_policy'] = "default" + T_dict['dequant_dist'] = dequant_dist + T_dict['int_dequant_factor'] = int_dequant_factor + + T = src.Transformations(**T_dict) + + dataset = make_dataset( + data_path = dataset_path, + T = T, + task_type = task_type, + change_val = False, + concat = concat, + ) + + if cat_encoding is None: + X_num = dataset.X_num + X_cat = dataset.X_cat + + X_train_num, X_test_num = X_num['train'], X_num['test'] + X_train_cat, X_test_cat = X_cat['train'], X_cat['test'] + + categories = src.get_categories(X_train_cat) + d_numerical = X_train_num.shape[1] + + X_num = (X_train_num, X_test_num) + X_cat = (X_train_cat, X_test_cat) + + + if inverse: + num_inverse = dataset.num_transform.inverse_transform if dataset.num_transform is not None else lambda x: x + int_inverse = dataset.int_transform.inverse_transform if dataset.int_transform is not None else lambda x: x + cat_inverse = dataset.cat_transform.inverse_transform if dataset.cat_transform is not None else lambda x: x + + return X_num, X_cat, categories, d_numerical, num_inverse, int_inverse, cat_inverse + else: + return X_num, X_cat, categories, d_numerical + else: + return dataset + + +def update_ema(target_params, source_params, rate=0.999): + """ + Update target parameters to be closer to those of source parameters using + an exponential moving average. + :param target_params: the target parameter sequence. + :param source_params: the source parameter sequence. + :param rate: the EMA rate (closer to 1 means slower). + """ + for target, source in zip(target_params, source_params): + target.detach().mul_(rate).add_(source.detach(), alpha=1 - rate) + + + +def concat_y_to_X(X, y): + if X is None: + return y.reshape(-1, 1) + return np.concatenate([y.reshape(-1, 1), X], axis=1) + + +def make_dataset( + data_path: str, + T: src.Transformations, + task_type, + change_val: bool, + concat = True, +): + + # classification + if task_type == 'binclass' or task_type == 'multiclass': + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) else None + y = {} if os.path.exists(os.path.join(data_path, 'y_train.npy')) else None + + for split in ['train', 'test']: + X_num_t, X_cat_t, y_t = src.read_pure_data(data_path, split) + if X_num is not None: + X_num[split] = X_num_t + if X_cat is not None: + if concat: + X_cat_t = concat_y_to_X(X_cat_t, y_t) + X_cat[split] = X_cat_t + if y is not None: + y[split] = y_t + else: + # regression + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) else None + y = {} if os.path.exists(os.path.join(data_path, 'y_train.npy')) else None + + for split in ['train', 'test']: + X_num_t, X_cat_t, y_t = src.read_pure_data(data_path, split) + if X_num is not None: + if concat: + X_num_t = concat_y_to_X(X_num_t, y_t) + X_num[split] = X_num_t + if X_cat is not None: + X_cat[split] = X_cat_t + if y is not None: + y[split] = y_t + + info = src.load_json(os.path.join(data_path, 'info.json')) + int_col_idx_wrt_num = info['int_col_idx_wrt_num'] + + D = src.Dataset( + X_num, + X_cat, + y, + int_col_idx_wrt_num, + y_info={}, + task_type=src.TaskType(info['task_type']), + n_classes=info.get('n_classes') + ) + + if change_val: + D = src.change_val(D) + + return src.transform_dataset(D, T, None) \ No newline at end of file diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_tabbyflow_train.py b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_tabbyflow_train.py new file mode 100644 index 0000000000000000000000000000000000000000..0f71e7e26b917e9c85c74a0f3487c1ca2cf4e532 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/_tabbyflow_train.py @@ -0,0 +1,33 @@ + +import os, shutil, subprocess, sys +root = r"/workspace/ef-vfm" +rt = r"/work/output-Benchmark-trainonly-v1/c12/tabbyflow/tabbyflow-c12-20260510_225304/_efvfm_runtime" +name = r"pipeline_c12" +src = r"/work/output-Benchmark-trainonly-v1/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12" + +shutil.rmtree(rt, ignore_errors=True) + +def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + +shutil.copytree(root, rt, ignore=_ignore) +dst_data = os.path.join(rt, "data", name) +dst_syn = os.path.join(rt, "synthetic", name) +shutil.rmtree(dst_data, ignore_errors=True) +os.makedirs(os.path.dirname(dst_data), exist_ok=True) +shutil.copytree(src, dst_data) +os.makedirs(dst_syn, exist_ok=True) +for fn in ("real.csv", "test.csv", "val.csv"): + shutil.copy(os.path.join(src, fn), os.path.join(dst_syn, fn)) +os.chdir(rt) +os.environ["PYTHONPATH"] = rt + os.pathsep + os.environ.get("PYTHONPATH", "") +os.environ["EFVFM_SMOKE_STEPS"] = "100" +os.environ["EFVFM_ADAPTER_TRAIN"] = "1" +os.environ.setdefault("EFVFM_SAMPLE_BATCH_SIZE", "128") +os.environ.setdefault("EFVFM_EVAL_NUM_SAMPLES", "512") +subprocess.check_call([ + sys.executable, os.path.join(rt, "main.py"), + "--dataname", name, "--mode", "train", "--gpu", "0", + "--no_wandb", "--exp_name", r"adapter_efvfm", +]) diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/input_snapshot.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..0c7d30badbd79a76b4ef81ae85223937a633fdc7 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f68eb9a6651fbc508c341f8b7104a8a8219522e55e0b0b38f051dbeadd68b0cc +size 1369 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/public_gate_report.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..01a3352609ac3fa673fd2be12baa6367058a5cb6 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dcd2f40e387e53cd33bfd5c338a2ad22446c20b06b9fb4e7e0826d3715fa5c5b +size 658455 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/run_config.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..647b92bd76ac3c375c99c29c95da6b42a609be0b --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:826bf5b974531c5b46cb3c5c14d046540943453d7be3614475be83e45f975a49 +size 1825 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/runtime_result.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..72b73506b25f339a878944fe2331d41b7b8e9294 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9eef0931e594615be5840b880ee66986486dc1e277d9d1f872589fc1a7595e54 +size 1109 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/staged_features.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/test.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/train.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/val.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_report.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..51112761ff46868db5a5fa25bad26437ee76c358 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0e84634b762cefdf1eb04261a651ffb4d1e012cacd2d3ccc90e46ccfc1dc0b93 +size 329 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_transforms_applied.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/model_input_manifest.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..48aa553b43717a5eea24b2c9a1828c046171c215 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/staged/tabbyflow/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c9986e096077a133f01884812719bee21d90e33671d8b944a85af254efe50ff1 +size 658660 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..3e4e5bb742d8d0c5497ec4ec864f1f3d595a7a55 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5160adcfd7a3dae2c17b5f31ba22d95318143f8ac4060711377a03f5431e38a +size 4092888 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..f3747fcd7e942d6ed4b2fa3bc9000043ea2ed0bb --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2afe152298b9b50f482d85dae554b6e35d6e98e43a32bbbafa4bb90d8770aea9 +size 32630248 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..89d8521e13cfe324582788e159a80b911f23630e --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_cat_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cd6b9e6e1227d5c8d6bec250b01723d86289999b2941b93efacc0b077fe4d6ae +size 4068008 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..e024771b21afd3380f7909bc4a008c3d4990fc09 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:300d9dfe9e44f5c06842165d657a72abbe126f90ef97854177e63ca429686468 +size 4076 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..624924ae67ad4e3ac474ef42f0a8455ded2eeb1e --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df2f44047e580945b1b5b7564af9fb585edd796a433a013d355aaac6a4897a4e +size 31604 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..634ed815e1441e488b5e2976bf8206ae5e93fdbf --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/X_num_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f6ff5229f67a68378f1ac2ddf0cbf9d6bcd9ac35aff540e8d7434418a119f075 +size 4052 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/info.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/info.json new file mode 100644 index 0000000000000000000000000000000000000000..b7885431320aa7b2b9480542436bf05d5417d8cc --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c7e4b1ec5600b398fb81dc17fe173571e8c31ccb75bc7a71a115b049c083b72a +size 239660 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/real.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/real.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/real.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/staged_features.json b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/test.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/train.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/val.csv b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_test.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..ead69000308d740029106af368f28be74e4a4984 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0827ebc8f8dfce84f28bfed2e70fc2736d3d5ef9489400232a27ad8de35a9e11 +size 2760 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_train.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_val.npy b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..6ecd5a37945d502473b0b23292f01d52b03957d6 --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/tabular_bundle/pipeline_c12/y_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2405e82f954de2d2909d0f30c075b2481e20ed9963101c4c0fafa1539271e127 +size 2744 diff --git a/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/train_20260510_225319.log b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/train_20260510_225319.log new file mode 100644 index 0000000000000000000000000000000000000000..6437cc519cff7e1ba57bc953c5a541b095c4c03f --- /dev/null +++ b/syntheticFail/c12/tabbyflow/tabbyflow-c12-20260510_225304/train_20260510_225319.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c993fc0eb1f777ff01b160ab0caa87ea2b493b9d0a8c7f566e4b45c5e06f87fa +size 29820 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/_tabddpm_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/_tabddpm_train.py new file mode 100644 index 0000000000000000000000000000000000000000..eed204b4459146e2d5901ef01847e59455d26eb9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/_tabddpm_train.py @@ -0,0 +1,32 @@ +import os, sys, subprocess + +tabddpm_root = "/workspace/tabddpm/code" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" +env = os.environ.copy() +env["PYTHONPATH"] = tabddpm_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Write a wrapper that patches collections.Sequence (removed in Python 3.10+) +# before running pipeline.py - needed because skorch uses old API +wrapper = os.path.join(tabddpm_root, "_compat_run.py") +with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Training, config=/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_215510/config.toml") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_215510/config.toml", + "--train"], + cwd=tabddpm_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) +print("[TabDDPM] Training complete") diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..775c550bb0b9572f4d7e181d8c3e1a9917a9aed4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:776a970f3b2271b4a594e39385183b7326d7b3030c777cea016d9c3d04eee482 +size 773 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_cat_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_num_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d81ab6d13ff8932c1b47822a5508c046d9fd6f6b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce0d1648e7f4633f3c9aa6e2f8c5460ec86f01d4bfa155e977a71e9640744427 +size 51619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/y_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/data/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/input_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..ea0c7955c35965e09281e7ad72e7f9722a3d793b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:754197615fcbb84d31c0a54a0fd62ded7a78578807874b50d4c73f62b7e80ef5 +size 1367 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/public_gate_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..dc64f717b6c1c70425294c502a1fdff82a3efe52 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b68c35fd5211f5ed379a93426e592c574c721799e345a3ef4f586b12464bfeeb +size 658435 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/run_config.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..87491f3165ce0681d66ddf7a1c5f27c9b59187eb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:054b39c732b40b605bc901421ecce80ce8a92f2e5f6d2618fc98c16c2c7f0238 +size 1905 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/runtime_result.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..7afaa63c5988c48aaa60e507b4ad867ff9b98089 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:65c40376e4a786d469865c511e0feafabe73d245b9ff3dd4873247a7ef31d3b0 +size 1057 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/staged_features.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/test.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/train.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/val.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..20942864401f02588eba42182fc9bc9f6841261e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46ed9828cedd4fa149f9ebcdbe19295342be343991ff6f06b6b20165f1f0c890 +size 323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_transforms_applied.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/model_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..4df1dc9b8d4a0be39b2d602a5d66294b7be395e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/staged/tabddpm/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0cbe928562ef4f87ea8e73994e17cfec824316324d48b30a339bcf0c433f738c +size 658634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/train_20260510_215517.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/train_20260510_215517.log new file mode 100644 index 0000000000000000000000000000000000000000..b2f45ddb669b789312b03af21f61f959cb49491f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_215510/train_20260510_215517.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e68ee8210bd6deed229031aafab945d0c07e0a3b3d8af6fc776643b2cbdb5f4f +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/._data b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/._data new file mode 100755 index 0000000000000000000000000000000000000000..89e52d9d55eea94a37ca2bfdd186b4b892b24643 Binary files /dev/null and b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/._data differ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..9b148cde6e315b01b30652b19f39a11f211dff1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitignore @@ -0,0 +1,22 @@ +.DS_Store +__pycache__/ +catboost_info/ +**/**.pt +**/**.ipynb +!agg_results.ipynb +**/**.npy +**/**.gz +**/**.sh +**/**.obj +**/**.png +**/**.tar +**/**.code-workspace +**/**.csv +exp/**/**/results_catboost.json +exp/**/**/results_mlp.json + +configs/ +data/ +junk/ +RF/ +exps/ \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitmodules b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitmodules new file mode 100644 index 0000000000000000000000000000000000000000..8c677ab737cbbdbc5c806cf58d27960efefcb11a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/.gitmodules @@ -0,0 +1,9 @@ +[submodule "ctgan"] + # path = CTGAN/CTGAN + url = https://github.com/sdv-dev/CTGAN +[submodule "ctabgan"] + # path = CTAB-GAN + url = https://github.com/Team-TUD/CTAB-GAN +[submodule "ctabgan+"] + # path = CTAB-GAN-Plus + url = https://github.com/Team-TUD/CTAB-GAN-Plus \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CONFIG_DESCRIPTION.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CONFIG_DESCRIPTION.md new file mode 100644 index 0000000000000000000000000000000000000000..646a0c00f329b55bc736d5cdbd1e797d1143cd1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CONFIG_DESCRIPTION.md @@ -0,0 +1,78 @@ +# Description of .toml config for TabDDPM +First of all, `train.T` and `eval.T` denote preprocessing for training and for evaluation, respectively. + +Here we list non-obvious parameters. + +Main part: +- `seed = 0` -- evaluation seed (and training, but for training it is fixed to 0) +- `parent_dir = "exp/abalone/check"` -- exp folder +- `real_data_path = "data/abalone/"` +- `model_type = "mlp"` -- model type that approximates the reverse process +- `num_numerical_features ` -- a number of numerical features in dataset +- `device = "cuda:0"` + +Model params: +- `is_y_cond` -- false for regression, true for classification +- `d_in` -- input dimension (not necessary, since scripts calculate it automatically) +- `num_calsses` -- zero for regression, a number of classes for classification +- `rtdl_params` -- MLP parameters + +```toml +seed = 0 +parent_dir = "exp/abalone/check" +real_data_path = "data/abalone/" +model_type = "mlp" +num_numerical_features = 7 +device = "cuda:0" + +[model_params] +is_y_cond = false +d_in = 11 +num_classes = 0 + +[model_params.rtdl_params] +d_layers = [ + 256, + 256, +] +dropout = 0.0 + +[diffusion_params] +num_timesteps = 1000 +gaussian_loss_type = "mse" +scheduler = "cosine" + +[train.main] +steps = 1000 +lr = 0.001 +weight_decay = 1e-05 +batch_size = 4096 + +[train.T] +seed = 0 +normalization = "quantile" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +[sample] +num_samples = 20800 +batch_size = 10000 +seed = 0 + +[eval.type] +eval_model = "catboost" +eval_type = "synthetic" + +[eval.T] +seed = 0 +normalization = "__none__" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/README.md new file mode 100644 index 0000000000000000000000000000000000000000..e873924cc56b6603669d17e6ab3badd4aba0657a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/README.md @@ -0,0 +1,49 @@ +# CTAB-GAN+ +This is the official git paper [CTAB-GAN+: Enhancing Tabular Data Synthesis](https://arxiv.org/abs/2204.00401). Current code is without differential privacy part. +If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` +The sklean package in newer version has updated its function for `sklearn.mixture.BayesianGaussianMixture`. Therefore, user should use this proposed sklearn version to successfully run the code! + +## Example +`Experiment_Script_Adult.ipynb` `Experiment_Script_king.ipynb` are two example notebooks for training CTAB-GAN+ with Adult (classification) and king (regression) datasets. The datasets are alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## Problem type + +You can either indicate your dataset problem type as Classification, Regression. If there is no problem type, you can leave the problem type as None as follows: +``` +problem_type= {None: None} +``` + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN+ will wrap the encoded data into an image-like format. What you can do is changing the line 378 and 385 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@article{zhao2022ctab, + title={CTAB-GAN+: Enhancing Tabular Data Synthesis}, + author={Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y}, + journal={arXiv preprint arXiv:2204.00401}, + year={2022} +} +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..ac695958cb0fb057fa024d712d065588e43e5279 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0d9e05a1c251995561cb1f4b2688be2c332a4971a0513d15645089efc0e236a +size 4355 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..81782dcde9f07f3d8178c29ba08ceb129c40f58f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py @@ -0,0 +1,70 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + general_columns = ["age"], + non_categorical_columns = [], + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": "income"}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, seed=0): + + sample = self.synthesizer.sample(len(self.raw_df), seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..abe1f725f7d09f7284abef0dd9c1187f0e3c96bf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py @@ -0,0 +1,130 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..9fd6845ffaf8f3a991acceba92af143941e5c11f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,601 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 64] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 64] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=2e-4, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + while len(result) < n: + data_resample = [] + steps_left = resample// self.batch_size + 1 + + for i in range(steps_left): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a99b5d587da5f3e49b3923e43975e02e9c11e6e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py @@ -0,0 +1,72 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [], + log_columns = [], + mixed_columns= {}, + general_columns = [], + non_categorical_columns = [], + integer_columns = [], + problem_type= {}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + lr=lr, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..3f4b7293d63db51bc7c9da6c38b84c6c033d779b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py @@ -0,0 +1,131 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..521a29aff4e8db1d45c7c3be98d593892c65c8d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,605 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm, trange +import time + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + print(n) + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + t0 = time.time() + while len(result) < n and (time.time() - t0) <= 600: + data_resample = [] + steps_left = resample// sample_batch_size + 1 + # print(f"Sampling: {len(result)}/{n}") + for i in range(steps_left): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..a584f91844e866d04f3c59297ca66017f1e7dd6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py @@ -0,0 +1,81 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib +from model.ctabgan import CTABGAN + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..c1f668fe5b5d3d5255a3587982e968276e60273d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py @@ -0,0 +1,110 @@ +import lib +import os +import numpy as np +import argparse +from model.ctabgan import CTABGAN +from pathlib import Path +import torch +import pickle + + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..ed19426b03246e546e234a2501a7c06f173d9f03 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +from random import random +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + # steps = trial.suggest_categorical('steps', [1000]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan-plus/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan-plus/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan-plus/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan-plus", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..261eeb9e9f8b2b4b0d119366dda99c6fd7d35c64 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/License.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/License.txt new file mode 100644 index 0000000000000000000000000000000000000000..5404b6f9e08e11c3a28a214518830c963060c885 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/License.txt @@ -0,0 +1,15 @@ +Distributed learning systems Lab at TU Delft & Generatrix, hereby disclaims all copyright interest in the program "CTAB-GAN" (which synthesizes tabular data) + +Copyright 2020-2022 Distributed learning systems Lab at TU Delft & Generatrix. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + https://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..7fd4f2ac92abf9b244313a9ecf7d8328932cfc8c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/README.md @@ -0,0 +1,50 @@ +# CTAB-GAN +This is the official git paper [CTAB-GAN: Effective Table Data Synthesizing](https://proceedings.mlr.press/v157/zhao21a.html). The paper is published on Asian Conference on Machine Learning (ACML 2021), please check our pdf on PMLR website for our newest version of [paper](https://proceedings.mlr.press/v157/zhao21a.html), it adds more content on time consumption analysis of training CTAB-GAN. If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` + +## Example +`Experiment_Script_Adult.ipynb` is an example notebook for training CTAB-GAN with Adult dataset. The dataset is alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN will wrap the encoded data into an image-like format. What you can do is changing the line 341 and 348 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@InProceedings{zhao21, + title = {CTAB-GAN: Effective Table Data Synthesizing}, + author = {Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y.}, + booktitle = {Proceedings of The 13th Asian Conference on Machine Learning}, + pages = {97--112}, + year = {2021}, + editor = {Balasubramanian, Vineeth N. and Tsang, Ivor}, + volume = {157}, + series = {Proceedings of Machine Learning Research}, + month = {17--19 Nov}, + publisher = {PMLR}, + pdf = {https://proceedings.mlr.press/v157/zhao21a/zhao21a.pdf}, + url = {https://proceedings.mlr.press/v157/zhao21a.html} +} + + +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..5acd6bbcc72f8df4869e43a9e55e4dca4b32c616 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c59fb02cb7f4a153aecb9e18dd81bbbb6946e55c3e6928c748811fcf5a85ad79 +size 3179 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..d12c1a3c05d486c698bca7012d45bf31bc50ffbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py @@ -0,0 +1,58 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": 'income'}, + batch_size = 512, + class_dim = (256, 256, 256, 256), + lr = 2e-4, + epochs = 10, + device=None): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer(lr = lr, epochs = epochs, batch_size = batch_size, class_dim = class_dim, device = device) + self.raw_df = df + print(self.raw_df.shape) + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self, no_train=False): + print("-"*100) + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], + mixed = self.data_prep.column_types["mixed"],type=self.problem_type, no_train=no_train) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + print("-"*100) + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..2cc965efb802eac7263640e94ffba0cbdfff8c7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py @@ -0,0 +1,191 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(X_train_real) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..dec2dc9715af03ecabf6efb3cff333588e5aa25c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py @@ -0,0 +1,114 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.lower_bounds = {} + self.label_encoder_list = [] + + + target_col = list(type.values())[0] + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + X_train_real[target_col]= y_train_real + + self.df = X_train_real + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..7e4dd5cc2ecfb7c730b8cdab498c3cba332a318f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,526 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, BatchNorm2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + ed= st+output_info[tc][0] + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_D = [] + for prev, curr in zip(layer_dims, layer_dims[1:]): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + BatchNorm2d(curr[0]), + LeakyReLU(0.2, inplace=True) + ] + print() + layers_D += [ + + Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), + Sigmoid() + ] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_G = [ + ConvTranspose2d( + random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False) + ] + + for prev, curr in zip(reversed(layer_dims), reversed(layer_dims[:-1])): + layers_G += [ + BatchNorm2d(prev[0]), + ReLU(True), + ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True) + ] + return layers_G + + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + lr=2e-4, + class_dim=(256, 256, 256, 256), + random_dim=128, + num_channels=64, + l2scale=1e-5, + batch_size=1024, + epochs=1, + device=torch.device("cpu")): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = device + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, type={}, no_train=False): + print("Fit started.") + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed) + self.transformer.fit() + + train_data = self.transformer.transform(train_data.values) + + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + + if no_train: return + + print("Training started.") + for i in range(self.epochs): + # for _ in range(steps_per_epoch): + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + y_real,_ = discriminator(real_cat_d) + y_fake,_ = discriminator(fake_cat_d) + loss_d = (-(torch.log(y_real + 1e-4).mean()) - (torch.log(1. - y_fake + 1e-4).mean())) + loss_d.backward() + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + g = -(torch.log(y_fake + 1e-4).mean()) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + if (i + 1) % 500 == 0: + print(f"Step: {i}/{self.epochs} Loss: {loss_mean:.4f}") + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + # print(len(data)) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result = self.transformer.inverse_transform(data) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..18fc3c492a99c7f2455ebf2c2cddf09525333b92 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py @@ -0,0 +1,363 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + gm = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh'), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + data_t[:, id_] = tmp + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + return data_t + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..9ed3e80f4a226ec8e973f5f15db87540e4fa01a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..1144dbbc7b9c35690b609f5717d766abd4ba9567 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/requirements.txt @@ -0,0 +1,6 @@ +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..be74a48ec44624d341dda0f684780ac698ec3851 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py @@ -0,0 +1,108 @@ +import lib +import os +import numpy as np +import argparse +from pathlib import Path +from model.ctabgan import CTABGAN +import torch +import pickle + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1).values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..71e73f1edc23821ea1ea099a10095a6b1de032ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py @@ -0,0 +1,150 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig new file mode 100644 index 0000000000000000000000000000000000000000..8558c49851ee32e7577c83758bf92941054d2c5c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig @@ -0,0 +1,24 @@ +# http://editorconfig.org + +root = true + +[*] +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true +insert_final_newline = true +charset = utf-8 +end_of_line = lf + +[*.py] +max_line_length = 99 + +[*.bat] +indent_style = tab +end_of_line = crlf + +[LICENSE] +insert_final_newline = false + +[Makefile] +indent_style = tab diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS new file mode 100644 index 0000000000000000000000000000000000000000..e4db0356f3f62a8480ae07791b86c28adff16739 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS @@ -0,0 +1,2 @@ +# Global rule: +* @sdv-dev/core-contributors diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000000000000000000000000000000000000..16e0decde54dd915131ba85aa981029946dc53aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,33 @@ +--- +name: Bug report +about: Report an error that you found when using CTGAN +title: '' +labels: bug, pending review +assignees: '' + +--- + +### Environment Details + +Please indicate the following details about the environment in which you found the bug: + +* CTGAN version: +* Python version: +* Operating System: + +### Error Description + + + +### Steps to reproduce + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000000000000000000000000000000000000..54d7b6a17c3456c79fd59efaa5819d071e0101b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,24 @@ +--- +name: Feature request +about: Request a new feature that you would like to see implemented in CTGAN +title: '' +labels: new feature, pending review +assignees: '' + +--- + +### Problem Description + + + +### Expected behavior + + + +### Additional context + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md new file mode 100644 index 0000000000000000000000000000000000000000..20aca671d77560c3c52bd7d00ae129ca2f160f8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md @@ -0,0 +1,33 @@ +--- +name: Question +about: Doubts about CTGAN usage +title: '' +labels: question, pending review +assignees: '' + +--- + +### Environment details + +If you are already running CTGAN, please indicate the following details about the environment in +which you are running it: + +* CTGAN version: +* Python version: +* Operating System: + +### Problem description + + + +### What I already tried + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml new file mode 100644 index 0000000000000000000000000000000000000000..fdc744eeec5f5a1a18ce12ab91a8796f1c25d9fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml @@ -0,0 +1,31 @@ +name: Integration Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run integration tests + run: invoke integration diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml new file mode 100644 index 0000000000000000000000000000000000000000..07dde39e9f898c598379e9bd39dac1304be9456e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml @@ -0,0 +1,21 @@ +name: Style Checks + +on: + - push + - pull_request + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - name: Set up Python 3.8 + uses: actions/setup-python@v2 + with: + python-version: 3.8 + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[dev] + - name: Run lint checks + run: invoke lint diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml new file mode 100644 index 0000000000000000000000000000000000000000..1989c957943adecaf4e9fb851971e961c9188b3d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml @@ -0,0 +1,31 @@ +name: Unit Tests Minimum Versions + +on: + - push + - pull_request + +jobs: + minimum: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch==1.8' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision==0.9.0' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Test with minimum versions + run: invoke minimum diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml new file mode 100644 index 0000000000000000000000000000000000000000..5a623b543050f215dce8a6ba0d9aeecf2875b779 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml @@ -0,0 +1,25 @@ +name: Test README + +on: + - push + - pull_request + +jobs: + readme: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15] # skip windows bc rundoc fails + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke rundoc . + - name: Run the README.md + run: invoke readme diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml new file mode 100644 index 0000000000000000000000000000000000000000..6a63f0e006e1c8d3b635c441661c5ceb0282066b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml @@ -0,0 +1,34 @@ +name: Unit Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run unit tests + run: invoke unit + - if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.8 + name: Upload codecov report + uses: codecov/codecov-action@v2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..1609a70e22920b86a4a717e9c9aae645184b0831 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.gitignore @@ -0,0 +1,107 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +.hypothesis/ +.pytest_cache/ +tests/readme_test/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ +docs/api/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# SageMath parsed files +*.sage.py + +# dotenv +.env + +# virtualenv +.venv +venv/ +ENV/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ + +# Vim +.*.swp diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml new file mode 100644 index 0000000000000000000000000000000000000000..ecfa96045b11d59a33951d94e2358ea6b30646b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml @@ -0,0 +1,15 @@ +# Config file for automatic testing at travis-ci.org +dist: bionic +language: python +python: + - 3.8 + - 3.7 + - 3.6 + +# Command to install dependencies +install: pip install -U tox-travis codecov + +after_success: codecov + +# Command to run tests +script: tox diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst new file mode 100644 index 0000000000000000000000000000000000000000..1ea30d0908426597369b5193f52f1ec2b6ff4826 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst @@ -0,0 +1,13 @@ +Credits +======= + +Research and Development Lead +----------------------------- + +* Lei Xu + +Contributors +------------ + +* Carles Sala +* Kevin Kuo diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst new file mode 100644 index 0000000000000000000000000000000000000000..a21b70abaec7c75cf14208a5438d0af3dfac03b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst @@ -0,0 +1,237 @@ +.. highlight:: shell + +============ +Contributing +============ + +Contributions are welcome, and they are greatly appreciated! Every little bit +helps, and credit will always be given. + +You can contribute in many ways: + +Types of Contributions +---------------------- + +Report Bugs +~~~~~~~~~~~ + +Report bugs at the `GitHub Issues page`_. + +If you are reporting a bug, please include: + +* Your operating system name and version. +* Any details about your local setup that might be helpful in troubleshooting. +* Detailed steps to reproduce the bug. + +Fix Bugs +~~~~~~~~ + +Look through the GitHub issues for bugs. Anything tagged with "bug" and "help +wanted" is open to whoever wants to implement it. + +Implement Features +~~~~~~~~~~~~~~~~~~ + +Look through the GitHub issues for features. Anything tagged with "enhancement" +and "help wanted" is open to whoever wants to implement it. + +Write Documentation +~~~~~~~~~~~~~~~~~~~ + +CTGAN could always use more documentation, whether as part of the +official CTGAN docs, in docstrings, or even on the web in blog posts, +articles, and such. + +Submit Feedback +~~~~~~~~~~~~~~~ + +The best way to send feedback is to file an issue at the `GitHub Issues page`_. + +If you are proposing a feature: + +* Explain in detail how it would work. +* Keep the scope as narrow as possible, to make it easier to implement. +* Remember that this is a volunteer-driven project, and that contributions + are welcome :) + +Get Started! +------------ + +Ready to contribute? Here's how to set up `CTGAN` for local development. + +1. Fork the `CTGAN` repo on GitHub. +2. Clone your fork locally:: + + $ git clone git@github.com:your_name_here/CTGAN.git + +3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, + this is how you set up your fork for local development:: + + $ mkvirtualenv CTGAN + $ cd CTGAN/ + $ make install-develop + +4. Create a branch for local development:: + + $ git checkout -b name-of-your-bugfix-or-feature + + Try to use the naming scheme of prefixing your branch with ``gh-X`` where X is + the associated issue, such as ``gh-3-fix-foo-bug``. And if you are not + developing on your own fork, further prefix the branch with your GitHub + username, like ``githubusername/gh-3-fix-foo-bug``. + + Now you can make your changes locally. + +5. While hacking your changes, make sure to cover all your developments with the required + unit tests, and that none of the old tests fail as a consequence of your changes. + For this, make sure to run the tests suite and check the code coverage:: + + $ make lint # Check code styling + $ make test # Run the tests + $ make coverage # Get the coverage report + +6. When you're done making changes, check that your changes pass all the styling checks and + tests, including other Python supported versions, using:: + + $ make test-all + +7. Make also sure to include the necessary documentation in the code as docstrings following + the `Google docstrings style`_. + If you want to view how your documentation will look like when it is published, you can + generate and view the docs with this command:: + + $ make view-docs + +8. Commit your changes and push your branch to GitHub:: + + $ git add . + $ git commit -m "Your detailed description of your changes." + $ git push origin name-of-your-bugfix-or-feature + +9. Submit a pull request through the GitHub website. + +Pull Request Guidelines +----------------------- + +Before you submit a pull request, check that it meets these guidelines: + +1. It resolves an open GitHub Issue and contains its reference in the title or + the comment. If there is no associated issue, feel free to create one. +2. Whenever possible, it resolves only **one** issue. If your PR resolves more than + one issue, try to split it in more than one pull request. +3. The pull request should include unit tests that cover all the changed code +4. If the pull request adds functionality, the docs should be updated. Put + your new functionality into a function with a docstring, and add the + feature to the documentation in an appropriate place. +5. The pull request should work for all the supported Python versions. Check the `Travis Build + Status page`_ and make sure that all the checks pass. + +Unit Testing Guidelines +----------------------- + +All the Unit Tests should comply with the following requirements: + +1. Unit Tests should be based only in unittest and pytest modules. + +2. The tests that cover a module called ``ctgan/path/to/a_module.py`` + should be implemented in a separated module called + ``tests/ctgan/path/to/test_a_module.py``. + Note that the module name has the ``test_`` prefix and is located in a path similar + to the one of the tested module, just inside the ``tests`` folder. + +3. Each method of the tested module should have at least one associated test method, and + each test method should cover only **one** use case or scenario. + +4. Test case methods should start with the ``test_`` prefix and have descriptive names + that indicate which scenario they cover. + Names such as ``test_some_methed_input_none``, ``test_some_method_value_error`` or + ``test_some_method_timeout`` are right, but names like ``test_some_method_1``, + ``some_method`` or ``test_error`` are not. + +5. Each test should validate only what the code of the method being tested does, and not + cover the behavior of any third party package or tool being used, which is assumed to + work properly as far as it is being passed the right values. + +6. Any third party tool that may have any kind of random behavior, such as some Machine + Learning models, databases or Web APIs, will be mocked using the ``mock`` library, and + the only thing that will be tested is that our code passes the right values to them. + +7. Unit tests should not use anything from outside the test and the code being tested. This + includes not reading or writing to any file system or database, which will be properly + mocked. + +Tips +---- + +To run a subset of tests:: + + $ python -m pytest tests.test_ctgan + $ python -m pytest -k 'foo' + +Release Workflow +---------------- + +The process of releasing a new version involves several steps combining both ``git`` and +``bumpversion`` which, briefly: + +1. Merge what is in ``master`` branch into ``stable`` branch. +2. Update the version in ``setup.cfg``, ``ctgan/__init__.py`` and + ``HISTORY.md`` files. +3. Create a new git tag pointing at the corresponding commit in ``stable`` branch. +4. Merge the new commit from ``stable`` into ``master``. +5. Update the version in ``setup.cfg`` and ``ctgan/__init__.py`` + to open the next development iteration. + +.. note:: Before starting the process, make sure that ``HISTORY.md`` has been updated with a new + entry that explains the changes that will be included in the new version. + Normally this is just a list of the Pull Requests that have been merged to master + since the last release. + +Once this is done, run of the following commands: + +1. If you are releasing a patch version:: + + make release + +2. If you are releasing a minor version:: + + make release-minor + +3. If you are releasing a major version:: + + make release-major + +Release Candidates +~~~~~~~~~~~~~~~~~~ + +Sometimes it is necessary or convenient to upload a release candidate to PyPi as a pre-release, +in order to make some of the new features available for testing on other projects before they +are included in an actual full-blown release. + +In order to perform such an action, you can execute:: + + make release-candidate + +This will perform the following actions: + +1. Build and upload the current version to PyPi as a pre-release, with the format ``X.Y.Z.devN`` + +2. Bump the current version to the next release candidate, ``X.Y.Z.dev(N+1)`` + +After this is done, the new pre-release can be installed by including the ``dev`` section in the +dependency specification, either in ``setup.py``:: + + install_requires = [ + ... + 'ctgan>=X.Y.Z.dev', + ... + ] + +or in command line:: + + pip install 'ctgan>=X.Y.Z.dev' + + +.. _GitHub issues page: https://github.com/sdv-dev/CTGAN/issues +.. _Travis Build Status page: https://travis-ci.org/sdv-dev/CTGAN/pull_requests +.. _Google docstrings style: https://google.github.io/styleguide/pyguide.html?showone=Comments#Comments diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md new file mode 100644 index 0000000000000000000000000000000000000000..df2595e5dbbc2a9c44d571d9ae63bf86670e6cf2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md @@ -0,0 +1,147 @@ +# History + +## v0.5.1 - 2022-02-25 + +This release fixes a bug with the decoder instantiation, and also allows users to set a random state for the model +fitting and sampling. + +### Issues closed + +* Update self.decoder with correct variable name - Issue [#203](https://github.com/sdv-dev/CTGAN/issues/203) by @tejuafonja +* Add random state - Issue [#204](https://github.com/sdv-dev/CTGAN/issues/204) by @katxiao + +## v0.5.0 - 2021-11-18 + +This release adds support for Python 3.9 and updates dependencies to ensure compatibility with the +rest of the SDV ecosystem, and upgrades to the latests [RDT](https://github.com/sdv-dev/RDT/releases/tag/v0.6.1) +release. + +### Issues closed + +* Add support for Python 3.9 - Issue [#177](https://github.com/sdv-dev/CTGAN/issues/177) by @pvk-developer +* Add pip check to CI workflows - Issue [#174](https://github.com/sdv-dev/CTGAN/issues/174) by @pvk-developer +* Typo in `CTGAN` code - Issue [#158](https://github.com/sdv-dev/CTGAN/issues/158) by @ori-katz100 and @fealho + +## v0.4.3 - 2021-07-12 + +Dependency upgrades to ensure compatibility with the rest of the SDV ecosystem. + +## v0.4.2 - 2021-04-27 + +In this release, the way in which the loss function of the TVAE model was computed has been fixed. +In addition, the default value of the `discriminator_decay` has been changed to a more optimal +value. Also some improvements to the tests were added. + +### Issues closed + +* `TVAE`: loss function - Issue [#143](https://github.com/sdv-dev/CTGAN/issues/143) by @fealho and @DingfanChen +* Set `discriminator_decay` to `1e-6` - Pull request [#145](https://github.com/sdv-dev/CTGAN/pull/145/) by @fealho +* Adds unit tests - Pull requests [#140](https://github.com/sdv-dev/CTGAN/pull/140) by @fealho + +## v0.4.1 - 2021-03-30 + +This release exposes all the hyperparameters which the user may find useful for both `CTGAN` +and `TVAE`. Also `TVAE` can now be fitted on datasets that are shorter than the batch +size and drops the last batch only if the data size is not divisible by the batch size. + +### Issues closed + +* `TVAE`: Adapt `batch_size` to data size - Issue [#135](https://github.com/sdv-dev/CTGAN/issues/135) by @fealho and @csala +* `ValueError` from `validate_discre_columns` with `uniqueCombinationConstraint` - Issue [133](https://github.com/sdv-dev/CTGAN/issues/133) by @fealho and @MLjungg + +## v0.4.0 - 2021-02-24 + +Maintenance relese to upgrade dependencies to ensure compatibility with the rest +of the SDV libraries. + +Also add a validation on the CTGAN `condition_column` and `condition_value` inputs. + +### Improvements + +* Validate condition_column and condition_value - Issue [#124](https://github.com/sdv-dev/CTGAN/issues/124) by @fealho + +## v0.3.1 - 2021-01-27 + +### Improvements + +* Check discrete_columns valid before fitting - [Issue #35](https://github.com/sdv-dev/CTGAN/issues/35) by @fealho + +## Bugs fixed + +* ValueError: max() arg is an empty sequence - [Issue #115](https://github.com/sdv-dev/CTGAN/issues/115) by @fealho + +## v0.3.0 - 2020-12-18 + +In this release we add a new TVAE model which was presented in the original CTGAN paper. +It also exposes more hyperparameters and moves epochs and log_frequency from fit to the constructor. + +A new verbose argument has been added to optionally disable unnecessary printing, and a new hyperparameter +called `discriminator_steps` has been added to CTGAN to control the number of optimization steps performed +in the discriminator for each generator epoch. + +The code has also been reorganized and cleaned up for better readability and interpretability. + +Special thanks to @Baukebrenninkmeijer @fealho @leix28 @csala for the contributions! + +### Improvements + +* Add TVAE - [Issue #111](https://github.com/sdv-dev/CTGAN/issues/111) by @fealho +* Move `log_frequency` to `__init__` - [Issue #102](https://github.com/sdv-dev/CTGAN/issues/102) by @fealho +* Add discriminator steps hyperparameter - [Issue #101](https://github.com/sdv-dev/CTGAN/issues/101) by @Baukebrenninkmeijer +* Code cleanup / Expose hyperparameters - [Issue #59](https://github.com/sdv-dev/CTGAN/issues/59) by @fealho and @leix28 +* Publish to conda repo - [Issue #54](https://github.com/sdv-dev/CTGAN/issues/54) by @fealho + +### Bugs fixed + +* Fixed NaN != NaN counting bug. - [Issue #100](https://github.com/sdv-dev/CTGAN/issues/100) by @fealho +* Update dependencies and testing - [Issue #90](https://github.com/sdv-dev/CTGAN/issues/90) by @csala + +## v0.2.2 - 2020-11-13 + +In this release we introduce several minor improvements to make CTGAN more versatile and +propertly support new types of data, such as categorical NaN values, as well as conditional +sampling and features to save and load models. + +Additionally, the dependency ranges and python versions have been updated to support up +to date runtimes. + +Many thanks @fealho @leix28 @csala @oregonpillow and @lurosenb for working on making this release possible! + +### Improvements + +* Drop Python 3.5 support - [Issue #79](https://github.com/sdv-dev/CTGAN/issues/79) by @fealho +* Support NaN values in categorical variables - [Issue #78](https://github.com/sdv-dev/CTGAN/issues/78) by @fealho +* Sample synthetic data conditioning on a discrete column - [Issue #69](https://github.com/sdv-dev/CTGAN/issues/69) by @leix28 +* Support recent versions of pandas - [Issue #57](https://github.com/sdv-dev/CTGAN/issues/57) by @csala +* Easy solution for restoring original dtypes - [Issue #26](https://github.com/sdv-dev/CTGAN/issues/26) by @oregonpillow + +### Bugs fixed + +* Loss to nan - [Issue #73](https://github.com/sdv-dev/CTGAN/issues/73) by @fealho +* Swapped the sklearn utils testing import statement - [Issue #53](https://github.com/sdv-dev/CTGAN/issues/53) by @lurosenb + +## v0.2.1 - 2020-01-27 + +Minor version including changes to ensure the logs are properly printed and +the option to disable the log transformation to the discrete column frequencies. + +Special thanks to @kevinykuo for the contributions! + +### Issues Resolved: + +* Option to sample from true data frequency instead of logged frequency - [Issue #16](https://github.com/sdv-dev/CTGAN/issues/16) by @kevinykuo +* Flush stdout buffer for epoch updates - [Issue #14](https://github.com/sdv-dev/CTGAN/issues/14) by @kevinykuo + +## v0.2.0 - 2019-12-18 + +Reorganization of the project structure with a new Python API, new Command Line Interface +and increased data format support. + +### Issues Resolved: + +* Reorganize the project structure - [Issue #10](https://github.com/sdv-dev/CTGAN/issues/10) by @csala +* Move epochs to the fit method - [Issue #5](https://github.com/sdv-dev/CTGAN/issues/5) by @csala + +## v0.1.0 - 2019-11-07 + +First Release - NeurIPS 2019 Version. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f6f8213bcfc525df1b533a0dd4b06f05f9a14ea8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/LICENSE @@ -0,0 +1,22 @@ +MIT License + +Copyright (c) 2019, MIT Data To AI Lab + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in new file mode 100644 index 0000000000000000000000000000000000000000..469520f584a4ffc098d13e23c0d273f89e01a06e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in @@ -0,0 +1,11 @@ +include AUTHORS.rst +include CONTRIBUTING.rst +include HISTORY.md +include LICENSE +include README.md + +recursive-include tests * +recursive-exclude * __pycache__ +recursive-exclude * *.py[co] + +recursive-include docs *.md *.rst conf.py Makefile make.bat *.jpg *.png *.gif diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/Makefile b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..bb667a145994b12c34f88661ec6a566f06a4518d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/Makefile @@ -0,0 +1,240 @@ +.DEFAULT_GOAL := help + +define BROWSER_PYSCRIPT +import os, webbrowser, sys + +try: + from urllib import pathname2url +except: + from urllib.request import pathname2url + +webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1]))) +endef +export BROWSER_PYSCRIPT + +define PRINT_HELP_PYSCRIPT +import re, sys + +for line in sys.stdin: + match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line) + if match: + target, help = match.groups() + print("%-20s %s" % (target, help)) +endef +export PRINT_HELP_PYSCRIPT + +BROWSER := python -c "$$BROWSER_PYSCRIPT" + +.PHONY: help +help: + @python -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST) + + +# CLEAN TARGETS + +.PHONY: clean-build +clean-build: ## remove build artifacts + rm -fr build/ + rm -fr dist/ + rm -fr .eggs/ + find . -name '*.egg-info' -exec rm -fr {} + + find . -name '*.egg' -exec rm -f {} + + +.PHONY: clean-pyc +clean-pyc: ## remove Python file artifacts + find . -name '*.pyc' -exec rm -f {} + + find . -name '*.pyo' -exec rm -f {} + + find . -name '*~' -exec rm -f {} + + find . -name '__pycache__' -exec rm -fr {} + + +.PHONY: clean-coverage +clean-coverage: ## remove coverage artifacts + rm -f .coverage + rm -f .coverage.* + rm -fr htmlcov/ + +.PHONY: clean-test +clean-test: ## remove test artifacts + rm -fr .tox/ + rm -fr .pytest_cache + +.PHONY: clean +clean: clean-build clean-pyc clean-test clean-coverage ## remove all build, test, coverage and Python artifacts + + +# INSTALL TARGETS + +.PHONY: install +install: clean-build clean-pyc ## install the package to the active Python's site-packages + pip install . + +.PHONY: install-test +install-test: clean-build clean-pyc ## install the package and test dependencies + pip install .[test] + +.PHONY: install-develop +install-develop: clean-build clean-pyc ## install the package in editable mode and dependencies for development + pip install -e .[dev] + +MINIMUM := $(shell sed -n '/install_requires = \[/,/]/p' setup.py | head -n-1 | tail -n+2 | sed 's/ *\(.*\),$?$$/\1/g' | tr '>' '=') + +.PHONY: install-minimum +install-minimum: ## install the minimum supported versions of the package dependencies + pip install $(MINIMUM) + + +# LINT TARGETS + + +.PHONY: lint +lint: ## check style with flake8 and isort + invoke lint + +.PHONY: fix-lint +fix-lint: ## fix lint issues using autoflake, autopep8, and isort + find ctgan tests -name '*.py' | xargs autoflake --in-place --remove-all-unused-imports --remove-unused-variables + autopep8 --in-place --recursive --aggressive ctgan tests + isort --apply --atomic --recursive ctgan tests + + +# TEST TARGETS + +.PHONY: test-unit +test-unit: ## run unit tests using pytest + invoke unit + +.PHONY: test-integration +test-integration: ## run integration tests using pytest + invoke integration + +.PHONY: test-readme +test-readme: ## run the readme snippets + invoke readme + +.PHONY: check-dependencies +check-dependencies: ## test if there are any broken dependencies + pip check + +.PHONY: test +test: test-unit test-integration test-readme ## test everything that needs test dependencies + +.PHONY: test-devel +test-devel: lint ## test everything that needs development dependencies + +.PHONY: test-all +test-all: ## run tests on every Python version with tox + tox -r + + +.PHONY: coverage +coverage: ## check code coverage quickly with the default Python + coverage run --source ctgan -m pytest + coverage report -m + coverage html + $(BROWSER) htmlcov/index.html + + +# RELEASE TARGETS + +.PHONY: dist +dist: clean ## builds source and wheel package + python setup.py sdist + python setup.py bdist_wheel + ls -l dist + +.PHONY: publish-confirm +publish-confirm: + @echo "WARNING: This will irreversibly upload a new version to PyPI!" + @echo -n "Please type 'confirm' to proceed: " \ + && read answer \ + && [ "$${answer}" = "confirm" ] + +.PHONY: publish-test +publish-test: dist publish-confirm ## package and upload a release on TestPyPI + twine upload --repository-url https://test.pypi.org/legacy/ dist/* + +.PHONY: publish +publish: dist publish-confirm ## package and upload a release + twine upload dist/* + +.PHONY: bumpversion-release +bumpversion-release: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release + git push --tags origin stable + +.PHONY: bumpversion-release-test +bumpversion-release-test: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release --no-tag + @echo git push --tags origin stable + +.PHONY: bumpversion-patch +bumpversion-patch: ## Merge stable to master and bumpversion patch + git checkout master + git merge stable + bumpversion --no-tag patch + git push + +.PHONY: bumpversion-candidate +bumpversion-candidate: ## Bump the version to the next candidate + bumpversion candidate --no-tag + +.PHONY: bumpversion-minor +bumpversion-minor: ## Bump the version the next minor skipping the release + bumpversion --no-tag minor + +.PHONY: bumpversion-major +bumpversion-major: ## Bump the version the next major skipping the release + bumpversion --no-tag major + +.PHONY: bumpversion-revert +bumpversion-revert: ## Undo a previous bumpversion-release + git checkout master + git branch -D stable + +CLEAN_DIR := $(shell git status --short | grep -v ??) +CURRENT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD 2>/dev/null) +CHANGELOG_LINES := $(shell git diff HEAD..origin/stable HISTORY.md 2>&1 | wc -l) + +.PHONY: check-clean +check-clean: ## Check if the directory has uncommitted changes +ifneq ($(CLEAN_DIR),) + $(error There are uncommitted changes) +endif + +.PHONY: check-master +check-master: ## Check if we are in master branch +ifneq ($(CURRENT_BRANCH),master) + $(error Please make the release from master branch\n) +endif + +.PHONY: check-history +check-history: ## Check if HISTORY.md has been modified +ifeq ($(CHANGELOG_LINES),0) + $(error Please insert the release notes in HISTORY.md before releasing) +endif + +.PHONY: check-release +check-release: check-clean check-master check-history ## Check if the release can be made + @echo "A new release can be made" + +.PHONY: release +release: check-release bumpversion-release publish bumpversion-patch + +.PHONY: release-test +release-test: check-release bumpversion-release-test publish-test bumpversion-revert + +.PHONY: release-candidate +release-candidate: check-master publish bumpversion-candidate + +.PHONY: release-candidate-test +release-candidate-test: check-clean check-master publish-test + +.PHONY: release-minor +release-minor: check-release bumpversion-minor release + +.PHONY: release-major +release-major: check-release bumpversion-major release diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..6c8ab04c4ff5f505eaf5f1bf68c55f0161593f07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/README.md @@ -0,0 +1,182 @@ +
+
+

+ This repository is part of The Synthetic Data Vault Project, a project from DataCebo. +

+ +[![Development Status](https://img.shields.io/badge/Development%20Status-2%20--%20Pre--Alpha-yellow)](https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha) +[![PyPI Shield](https://img.shields.io/pypi/v/ctgan.svg)](https://pypi.python.org/pypi/ctgan) +[![Unit Tests](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml/badge.svg)](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml) +[![Downloads](https://pepy.tech/badge/ctgan)](https://pepy.tech/project/ctgan) +[![Coverage Status](https://codecov.io/gh/sdv-dev/CTGAN/branch/master/graph/badge.svg)](https://codecov.io/gh/sdv-dev/CTGAN) + +
+
+

+ + + +

+
+ +
+ +# Overview + +CTGAN is a collection of Deep Learning based Synthetic Data Generators for single table data, which are able to learn from real data and generate synthetic clones with high fidelity. + +| Important Links | | +| --------------------------------------------- | -------------------------------------------------------------------- | +| :computer: **[Website]** | Check out the SDV Website for more information about the project. | +| :orange_book: **[SDV Blog]** | Regular publshing of useful content about Synthetic Data Generation. | +| :book: **[Documentation]** | Quickstarts, User and Development Guides, and API Reference. | +| :octocat: **[Repository]** | The link to the Github Repository of this library. | +| :scroll: **[License]** | The entire ecosystem is published under the MIT License. | +| :keyboard: **[Development Status]** | This software is in its Pre-Alpha stage. | +| [![][Slack Logo] **Community**][Community] | Join our Slack Workspace for announcements and discussions. | +| [![][MyBinder Logo] **Tutorials**][Tutorials] | Run the SDV Tutorials in a Binder environment. | + +[Website]: https://sdv.dev +[SDV Blog]: https://sdv.dev/blog +[Documentation]: https://sdv.dev/SDV +[Repository]: https://github.com/sdv-dev/CTGAN +[License]: https://github.com/sdv-dev/CTGAN/blob/master/LICENSE +[Development Status]: https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha +[Slack Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/slack.png +[Community]: https://join.slack.com/t/sdv-space/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw +[MyBinder Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/mybinder.png +[Tutorials]: https://mybinder.org/v2/gh/sdv-dev/SDV/master?filepath=tutorials + +## Implemented Models + +Currently, this library implements the **CTGAN** and **TVAE** models proposed in the [Modeling Tabular data using Conditional GAN](https://arxiv.org/abs/1907.00503) paper. For more information about these models, please check out the respective user guides: +* [CTGAN User Guide](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). +* [TVAE User Guide](https://sdv.dev/SDV/user_guides/single_table/tvae.html). + +# Install + +**CTGAN** is part of the **SDV** project and is automatically installed alongside it. For +details about this process please visit the [SDV Installation Guide]( +https://sdv.dev/SDV/getting_started/install.html) + +Optionally, **CTGAN** can also be installed as a standalone library using the following commands: + +**Using `pip`:** + +```bash +pip install ctgan +``` + +**Using `conda`:** + +```bash +conda install -c pytorch -c conda-forge ctgan +``` + +For more installation options please visit the [CTGAN installation Guide](INSTALL.md) + +# Usage Example + +> :warning: **WARNING**: If you're just getting started with synthetic data, we recommend using the SDV library which provides user-friendly APIs for interacting with CTGAN. To learn more about using CTGAN through SDV, check out the user guide [here](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). + +To get started with CTGAN, you should prepare your data as either a `numpy.ndarray` or a `pandas.DataFrame` object with two types of columns: + +* **Continuous Columns**: can contain any numerical value. +* **Discrete Columns**: contain a finite number values, whether these are string values or not. + +In this example we load the [Adult Census Dataset](https://archive.ics.uci.edu/ml/datasets/adult) which is a built-in demo dataset. We then model it using the **CTGANSynthesizer** and generate a synthetic copy of it. + + +```python3 +from ctgan import CTGANSynthesizer +from ctgan import load_demo + +data = load_demo() + +# Names of the columns that are discrete +discrete_columns = [ + 'workclass', + 'education', + 'marital-status', + 'occupation', + 'relationship', + 'race', + 'sex', + 'native-country', + 'income' +] + +ctgan = CTGANSynthesizer(epochs=10) +ctgan.fit(data, discrete_columns) + +# Synthetic copy +samples = ctgan.sample(1000) +``` + + + +# Join our community + + +1. Please have a look at the [Contributing Guide](https://sdv.dev/SDV/developer_guides/contributing.html) to see how you can contribute to the project. +2. If you have any doubts, feature requests or detect an error, please [open an issue on github](https://github.com/sdv-dev/CTGAN/issues) or [join our Slack Workspace](https://sdv-space.slack.com/join/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw#/). +3. Also, do not forget to check the [project documentation site](https://sdv.dev/SDV/)! + + +# Citing TGAN + +If you use CTGAN, please cite the following work: + +- *Lei Xu, Maria Skoularidou, Alfredo Cuesta-Infante, Kalyan Veeramachaneni.* **Modeling Tabular data using Conditional GAN**. NeurIPS, 2019. + +```LaTeX +@inproceedings{xu2019modeling, + title={Modeling Tabular data using Conditional GAN}, + author={Xu, Lei and Skoularidou, Maria and Cuesta-Infante, Alfredo and Veeramachaneni, Kalyan}, + booktitle={Advances in Neural Information Processing Systems}, + year={2019} +} +``` + +# Related Projects +Please note that these libraries are external contributions and are not maintained nor supervised by +the MIT DAI-Lab team. + +## R interface for CTGAN + +A wrapper around **CTGAN** has been implemented by Kevin Kuo @kevinykuo, bringing the functionalities +of **CTGAN** to **R** users. + +More details can be found in the corresponding repository: https://github.com/kasaai/ctgan + +## CTGAN Server CLI + +A package to easily deploy **CTGAN** onto a remote server. This package is developed by Timothy Pillow @oregonpillow. + +More details can be found in the corresponding repository: https://github.com/oregonpillow/ctgan-server-cli + +--- + + +
+ +
+
+
+ +[The Synthetic Data Vault Project](https://sdv.dev) was first created at MIT's [Data to AI Lab]( +https://dai.lids.mit.edu/) in 2016. After 4 years of research and traction with enterprise, we +created [DataCebo](https://datacebo.com) in 2020 with the goal of growing the project. +Today, DataCebo is the proud developer of SDV, the largest ecosystem for +synthetic data generation & evaluation. It is home to multiple libraries that support synthetic +data, including: + +* 🔄 Data discovery & transformation. Reverse the transforms to reproduce realistic data. +* 🧠 Multiple machine learning models -- ranging from Copulas to Deep Learning -- to create tabular, + multi table and time series data. +* 📊 Measuring quality and privacy of synthetic data, and comparing different synthetic data + generation models. + +[Get started using the SDV package](https://sdv.dev/SDV/getting_started/install.html) -- a fully +integrated solution and your one-stop shop for synthetic data. Or, use the standalone libraries +for specific needs. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md new file mode 100644 index 0000000000000000000000000000000000000000..92e2ec5aa40b081c940ac1e918efaeeed8623584 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md @@ -0,0 +1,29 @@ +## Instructions + +These are instructions to deploy the latest version of **CTGAN** to [conda](https://docs.conda.io/en/latest/). +It should be done after every new release. + +## Update the recipe +Prior to making the release on PyPI, you should update the meta.yaml to reflect any changes in the dependencies. +Note that you do not need to edit the version number as that is managed by bumpversion. + +## Make the PyPI release +Follow the standard release instructions to make a PyPI release. Then, return here to make the conda release. + +## Build a package +As part of the PyPI release, you will have updated the stable branch. You should now check out the stable +branch and build the conda package. + +```bash +git checkout stable +cd conda +conda build -c sdv-dev -c pytorch -c conda-forge . +``` + +## Upload to Anaconda +Finally, you can upload the resulting package to Anaconda. + +```bash +anaconda login +anaconda upload -u sdv-dev +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9d26c28c6ada4f4977d517986a05ceca138c7090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml @@ -0,0 +1,51 @@ +{% set name = 'ctgan' %} +{% set version = '0.5.2.dev0' %} + +package: + name: "{{ name|lower }}" + version: "{{ version }}" + +source: + url: "https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz" + +build: + number: 0 + noarch: python + entry_points: + - ctgan=ctgan.__main__:main + script: "{{ PYTHON }} -m pip install . -vv" + +requirements: + host: + - pip + - pytest-runner + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + run: + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + +about: + home: "https://github.com/sdv-dev/CTGAN" + license: MIT + license_family: MIT + license_file: + summary: "Conditional GAN for Tabular Data" + doc_url: + dev_url: + +extra: + recipe-maintainers: + - sdv-dev diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e3abb1c03b685802c21428ba050b1620e1a435fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py @@ -0,0 +1,17 @@ +# -*- coding: utf-8 -*- + +"""Top-level package for ctgan.""" + +__author__ = 'MIT Data To AI Lab' +__email__ = 'dailabmit@gmail.com' +__version__ = '0.5.2.dev0' + +from .demo import load_demo +from .synthesizers.ctgan import CTGANSynthesizer +from .synthesizers.tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer', + 'load_demo' +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..8291c1879b60d0de49db79fb6ca60d33f09c8763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py @@ -0,0 +1,102 @@ +"""CLI.""" + +import argparse + +from ctgan.data import read_csv, read_tsv, write_tsv +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def _parse_args(): + parser = argparse.ArgumentParser(description='CTGAN Command Line Interface') + parser.add_argument('-e', '--epochs', default=300, type=int, + help='Number of training epochs') + parser.add_argument('-t', '--tsv', action='store_true', + help='Load data in TSV format instead of CSV') + parser.add_argument('--no-header', dest='header', action='store_false', + help='The CSV file has no header. Discrete columns will be indices.') + + parser.add_argument('-m', '--metadata', help='Path to the metadata') + parser.add_argument('-d', '--discrete', + help='Comma separated list of discrete columns without whitespaces.') + parser.add_argument('-n', '--num-samples', type=int, + help='Number of rows to sample. Defaults to the training data size') + + parser.add_argument('--generator_lr', type=float, default=2e-4, + help='Learning rate for the generator.') + parser.add_argument('--discriminator_lr', type=float, default=2e-4, + help='Learning rate for the discriminator.') + + parser.add_argument('--generator_decay', type=float, default=1e-6, + help='Weight decay for the generator.') + parser.add_argument('--discriminator_decay', type=float, default=0, + help='Weight decay for the discriminator.') + + parser.add_argument('--embedding_dim', type=int, default=128, + help='Dimension of input z to the generator.') + parser.add_argument('--generator_dim', type=str, default='256,256', + help='Dimension of each generator layer. ' + 'Comma separated integers with no whitespaces.') + parser.add_argument('--discriminator_dim', type=str, default='256,256', + help='Dimension of each discriminator layer. ' + 'Comma separated integers with no whitespaces.') + + parser.add_argument('--batch_size', type=int, default=500, + help='Batch size. Must be an even number.') + parser.add_argument('--save', default=None, type=str, + help='A filename to save the trained synthesizer.') + parser.add_argument('--load', default=None, type=str, + help='A filename to load a trained synthesizer.') + + parser.add_argument('--sample_condition_column', default=None, type=str, + help='Select a discrete column name.') + parser.add_argument('--sample_condition_column_value', default=None, type=str, + help='Specify the value of the selected discrete column.') + + parser.add_argument('data', help='Path to training data') + parser.add_argument('output', help='Path of the output file') + + return parser.parse_args() + + +def main(): + """CLI.""" + args = _parse_args() + if args.tsv: + data, discrete_columns = read_tsv(args.data, args.metadata) + else: + data, discrete_columns = read_csv(args.data, args.metadata, args.header, args.discrete) + + if args.load: + model = CTGANSynthesizer.load(args.load) + else: + generator_dim = [int(x) for x in args.generator_dim.split(',')] + discriminator_dim = [int(x) for x in args.discriminator_dim.split(',')] + model = CTGANSynthesizer( + embedding_dim=args.embedding_dim, generator_dim=generator_dim, + discriminator_dim=discriminator_dim, generator_lr=args.generator_lr, + generator_decay=args.generator_decay, discriminator_lr=args.discriminator_lr, + discriminator_decay=args.discriminator_decay, batch_size=args.batch_size, + epochs=args.epochs) + model.fit(data, discrete_columns) + + if args.save is not None: + model.save(args.save) + + num_samples = args.num_samples or len(data) + + if args.sample_condition_column is not None: + assert args.sample_condition_column_value is not None + + sampled = model.sample( + num_samples, + args.sample_condition_column, + args.sample_condition_column_value) + + if args.tsv: + write_tsv(sampled, args.metadata, args.output) + else: + sampled.to_csv(args.output, index=False) + + +if __name__ == '__main__': + main() diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py new file mode 100644 index 0000000000000000000000000000000000000000..1c3ec72e9ec972f9c7d148b66f212bf3e366a340 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py @@ -0,0 +1,94 @@ +"""Data loading.""" + +import json + +import numpy as np +import pandas as pd + + +def read_csv(csv_filename, meta_filename=None, header=True, discrete=None): + """Read a csv file.""" + data = pd.read_csv(csv_filename, header='infer' if header else None) + + if meta_filename: + with open(meta_filename) as meta_file: + metadata = json.load(meta_file) + + discrete_columns = [ + column['name'] + for column in metadata['columns'] + if column['type'] != 'continuous' + ] + + elif discrete: + discrete_columns = discrete.split(',') + if not header: + discrete_columns = [int(i) for i in discrete_columns] + + else: + discrete_columns = [] + + return data, discrete_columns + + +def read_tsv(data_filename, meta_filename): + """Read a tsv file.""" + with open(meta_filename) as f: + column_info = f.readlines() + + column_info_raw = [ + x.replace('{', ' ').replace('}', ' ').split() + for x in column_info + ] + + discrete = [] + continuous = [] + column_info = [] + + for idx, item in enumerate(column_info_raw): + if item[0] == 'C': + continuous.append(idx) + column_info.append((float(item[1]), float(item[2]))) + else: + assert item[0] == 'D' + discrete.append(idx) + column_info.append(item[1:]) + + meta = { + 'continuous_columns': continuous, + 'discrete_columns': discrete, + 'column_info': column_info + } + + with open(data_filename) as f: + lines = f.readlines() + + data = [] + for row in lines: + row_raw = row.split() + row = [] + for idx, col in enumerate(row_raw): + if idx in continuous: + row.append(col) + else: + assert idx in discrete + row.append(column_info[idx].index(col)) + + data.append(row) + + return np.asarray(data, dtype='float32'), meta['discrete_columns'] + + +def write_tsv(data, meta, output_filename): + """Write to a tsv file.""" + with open(output_filename, 'w') as f: + + for row in data: + for idx, col in enumerate(row): + if idx in meta['continuous_columns']: + print(col, end=' ', file=f) + else: + assert idx in meta['discrete_columns'] + print(meta['column_info'][idx][int(col)], end=' ', file=f) + + print(file=f) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py new file mode 100644 index 0000000000000000000000000000000000000000..5cbf339dac0980c5368d2d11e2934a268fb9d43a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py @@ -0,0 +1,156 @@ +"""DataSampler module.""" + +import numpy as np + + +class DataSampler(object): + """DataSampler samples the conditional vector and corresponding data for CTGAN.""" + + def __init__(self, data, output_info, log_frequency): + self._data = data + + def is_discrete_column(column_info): + return (len(column_info) == 1 + and column_info[0].activation_fn == 'softmax') + + n_discrete_columns = sum( + [1 for column_info in output_info if is_discrete_column(column_info)]) + + self._discrete_column_matrix_st = np.zeros( + n_discrete_columns, dtype='int32') + + # Store the row id for each category in each discrete column. + # For example _rid_by_cat_cols[a][b] is a list of all rows with the + # a-th discrete column equal value b. + self._rid_by_cat_cols = [] + + # Compute _rid_by_cat_cols + st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + + rid_by_cat = [] + for j in range(span_info.dim): + rid_by_cat.append(np.nonzero(data[:, st + j])[0]) + self._rid_by_cat_cols.append(rid_by_cat) + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + assert st == data.shape[1] + + # Prepare an interval matrix for efficiently sample conditional vector + max_category = max([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ], default=0) + + self._discrete_column_cond_st = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_n_category = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_category_prob = np.zeros((n_discrete_columns, max_category)) + self._n_discrete_columns = n_discrete_columns + self._n_categories = sum([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ]) + + st = 0 + current_id = 0 + current_cond_st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + category_freq = np.sum(data[:, st:ed], axis=0) + if log_frequency: + category_freq = np.log(category_freq + 1) + category_prob = category_freq / np.sum(category_freq) + self._discrete_column_category_prob[current_id, :span_info.dim] = category_prob + self._discrete_column_cond_st[current_id] = current_cond_st + self._discrete_column_n_category[current_id] = span_info.dim + current_cond_st += span_info.dim + current_id += 1 + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + + def _random_choice_prob_index(self, discrete_column_id): + probs = self._discrete_column_category_prob[discrete_column_id] + r = np.expand_dims(np.random.rand(probs.shape[0]), axis=1) + return (probs.cumsum(axis=1) > r).argmax(axis=1) + + def sample_condvec(self, batch): + """Generate the conditional vector for training. + + Returns: + cond (batch x #categories): + The conditional vector. + mask (batch x #discrete columns): + A one-hot vector indicating the selected discrete column. + discrete column id (batch): + Integer representation of mask. + category_id_in_col (batch): + Selected category in the selected discrete column. + """ + if self._n_discrete_columns == 0: + return None + + discrete_column_id = np.random.choice( + np.arange(self._n_discrete_columns), batch) + + cond = np.zeros((batch, self._n_categories), dtype='float32') + mask = np.zeros((batch, self._n_discrete_columns), dtype='float32') + mask[np.arange(batch), discrete_column_id] = 1 + category_id_in_col = self._random_choice_prob_index(discrete_column_id) + category_id = (self._discrete_column_cond_st[discrete_column_id] + category_id_in_col) + cond[np.arange(batch), category_id] = 1 + + return cond, mask, discrete_column_id, category_id_in_col + + def sample_original_condvec(self, batch): + """Generate the conditional vector for generation use original frequency.""" + if self._n_discrete_columns == 0: + return None + + cond = np.zeros((batch, self._n_categories), dtype='float32') + + for i in range(batch): + row_idx = np.random.randint(0, len(self._data)) + col_idx = np.random.randint(0, self._n_discrete_columns) + matrix_st = self._discrete_column_matrix_st[col_idx] + matrix_ed = matrix_st + self._discrete_column_n_category[col_idx] + pick = np.argmax(self._data[row_idx, matrix_st:matrix_ed]) + cond[i, pick + self._discrete_column_cond_st[col_idx]] = 1 + + return cond + + def sample_data(self, n, col, opt): + """Sample data from original training data satisfying the sampled conditional vector. + + Returns: + n rows of matrix data. + """ + if col is None: + idx = np.random.randint(len(self._data), size=n) + return self._data[idx] + + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self._rid_by_cat_cols[c][o])) + + return self._data[idx] + + def dim_cond_vec(self): + """Return the total number of categories.""" + return self._n_categories + + def generate_cond_from_condition_column_info(self, condition_info, batch): + """Generate the condition vector.""" + vec = np.zeros((batch, self._n_categories), dtype='float32') + id_ = self._discrete_column_matrix_st[condition_info['discrete_column_id']] + id_ += condition_info['value_id'] + vec[:, id_] = 1 + return vec diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..06cfd128247f187be963c4b8c26067b06a02cbce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py @@ -0,0 +1,217 @@ +"""DataTransformer module.""" + +from collections import namedtuple + +import numpy as np +import pandas as pd +from rdt.transformers import BayesGMMTransformer, OneHotEncodingTransformer + +SpanInfo = namedtuple('SpanInfo', ['dim', 'activation_fn']) +ColumnTransformInfo = namedtuple( + 'ColumnTransformInfo', [ + 'column_name', 'column_type', 'transform', 'output_info', 'output_dimensions' + ] +) + + +class DataTransformer(object): + """Data Transformer. + + Model continuous columns with a BayesianGMM and normalized to a scalar [0, 1] and a vector. + Discrete columns are encoded using a scikit-learn OneHotEncoder. + """ + + def __init__(self, max_clusters=10, weight_threshold=0.005): + """Create a data transformer. + + Args: + max_clusters (int): + Maximum number of Gaussian distributions in Bayesian GMM. + weight_threshold (float): + Weight threshold for a Gaussian distribution to be kept. + """ + self._max_clusters = max_clusters + self._weight_threshold = weight_threshold + + def _fit_continuous(self, data): + """Train Bayesian GMM for continuous columns. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + gm = BayesGMMTransformer(max_clusters=min(len(data), 10)) + gm.fit(data, [column_name]) + num_components = sum(gm.valid_component_indicator) + + return ColumnTransformInfo( + column_name=column_name, column_type='continuous', transform=gm, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(num_components, 'softmax')], + output_dimensions=1 + num_components) + + def _fit_discrete(self, data): + """Fit one hot encoder for discrete column. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + ohe = OneHotEncodingTransformer() + ohe.fit(data, [column_name]) + num_categories = len(ohe.dummies) + + return ColumnTransformInfo( + column_name=column_name, column_type='discrete', transform=ohe, + output_info=[SpanInfo(num_categories, 'softmax')], + output_dimensions=num_categories) + + def fit(self, raw_data, discrete_columns=()): + """Fit the ``DataTransformer``. + + Fits a ``BayesGMMTransformer`` for continuous columns and a + ``OneHotEncodingTransformer`` for discrete columns. + + This step also counts the #columns in matrix data and span information. + """ + self.output_info_list = [] + self.output_dimensions = 0 + self.dataframe = True + + if not isinstance(raw_data, pd.DataFrame): + self.dataframe = False + # work around for RDT issue #328 Fitting with numerical column names fails + discrete_columns = [str(column) for column in discrete_columns] + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + self._column_raw_dtypes = raw_data.infer_objects().dtypes + self._column_transform_info_list = [] + for column_name in raw_data.columns: + if column_name in discrete_columns: + column_transform_info = self._fit_discrete(raw_data[[column_name]]) + else: + column_transform_info = self._fit_continuous(raw_data[[column_name]]) + + self.output_info_list.append(column_transform_info.output_info) + self.output_dimensions += column_transform_info.output_dimensions + self._column_transform_info_list.append(column_transform_info) + + def _transform_continuous(self, column_transform_info, data): + column_name = data.columns[0] + data.loc[:, column_name] = data[column_name].to_numpy().flatten() + gm = column_transform_info.transform + transformed = gm.transform(data, [column_name]) + + # Converts the transformed data to the appropriate output format. + # The first column (ending in '.normalized') stays the same, + # but the lable encoded column (ending in '.component') is one hot encoded. + output = np.zeros((len(transformed), column_transform_info.output_dimensions)) + output[:, 0] = transformed[f'{column_name}.normalized'].to_numpy() + index = transformed[f'{column_name}.component'].to_numpy().astype(int) + output[np.arange(index.size), index + 1] = 1.0 + + return output + + def _transform_discrete(self, column_transform_info, data): + ohe = column_transform_info.transform + return ohe.transform(data).to_numpy() + + def transform(self, raw_data): + """Take raw data and output a matrix data.""" + if not isinstance(raw_data, pd.DataFrame): + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + column_data_list = [] + for column_transform_info in self._column_transform_info_list: + column_name = column_transform_info.column_name + data = raw_data[[column_name]] + if column_transform_info.column_type == 'continuous': + column_data_list.append(self._transform_continuous(column_transform_info, data)) + else: + column_data_list.append(self._transform_discrete(column_transform_info, data)) + + return np.concatenate(column_data_list, axis=1).astype(float) + + def _inverse_transform_continuous(self, column_transform_info, column_data, sigmas, st): + gm = column_transform_info.transform + data = pd.DataFrame(column_data[:, :2], columns=list(gm.get_output_types())) + data.iloc[:, 1] = np.argmax(column_data[:, 1:], axis=1) + if sigmas is not None: + selected_normalized_value = np.random.normal(data.iloc[:, 0], sigmas[st]) + data.iloc[:, 0] = selected_normalized_value + + return gm.reverse_transform(data, [column_transform_info.column_name]) + + def _inverse_transform_discrete(self, column_transform_info, column_data): + ohe = column_transform_info.transform + data = pd.DataFrame(column_data, columns=list(ohe.get_output_types())) + return ohe.reverse_transform(data)[column_transform_info.column_name] + + def inverse_transform(self, data, sigmas=None): + """Take matrix data and output raw data. + + Output uses the same type as input to the transform function. + Either np array or pd dataframe. + """ + st = 0 + recovered_column_data_list = [] + column_names = [] + for column_transform_info in self._column_transform_info_list: + dim = column_transform_info.output_dimensions + column_data = data[:, st:st + dim] + if column_transform_info.column_type == 'continuous': + recovered_column_data = self._inverse_transform_continuous( + column_transform_info, column_data, sigmas, st) + else: + recovered_column_data = self._inverse_transform_discrete( + column_transform_info, column_data) + + recovered_column_data_list.append(recovered_column_data) + column_names.append(column_transform_info.column_name) + st += dim + + recovered_data = np.column_stack(recovered_column_data_list) + recovered_data = (pd.DataFrame(recovered_data, columns=column_names) + .astype(self._column_raw_dtypes)) + if not self.dataframe: + recovered_data = recovered_data.to_numpy() + + return recovered_data + + def convert_column_name_value_to_id(self, column_name, value): + """Get the ids of the given `column_name`.""" + discrete_counter = 0 + column_id = 0 + for column_transform_info in self._column_transform_info_list: + if column_transform_info.column_name == column_name: + break + if column_transform_info.column_type == 'discrete': + discrete_counter += 1 + + column_id += 1 + + else: + raise ValueError(f"The column_name `{column_name}` doesn't exist in the data.") + + ohe = column_transform_info.transform + data = pd.DataFrame([value], columns=[column_transform_info.column_name]) + one_hot = ohe.transform(data).to_numpy()[0] + if sum(one_hot) == 0: + raise ValueError(f"The value `{value}` doesn't exist in the column `{column_name}`.") + + return { + 'discrete_column_id': discrete_counter, + 'column_id': column_id, + 'value_id': np.argmax(one_hot) + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py new file mode 100644 index 0000000000000000000000000000000000000000..a99f90aa576a31f07ebfa7081ee6e4e7817ed02f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py @@ -0,0 +1,10 @@ +"""Demo module.""" + +import pandas as pd + +DEMO_URL = 'http://ctgan-data.s3.amazonaws.com/census.csv.gz' + + +def load_demo(): + """Load the demo.""" + return pd.read_csv(DEMO_URL, compression='gzip') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..2f67c77a7892dad39ae429b80b46e8672a3c69df --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py @@ -0,0 +1,16 @@ +"""Synthesizers module.""" + +from .ctgan import CTGANSynthesizer +from .tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer' +) + + +def get_all_synthesizers(): + return { + name: globals()[name] + for name in __all__ + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py new file mode 100644 index 0000000000000000000000000000000000000000..5afb66d4a6d2700c27516d8a322ab7b30a9356eb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py @@ -0,0 +1,105 @@ +"""BaseSynthesizer module.""" + +import contextlib + +import numpy as np +import torch + + +@contextlib.contextmanager +def set_random_states(random_state, set_model_random_state): + """Context manager for managing the random state. + + Args: + random_state (int or tuple): + The random seed or a tuple of (numpy.random.RandomState, torch.Generator). + set_model_random_state (function): + Function to set the random state on the model. + """ + original_np_state = np.random.get_state() + original_torch_state = torch.get_rng_state() + + random_np_state, random_torch_state = random_state + + np.random.set_state(random_np_state.get_state()) + torch.set_rng_state(random_torch_state.get_state()) + + try: + yield + finally: + current_np_state = np.random.RandomState() + current_np_state.set_state(np.random.get_state()) + current_torch_state = torch.Generator() + current_torch_state.set_state(torch.get_rng_state()) + set_model_random_state((current_np_state, current_torch_state)) + + np.random.set_state(original_np_state) + torch.set_rng_state(original_torch_state) + + +def random_state(function): + """Set the random state before calling the function. + + Args: + function (Callable): + The function to wrap around. + """ + def wrapper(self, *args, **kwargs): + if self.random_states is None: + return function(self, *args, **kwargs) + + else: + with set_random_states(self.random_states, self.set_random_state): + return function(self, *args, **kwargs) + + return wrapper + + +class BaseSynthesizer: + """Base class for all default synthesizers of ``CTGAN``. + + This should contain the save/load methods. + """ + + random_states = None + + def save(self, path): + """Save the model in the passed `path`.""" + device_backup = self._device + self.set_device(torch.device('cpu')) + torch.save(self, path) + self.set_device(device_backup) + + @classmethod + def load(cls, path): + """Load the model stored in the passed `path`.""" + device = torch.device('cuda:0' if torch.cuda.is_available() else 'cpu') + model = torch.load(path) + model.set_device(device) + return model + + def set_random_state(self, random_state): + """Set the random state. + + Args: + random_state (int, tuple, or None): + Either a tuple containing the (numpy.random.RandomState, torch.Generator) + or an int representing the random seed to use for both random states. + """ + if random_state is None: + self.random_states = random_state + elif isinstance(random_state, int): + self.random_states = ( + np.random.RandomState(seed=random_state), + torch.Generator().manual_seed(random_state), + ) + elif ( + isinstance(random_state, tuple) and + isinstance(random_state[0], np.random.RandomState) and + isinstance(random_state[1], torch.Generator) + ): + self.random_states = random_state + else: + raise TypeError( + f'`random_state` {random_state} expected to be an int or a tuple of ' + '(`np.random.RandomState`, `torch.Generator`)') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..e4253e87d6349cd2bccb669f46146edfd61e23a8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py @@ -0,0 +1,482 @@ +"""CTGANSynthesizer module.""" + +import warnings + +import numpy as np +import pandas as pd +import torch +from packaging import version +from torch import optim +from torch.nn import BatchNorm1d, Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, functional + +from ..data_sampler import DataSampler +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Discriminator(Module): + """Discriminator for the CTGANSynthesizer.""" + + def __init__(self, input_dim, discriminator_dim, pac=10): + super(Discriminator, self).__init__() + dim = input_dim * pac + self.pac = pac + self.pacdim = dim + seq = [] + for item in list(discriminator_dim): + seq += [Linear(dim, item), LeakyReLU(0.2), Dropout(0.5)] + dim = item + + seq += [Linear(dim, 1)] + self.seq = Sequential(*seq) + + def calc_gradient_penalty(self, real_data, fake_data, device='cpu', pac=10, lambda_=10): + """Compute the gradient penalty.""" + alpha = torch.rand(real_data.size(0) // pac, 1, 1, device=device) + alpha = alpha.repeat(1, pac, real_data.size(1)) + alpha = alpha.view(-1, real_data.size(1)) + + interpolates = alpha * real_data + ((1 - alpha) * fake_data) + + disc_interpolates = self(interpolates) + + gradients = torch.autograd.grad( + outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size(), device=device), + create_graph=True, retain_graph=True, only_inputs=True + )[0] + + gradients_view = gradients.view(-1, pac * real_data.size(1)).norm(2, dim=1) - 1 + gradient_penalty = ((gradients_view) ** 2).mean() * lambda_ + + return gradient_penalty + + def forward(self, input_): + """Apply the Discriminator to the `input_`.""" + assert input_.size()[0] % self.pac == 0 + return self.seq(input_.view(-1, self.pacdim)) + + +class Residual(Module): + """Residual layer for the CTGANSynthesizer.""" + + def __init__(self, i, o): + super(Residual, self).__init__() + self.fc = Linear(i, o) + self.bn = BatchNorm1d(o) + self.relu = ReLU() + + def forward(self, input_): + """Apply the Residual layer to the `input_`.""" + out = self.fc(input_) + out = self.bn(out) + out = self.relu(out) + return torch.cat([out, input_], dim=1) + + +class Generator(Module): + """Generator for the CTGANSynthesizer.""" + + def __init__(self, embedding_dim, generator_dim, data_dim): + super(Generator, self).__init__() + dim = embedding_dim + seq = [] + for item in list(generator_dim): + seq += [Residual(dim, item)] + dim += item + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + + def forward(self, input_): + """Apply the Generator to the `input_`.""" + data = self.seq(input_) + return data + + +class CTGANSynthesizer(BaseSynthesizer): + """Conditional Table GAN Synthesizer. + + This is the core class of the CTGAN project, where the different components + are orchestrated together. + For more details about the process, please check the [Modeling Tabular data using + Conditional GAN](https://arxiv.org/abs/1907.00503) paper. + + Args: + embedding_dim (int): + Size of the random sample passed to the Generator. Defaults to 128. + generator_dim (tuple or list of ints): + Size of the output samples for each one of the Residuals. A Residual Layer + will be created for each one of the values provided. Defaults to (256, 256). + discriminator_dim (tuple or list of ints): + Size of the output samples for each one of the Discriminator Layers. A Linear Layer + will be created for each one of the values provided. Defaults to (256, 256). + generator_lr (float): + Learning rate for the generator. Defaults to 2e-4. + generator_decay (float): + Generator weight decay for the Adam Optimizer. Defaults to 1e-6. + discriminator_lr (float): + Learning rate for the discriminator. Defaults to 2e-4. + discriminator_decay (float): + Discriminator weight decay for the Adam Optimizer. Defaults to 1e-6. + batch_size (int): + Number of data samples to process in each step. + discriminator_steps (int): + Number of discriminator updates to do for each generator update. + From the WGAN paper: https://arxiv.org/abs/1701.07875. WGAN paper + default is 5. Default used is 1 to match original CTGAN implementation. + log_frequency (boolean): + Whether to use log frequency of categorical levels in conditional + sampling. Defaults to ``True``. + verbose (boolean): + Whether to have print statements for progress results. Defaults to ``False``. + epochs (int): + Number of training epochs. Defaults to 300. + pac (int): + Number of samples to group together when applying the discriminator. + Defaults to 10. + cuda (bool): + Whether to attempt to use cuda for GPU computation. + If this is False or CUDA is not available, CPU will be used. + Defaults to ``True``. + """ + + def __init__(self, embedding_dim=128, generator_dim=(256, 256), discriminator_dim=(256, 256), + generator_lr=2e-4, generator_decay=1e-6, discriminator_lr=2e-4, + discriminator_decay=1e-6, batch_size=500, discriminator_steps=1, + log_frequency=True, verbose=False, epochs=300, pac=10, cuda=True): + + assert batch_size % 2 == 0 + + self._embedding_dim = embedding_dim + self._generator_dim = generator_dim + self._discriminator_dim = discriminator_dim + + self._generator_lr = generator_lr + self._generator_decay = generator_decay + self._discriminator_lr = discriminator_lr + self._discriminator_decay = discriminator_decay + + self._batch_size = batch_size + self._discriminator_steps = discriminator_steps + self._log_frequency = log_frequency + self._verbose = verbose + self._epochs = epochs + self.pac = pac + + if not cuda or not torch.cuda.is_available(): + device = 'cpu' + elif isinstance(cuda, str): + device = cuda + else: + device = 'cuda' + + self._device = torch.device(device) + + self._transformer = None + self._data_sampler = None + self._generator = None + + @staticmethod + def _gumbel_softmax(logits, tau=1, hard=False, eps=1e-10, dim=-1): + """Deals with the instability of the gumbel_softmax for older versions of torch. + + For more details about the issue: + https://drive.google.com/file/d/1AA5wPfZ1kquaRtVruCd6BiYZGcDeNxyP/view?usp=sharing + + Args: + logits […, num_features]: + Unnormalized log probabilities + tau: + Non-negative scalar temperature + hard (bool): + If True, the returned samples will be discretized as one-hot vectors, + but will be differentiated as if it is the soft sample in autograd + dim (int): + A dimension along which softmax will be computed. Default: -1. + + Returns: + Sampled tensor of same shape as logits from the Gumbel-Softmax distribution. + """ + if version.parse(torch.__version__) < version.parse('1.2.0'): + for i in range(10): + transformed = functional.gumbel_softmax(logits, tau=tau, hard=hard, + eps=eps, dim=dim) + if not torch.isnan(transformed).any(): + return transformed + raise ValueError('gumbel_softmax returning NaN.') + + return functional.gumbel_softmax(logits, tau=tau, hard=hard, eps=eps, dim=dim) + + def _apply_activate(self, data): + """Apply proper activation function to the output of the generator.""" + data_t = [] + st = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if span_info.activation_fn == 'tanh': + ed = st + span_info.dim + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif span_info.activation_fn == 'softmax': + ed = st + span_info.dim + transformed = self._gumbel_softmax(data[:, st:ed], tau=0.2) + data_t.append(transformed) + st = ed + else: + raise ValueError(f'Unexpected activation function {span_info.activation_fn}.') + + return torch.cat(data_t, dim=1) + + def _cond_loss(self, data, c, m): + """Compute the cross entropy loss on the fixed discrete column.""" + loss = [] + st = 0 + st_c = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if len(column_info) != 1 or span_info.activation_fn != 'softmax': + # not discrete column + st += span_info.dim + else: + ed = st + span_info.dim + ed_c = st_c + span_info.dim + tmp = functional.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none' + ) + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) # noqa: PD013 + + return (loss * m).sum() / data.size()[0] + + def _validate_discrete_columns(self, train_data, discrete_columns): + """Check whether ``discrete_columns`` exists in ``train_data``. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + if isinstance(train_data, pd.DataFrame): + invalid_columns = set(discrete_columns) - set(train_data.columns) + elif isinstance(train_data, np.ndarray): + invalid_columns = [] + for column in discrete_columns: + if column < 0 or column >= train_data.shape[1]: + invalid_columns.append(column) + else: + raise TypeError('``train_data`` should be either pd.DataFrame or np.array.') + + if invalid_columns: + raise ValueError(f'Invalid columns found: {invalid_columns}') + + @random_state + def fit(self, train_data, discrete_columns=(), epochs=None): + """Fit the CTGAN Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self._validate_discrete_columns(train_data, discrete_columns) + + if epochs is None: + epochs = self._epochs + else: + warnings.warn( + ('`epochs` argument in `fit` method has been deprecated and will be removed ' + 'in a future version. Please pass `epochs` to the constructor instead'), + DeprecationWarning + ) + + self._transformer = DataTransformer() + self._transformer.fit(train_data, discrete_columns) + + train_data = self._transformer.transform(train_data) + + self._data_sampler = DataSampler( + train_data, + self._transformer.output_info_list, + self._log_frequency) + + data_dim = self._transformer.output_dimensions + + self._generator = Generator( + self._embedding_dim + self._data_sampler.dim_cond_vec(), + self._generator_dim, + data_dim + ).to(self._device) + + discriminator = Discriminator( + data_dim + self._data_sampler.dim_cond_vec(), + self._discriminator_dim, + pac=self.pac + ).to(self._device) + + optimizerG = optim.Adam( + self._generator.parameters(), lr=self._generator_lr, betas=(0.5, 0.9), + weight_decay=self._generator_decay + ) + + optimizerD = optim.Adam( + discriminator.parameters(), lr=self._discriminator_lr, + betas=(0.5, 0.9), weight_decay=self._discriminator_decay + ) + + mean = torch.zeros(self._batch_size, self._embedding_dim, device=self._device) + std = mean + 1 + + print('CTGAN training') + steps_per_epoch = max(len(train_data) // self._batch_size, 1) + for i in range(epochs): + for n in range(self._discriminator_steps): + fakez = torch.normal(mean=mean, std=std) + + condvec = self._data_sampler.sample_condvec(self._batch_size) + if condvec is None: + c1, m1, col, opt = None, None, None, None + real = self._data_sampler.sample_data(self._batch_size, col, opt) + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + perm = np.arange(self._batch_size) + np.random.shuffle(perm) + real = self._data_sampler.sample_data( + self._batch_size, col[perm], opt[perm]) + c2 = c1[perm] + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + real = torch.from_numpy(real.astype('float32')).to(self._device) + + if c1 is not None: + fake_cat = torch.cat([fakeact, c1], dim=1) + real_cat = torch.cat([real, c2], dim=1) + else: + real_cat = real + fake_cat = fakeact + + y_fake = discriminator(fake_cat) + y_real = discriminator(real_cat) + + pen = discriminator.calc_gradient_penalty( + real_cat, fake_cat, self._device, self.pac) + loss_d = -(torch.mean(y_real) - torch.mean(y_fake)) + + optimizerD.zero_grad() + pen.backward(retain_graph=True) + loss_d.backward() + optimizerD.step() + + fakez = torch.normal(mean=mean, std=std) + condvec = self._data_sampler.sample_condvec(self._batch_size) + + if condvec is None: + c1, m1, col, opt = None, None, None, None + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + if c1 is not None: + y_fake = discriminator(torch.cat([fakeact, c1], dim=1)) + else: + y_fake = discriminator(fakeact) + + if condvec is None: + cross_entropy = 0 + else: + cross_entropy = self._cond_loss(fake, c1, m1) + + loss_g = -torch.mean(y_fake) + cross_entropy + + optimizerG.zero_grad() + loss_g.backward() + optimizerG.step() + + if self._verbose and (i + 1) % 1000 == 0: + print(f'Epoch {i+1}, Loss G: {loss_g.detach().cpu(): .4f},' # noqa: T001 + f'Loss D: {loss_d.detach().cpu(): .4f}', + flush=True) + + @random_state + def sample(self, n, condition_column=None, condition_value=None): + """Sample data similar to the training data. + + Choosing a condition_column and condition_value will increase the probability of the + discrete condition_value happening in the condition_column. + + Args: + n (int): + Number of rows to sample. + condition_column (string): + Name of a discrete column. + condition_value (string): + Name of the category in the condition_column which we wish to increase the + probability of happening. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + if condition_column is not None and condition_value is not None: + condition_info = self._transformer.convert_column_name_value_to_id( + condition_column, condition_value) + global_condition_vec = self._data_sampler.generate_cond_from_condition_column_info( + condition_info, self._batch_size) + else: + global_condition_vec = None + + steps = n // self._batch_size + 1 + data = [] + for i in range(steps): + mean = torch.zeros(self._batch_size, self._embedding_dim) + std = mean + 1 + fakez = torch.normal(mean=mean, std=std).to(self._device) + + if global_condition_vec is not None: + condvec = global_condition_vec.copy() + else: + condvec = self._data_sampler.sample_original_condvec(self._batch_size) + + if condvec is None: + pass + else: + c1 = condvec + c1 = torch.from_numpy(c1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:n] + + return self._transformer.inverse_transform(data) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + if self._generator is not None: + self._generator.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..1baa3f38a8157b80fb866c205491616543fb0470 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py @@ -0,0 +1,218 @@ +"""TVAESynthesizer module.""" + +import numpy as np +import torch +from torch.nn import Linear, Module, Parameter, ReLU, Sequential +from torch.nn.functional import cross_entropy +from torch.optim import Adam +from torch.utils.data import DataLoader, TensorDataset + +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Encoder(Module): + """Encoder for the TVAESynthesizer. + + Args: + data_dim (int): + Dimensions of the data. + compress_dims (tuple or list of ints): + Size of each hidden layer. + embedding_dim (int): + Size of the output vector. + """ + + def __init__(self, data_dim, compress_dims, embedding_dim): + super(Encoder, self).__init__() + dim = data_dim + seq = [] + for item in list(compress_dims): + seq += [ + Linear(dim, item), + ReLU() + ] + dim = item + + self.seq = Sequential(*seq) + self.fc1 = Linear(dim, embedding_dim) + self.fc2 = Linear(dim, embedding_dim) + + def forward(self, input_): + """Encode the passed `input_`.""" + feature = self.seq(input_) + mu = self.fc1(feature) + logvar = self.fc2(feature) + std = torch.exp(0.5 * logvar) + return mu, std, logvar + + +class Decoder(Module): + """Decoder for the TVAESynthesizer. + + Args: + embedding_dim (int): + Size of the input vector. + decompress_dims (tuple or list of ints): + Size of each hidden layer. + data_dim (int): + Dimensions of the data. + """ + + def __init__(self, embedding_dim, decompress_dims, data_dim): + super(Decoder, self).__init__() + dim = embedding_dim + seq = [] + for item in list(decompress_dims): + seq += [Linear(dim, item), ReLU()] + dim = item + + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + self.sigma = Parameter(torch.ones(data_dim) * 0.1) + + def forward(self, input_): + """Decode the passed `input_`.""" + return self.seq(input_), self.sigma + + +def _loss_function(recon_x, x, sigmas, mu, logvar, output_info, factor): + st = 0 + loss = [] + for column_info in output_info: + for span_info in column_info: + if span_info.activation_fn != 'softmax': + ed = st + span_info.dim + std = sigmas[st] + eq = x[:, st] - torch.tanh(recon_x[:, st]) + loss.append((eq ** 2 / 2 / (std ** 2)).sum()) + loss.append(torch.log(std) * x.size()[0]) + st = ed + + else: + ed = st + span_info.dim + loss.append(cross_entropy( + recon_x[:, st:ed], torch.argmax(x[:, st:ed], dim=-1), reduction='sum')) + st = ed + + assert st == recon_x.size()[1] + KLD = -0.5 * torch.sum(1 + logvar - mu**2 - logvar.exp()) + return sum(loss) * factor / x.size()[0], KLD / x.size()[0] + + +class TVAESynthesizer(BaseSynthesizer): + """TVAESynthesizer.""" + + def __init__( + self, + embedding_dim=128, + compress_dims=(128, 128), + decompress_dims=(128, 128), + l2scale=1e-5, + batch_size=500, + epochs=300, + lr=1e-3, + loss_factor=2, + device="cuda:0" + ): + self.embedding_dim = embedding_dim + self.compress_dims = compress_dims + self.decompress_dims = decompress_dims + + self.lr = lr + self.l2scale = l2scale + self.batch_size = batch_size + self.loss_factor = loss_factor + self.epochs = epochs + + + self._device = torch.device(device) + + @random_state + def fit(self, train_data, discrete_columns=()): + """Fit the TVAE Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self.transformer = DataTransformer() + self.transformer.fit(train_data, discrete_columns) + train_data = self.transformer.transform(train_data) + dataset = TensorDataset(torch.from_numpy(train_data.astype('float32'))) + loader = DataLoader(dataset, batch_size=self.batch_size, shuffle=True, drop_last=False) + + data_dim = self.transformer.output_dimensions + encoder = Encoder(data_dim, self.compress_dims, self.embedding_dim).to(self._device) + self.decoder = Decoder(self.embedding_dim, self.decompress_dims, data_dim).to(self._device) + optimizerAE = Adam( + list(encoder.parameters()) + list(self.decoder.parameters()), + lr=self.lr, + weight_decay=self.l2scale) + data_iter = iter(loader) + print('Training:') + for i in range(self.epochs): + try: + data = next(data_iter) + except: + data_iter = iter(loader) + data = next(data_iter) + + optimizerAE.zero_grad() + real = data[0].to(self._device) + mu, std, logvar = encoder(real) + eps = torch.randn_like(std) + emb = eps * std + mu + rec, sigmas = self.decoder(emb) + loss_1, loss_2 = _loss_function( + rec, real, sigmas, mu, logvar, + self.transformer.output_info_list, self.loss_factor + ) + loss = loss_1 + loss_2 + loss.backward() + optimizerAE.step() + self.decoder.sigma.data.clamp_(0.01, 1.0) + if (i + 1) % 1000 == 0: + print(f"{i + 1}/{self.epochs} {loss}", flush=True) + + @random_state + def sample(self, samples, seed=0): + """Sample data similar to the training data. + + Args: + samples (int): + Number of rows to sample. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + + torch.cuda.manual_seed(seed) + torch.manual_seed(seed) + + self.decoder.eval() + + sample_batch_size = 8092 + steps = samples // sample_batch_size + 1 + data = [] + for _ in range(steps): + mean = torch.zeros(sample_batch_size, self.embedding_dim) + std = mean + 1 + noise = torch.normal(mean=mean, std=std).to(self._device) + fake, sigmas = self.decoder(noise) + fake = torch.tanh(fake) + data.append(fake.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:samples] + return self.transformer.inverse_transform(data, sigmas.detach().cpu().numpy()) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + self.decoder.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg new file mode 100644 index 0000000000000000000000000000000000000000..8398eee0de75e378fa157456b8594f9ec383c45c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg @@ -0,0 +1,59 @@ +[bumpversion] +current_version = 0.5.2.dev0 +commit = True +tag = True +parse = (?P\d+)\.(?P\d+)\.(?P\d+)(\.(?P[a-z]+)(?P\d+))? +serialize = + {major}.{minor}.{patch}.{release}{candidate} + {major}.{minor}.{patch} + +[bumpversion:part:release] +optional_value = release +first_value = dev +values = + dev + release + +[bumpversion:part:candidate] + +[bumpversion:file:setup.py] +search = version='{current_version}' +replace = version='{new_version}' + +[bumpversion:file:ctgan/__init__.py] +search = __version__ = '{current_version}' +replace = __version__ = '{new_version}' + +[bumpversion:file:conda/meta.yaml] +search = version = '{current_version}' +replace = version = '{new_version}' + +[bdist_wheel] +universal = 1 + +[flake8] +convention = google +max-line-length = 99 +exclude = docs, .tox, .git, __pycache__, .ipynb_checkpoints +extend-ignore = D107, # Missing docstring in __init__ + D407, # Missing dashed underline after section + D417, # Missing argument descriptions in the docstring + SFS3, # String literal formatting using f-string. + VNE001 # Single letter variable names are not allowed +per-file-ignores = + ctgan/data.py:T001 + +[isort] +include_trailing_comment = True +line_length = 99 +lines_between_types = 0 +multi_line_output = 4 +not_skip = __init__.py +use_parentheses = True + +[aliases] +test = pytest + +[tool:pytest] +collect_ignore = ['setup.py'] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.py new file mode 100644 index 0000000000000000000000000000000000000000..83d973eb603ce5a4f4dc31f3bac459eeabdd1ec5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/setup.py @@ -0,0 +1,119 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""The setup script.""" + +from setuptools import find_packages, setup + +with open('README.md', encoding='utf-8') as readme_file: + readme = readme_file.read() + +with open('HISTORY.md', encoding='utf-8') as history_file: + history = history_file.read() + +install_requires = [ + 'packaging>=20,<22', + "numpy>=1.18.0,<1.20.0;python_version<'3.7'", + "numpy>=1.20.0,<2;python_version>='3.7'", + 'pandas>=1.1.3,<2', + 'scikit-learn>=0.24,<2', + 'torch>=1.8.0,<2', + 'torchvision>=0.9.0,<1', + 'rdt>=0.6.2,<0.7', +] + +setup_requires = [ + 'pytest-runner>=2.11.1', +] + +tests_require = [ + 'pytest>=3.4.2', + 'pytest-rerunfailures>=9.1.1,<10', + 'pytest-cov>=2.6.0', +] + +development_requires = [ + # general + 'pip>=9.0.1', + 'bumpversion>=0.5.3,<0.6', + 'watchdog>=0.8.3,<0.11', + + # style check + 'flake8>=3.7.7,<4', + 'isort>=4.3.4,<5', + 'dlint>=0.11.0,<0.12', # code security addon for flake8 + 'flake8-debugger>=4.0.0,<4.1', + 'flake8-mock>=0.3,<0.4', + 'flake8-mutable>=1.2.0,<1.3', + 'flake8-absolute-import>=1.0,<2', + 'flake8-multiline-containers>=0.0.18,<0.1', + 'flake8-print>=4.0.0,<4.1', + 'flake8-quotes>=3.3.0,<4', + 'flake8-fixme>=1.1.1,<1.2', + 'flake8-expression-complexity>=0.0.9,<0.1', + 'flake8-eradicate>=1.1.0,<1.2', + 'flake8-builtins>=1.5.3,<1.6', + 'flake8-variables-names>=0.0.4,<0.1', + 'pandas-vet>=0.2.2,<0.3', + 'flake8-comprehensions>=3.6.1,<3.7', + 'dlint>=0.11.0,<0.12', + 'flake8-docstrings>=1.5.0,<2', + 'flake8-sfs>=0.0.3,<0.1', + 'flake8-pytest-style>=1.5.0,<2', + + # fix style issues + 'autoflake>=1.1,<2', + 'autopep8>=1.4.3,<1.6', + + # distribute on PyPI + 'twine>=1.10.0,<4', + 'wheel>=0.30.0', + + # Advanced testing + 'coverage>=4.5.1,<6', + 'tox>=2.9.1,<4', + + 'invoke', +] + +setup( + author='MIT Data To AI Lab', + author_email='dailabmit@gmail.com', + classifiers=[ + 'Development Status :: 2 - Pre-Alpha', + 'Intended Audience :: Developers', + 'License :: OSI Approved :: MIT License', + 'Natural Language :: English', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + ], + description='Conditional GAN for Tabular Data', + entry_points={ + 'console_scripts': [ + 'ctgan=ctgan.__main__:main' + ], + }, + extras_require={ + 'test': tests_require, + 'dev': development_requires + tests_require, + }, + install_package_data=True, + install_requires=install_requires, + license='MIT license', + long_description=readme + '\n\n' + history, + long_description_content_type='text/markdown', + include_package_data=True, + keywords='ctgan CTGAN', + name='ctgan', + packages=find_packages(include=['ctgan', 'ctgan.*']), + python_requires='>=3.6,<3.10', + setup_requires=setup_requires, + test_suite='tests', + tests_require=tests_require, + url='https://github.com/sdv-dev/CTGAN', + version='0.5.2.dev0', + zip_safe=False, +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tasks.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tasks.py new file mode 100644 index 0000000000000000000000000000000000000000..78730cea28cec928ff175364db655f10abe6143e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tasks.py @@ -0,0 +1,121 @@ +import glob +import operator +import os +import re +import platform +import shutil +import stat +from pathlib import Path + +from invoke import task + +COMPARISONS = { + '>=': operator.ge, + '>': operator.gt, + '<': operator.lt, + '<=': operator.le +} + + +@task +def check_dependencies(c): + c.run('python -m pip check') + + +@task +def unit(c): + c.run('python -m pytest ./tests/unit --cov=ctgan --cov-report=xml') + + +@task +def integration(c): + c.run('python -m pytest ./tests/integration --reruns 3') + + +@task +def readme(c): + test_path = Path('tests/readme_test') + if test_path.exists() and test_path.is_dir(): + shutil.rmtree(test_path) + + cwd = os.getcwd() + os.makedirs(test_path, exist_ok=True) + shutil.copy('README.md', test_path / 'README.md') + os.chdir(test_path) + c.run('rundoc run --single-session python3 -t python3 README.md') + os.chdir(cwd) + shutil.rmtree(test_path) + + +def _validate_python_version(line): + python_version_match = re.search(r"python_version(<=?|>=?)\'(\d\.?)+\'", line) + if python_version_match: + python_version = python_version_match.group(0) + comparison = re.search(r'(>=?|<=?)', python_version).group(0) + version_number = python_version.split(comparison)[-1].replace("'", "") + comparison_function = COMPARISONS[comparison] + return comparison_function(platform.python_version(), version_number) + + return True + + +@task +def install_minimum(c): + with open('setup.py', 'r') as setup_py: + lines = setup_py.read().splitlines() + + versions = [] + started = False + for line in lines: + if started: + if line == ']': + started = False + continue + + line = line.strip() + if _validate_python_version(line): + requirement = re.match(r'[^>]*', line).group(0) + requirement = re.sub(r"""['",]""", '', requirement) + version = re.search(r'>=?[^(,|#)]*', line).group(0) + if version: + version = re.sub(r'>=?', '==', version) + version = re.sub(r"""['",]""", '', version) + requirement += version + + versions.append(requirement) + + elif (line.startswith('install_requires = [') or + line.startswith('pomegranate_requires = [')): + started = True + + c.run(f'python -m pip install {" ".join(versions)}') + + +@task +def minimum(c): + install_minimum(c) + check_dependencies(c) + unit(c) + integration(c) + + +@task +def lint(c): + check_dependencies(c) + c.run('flake8 ctgan') + c.run('flake8 tests --ignore=D101') + c.run('isort -c --recursive ctgan tests') + + +def remove_readonly(func, path, _): + "Clear the readonly bit and reattempt the removal" + os.chmod(path, stat.S_IWRITE) + func(path) + + +@task +def rmdir(c, path): + try: + shutil.rmtree(path, onerror=remove_readonly) + except PermissionError: + pass diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a750d3dabc716a49fb722dbbb87e7a2120fc5fd4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py @@ -0,0 +1,275 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for ctgan. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import tempfile as tf + +import numpy as np +import pandas as pd +import pytest + +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def test_ctgan_no_categoricals(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000) + }) + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, []) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 1) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous'} + + +def test_ctgan_dataframe(): + """Test the CTGANSynthesizer when passed a dataframe.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_ctgan_numpy(): + """Test the CTGANSynthesizer when passed a numpy array.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = [1] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data.to_numpy(), discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, np.ndarray) + assert set(np.unique(sampled[:, 1])) == {'a', 'b', 'c'} + + +def test_log_frequency(): + """Test the CTGANSynthesizer with no `log_frequency` set to False.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000), + 'discrete': np.repeat(['a', 'b', 'c'], [950, 25, 25]) + }) + + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] < 6500 + + ctgan = CTGANSynthesizer(log_frequency=False, epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] > 9000 + + +def test_categorical_nan(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(30), + # This must be a list (not a np.array) or NaN will be cast to a string. + 'discrete': [np.nan, 'b', 'c'] * 10 + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + + # since np.nan != np.nan, we need to be careful here + values = set(sampled['discrete'].unique()) + assert len(values) == 3 + assert any(pd.isna(x) for x in values) + assert {'b', 'c'}.issubset(values) + + +def test_synthesizer_sample(): + """Test the CTGANSynthesizer samples the correct datatype.""" + data = pd.DataFrame({ + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + samples = ctgan.sample(1000, 'discrete', 'a') + assert isinstance(samples, pd.DataFrame) + + +def test_save_load(): + """Test the CTGANSynthesizer load/save methods.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with tf.TemporaryDirectory() as temporary_directory: + ctgan.save(temporary_directory + 'test_tvae.pkl') + ctgan = CTGANSynthesizer.load(temporary_directory + 'test_tvae.pkl') + + sampled = ctgan.sample(1000) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_wrong_discrete_columns_dataframe(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['b', 'c'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match="Invalid columns found: {'.*', '.*'}"): + ctgan.fit(data, discrete_columns) + + +def test_wrong_discrete_columns_numpy(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = [0, 1] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: \[1\]'): + ctgan.fit(data.to_numpy(), discrete_columns) + + +def test_wrong_sampling_conditions(): + """Test the CTGANSynthesizer correctly crashes when passed incorrect sampling conditions.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with pytest.raises(ValueError, match="The column_name `cardinal` doesn't exist in the data."): + ctgan.sample(1, 'cardinal', "doesn't matter") + + with pytest.raises(ValueError): # noqa: RDT currently incorrectly raises a tuple instead of a string + ctgan.sample(1, 'discrete', 'd') + + +def test_fixed_random_seed(): + """Test the CTGANSynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + + # Run + ctgan.fit(data, discrete_columns) + sampled_random = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_0_0 = ctgan.sample(10) + sampled_0_1 = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_1_0 = ctgan.sample(10) + sampled_1_1 = ctgan.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) + + +# Below are CTGAN tests that should be implemented in the future +def test_continuous(): + """Test training the CTGAN synthesizer on a continuous dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using kstest: + # - uniform (assert p-value > 0.05) + # - gaussian (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical(): + """Test training the CTGAN synthesizer on a categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical_log_frequency(): + """Test training the CTGAN synthesizer on a small categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_mixed(): + """Test training the CTGAN synthesizer on a small mixed-type dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test_conditional(): + """Test training the CTGAN synthesizer and sampling conditioned on a categorical.""" + # verify that conditioning increases the likelihood of getting a sample with the specified + # categorical value + + +def test_batch_size_pack_size(): + """Test that if batch size is not a multiple of pack size, it raises a sane error.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..ab8c583e0dd11fee3e1ce3d5cd4ac8f0a847a192 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py @@ -0,0 +1,131 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for tvae. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import numpy as np +import pandas as pd +from sklearn import datasets + +from ctgan.synthesizers.tvae import TVAESynthesizer + + +def test_tvae(tmpdir): + """Test the TVAESynthesizer load/save methods.""" + iris = datasets.load_iris() + data = pd.DataFrame(iris.data, columns=iris.feature_names) + data['class'] = pd.Series(iris.target).map(iris.target_names.__getitem__) + + tvae = TVAESynthesizer(epochs=10) + tvae.fit(data, ['class']) + + path = str(tmpdir / 'test_tvae.pkl') + tvae.save(path) + tvae = TVAESynthesizer.load(path) + + sampled = tvae.sample(100) + + assert sampled.shape == (100, 5) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == set(data.columns) + assert set(sampled.dtypes) == set(data.dtypes) + + +def test_drop_last_false(): + """Test the TVAESynthesizer predicts the correct values.""" + data = pd.DataFrame({ + '1': ['a', 'b', 'c'] * 150, + '2': ['a', 'b', 'c'] * 150 + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data, ['1', '2']) + + sampled = tvae.sample(100) + correct = 0 + for _, row in sampled.iterrows(): + if row['1'] == row['2']: + correct += 1 + + assert correct >= 95 + + +# TVAE tests that should be implemented in the future. +def test_continuous(): + """Test training the TVAE synthesizer on a small continuous dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest. + + +def test_categorical(): + """Test training the TVAE synthesizer on a small categorical dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a cstest. + + +def test_mixed(): + """Test training the TVAE synthesizer on a small mixed-type dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test__loss_function(): + """Test the TVAESynthesizer produces average values similar to the training data.""" + data = pd.DataFrame({ + '1': [float(i) for i in range(1000)], + '2': [float(2 * i) for i in range(1000)] + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data) + + num_samples = 1000 + sampled = tvae.sample(num_samples) + error = 0 + for _, row in sampled.iterrows(): + error += abs(2 * row['1'] - row['2']) + + avg_error = error / num_samples + + assert avg_error < 400 + + +def test_fixed_random_seed(): + """Test the TVAESynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + tvae = TVAESynthesizer(epochs=1) + + # Run + tvae.fit(data, discrete_columns) + sampled_random = tvae.sample(10) + + tvae.set_random_state(0) + sampled_0_0 = tvae.sample(10) + sampled_0_1 = tvae.sample(10) + + tvae.set_random_state(0) + sampled_1_0 = tvae.sample(10) + sampled_1_1 = tvae.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..2f0314ca08a4cbd05d2dba7560edeeab57780306 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py @@ -0,0 +1,42 @@ +"""Data transformer intergration testing module.""" + + +# Data Transformer tests that should be implemented in the future. +def test_constant(): + """Test transforming a dataframe containing constant values.""" + + +def test_df_continuous(): + """Test transforming a dataframe containing only continuous values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is **not** deterministic + # make sure it can be inverted + + +def test_df_categorical(): + """Test transforming a dataframe containing only categorical values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is deterministic + # make sure it can be inverted + + +def test_df_mixed(): + """Test transforming a dataframe containing mixed data types.""" + + +def test_df_mixed_nan(): + """Test transforming a dataframe containing mixed data types + NaN for categoricals.""" + + +def test_np_continuous(): + """Test transforming a np.array containing only continuous values.""" + + +def test_np_categorical(): + """Test transforming a np.array containing only categorical values.""" + + +def test_np_mixed(): + """Test transforming a np.array containing mixed data types.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..60ff4d04eff14032ccb698a80a37aa16cb4ff1ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py @@ -0,0 +1 @@ +"""Unit testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..80d7afbb190ef7d1204849cae14f6a89312c39f7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py @@ -0,0 +1 @@ +"""CTGANSynthesizer testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py new file mode 100644 index 0000000000000000000000000000000000000000..5859d93deb2bebe6f07faf0a7c3b08c841e66546 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py @@ -0,0 +1,111 @@ + +"""BaseSynthesizer unit testing module.""" + +from unittest.mock import MagicMock, call, patch + +import numpy as np +import torch + +from ctgan.synthesizers.base import BaseSynthesizer, random_state + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_valid_random_state(random_mock, torch_mock): + """Test the ``random_state`` attribute with a valid random state. + + Expect that the decorated function uses the random_state attribute. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + + random_state_mock = MagicMock() + random_state_mock.get_state.return_value = 'desired numpy state' + torch_generator_mock = MagicMock() + torch_generator_mock.get_state.return_value = 'desired torch state' + instance.random_states = (random_state_mock, torch_generator_mock) + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + random_mock.RandomState.return_value = random_state_mock + random_mock.get_state.return_value = 'random state' + torch_mock.Generator.return_value = torch_generator_mock + torch_mock.get_rng_state.return_value = 'torch random state' + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + assert random_mock.get_state.call_count == 2 + assert torch_mock.get_rng_state.call_count == 2 + random_mock.RandomState.assert_has_calls( + [call().get_state(), call(), call().set_state('random state')]) + random_mock.set_state.assert_has_calls([call('desired numpy state'), call('random state')]) + torch_mock.set_rng_state.assert_has_calls( + [call('desired torch state'), call('torch random state')]) + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_no_random_seed(random_mock, torch_mock): + """Test the ``random_state`` attribute with no random state. + + Expect that the decorated function calls the original function + when there is no random state. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + instance.random_states = None + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + random_mock.get_state.assert_not_called() + random_mock.RandomState.assert_not_called() + random_mock.set_state.assert_not_called() + torch_mock.get_rng_state.assert_not_called() + torch_mock.Generator.assert_not_called() + torch_mock.set_rng_state.assert_not_called() + + +class TestBaseSynthesizer: + + def test_set_random_state(self): + """Test ``set_random_state`` works as expected.""" + # Setup + instance = BaseSynthesizer() + + # Run + instance.set_random_state(3) + + # Assert + assert isinstance(instance.random_states, tuple) + assert isinstance(instance.random_states[0], np.random.RandomState) + assert isinstance(instance.random_states[1], torch.Generator) + + def test_set_random_state_with_none(self): + """Test ``set_random_state`` with None.""" + # Setup + instance = BaseSynthesizer() + + # Run and assert + instance.set_random_state(3) + assert instance.random_states is not None + + instance.set_random_state(None) + assert instance.random_states is None diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..7a724d30779cea4e9512fc480e8417c17a21da7a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py @@ -0,0 +1,343 @@ +"""CTGANSynthesizer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock + +import pandas as pd +import pytest +import torch + +from ctgan.data_transformer import SpanInfo +from ctgan.synthesizers.ctgan import CTGANSynthesizer, Discriminator, Generator, Residual + + +class TestDiscriminator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 3*`discriminator_dim` + 1. + + Setup: + - Create Discriminator + + Input: + - input_dim = positive integer + - discriminator_dim = list of integers + - pack = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.pack` and `self.packdim` + """ + discriminator_dim = [1, 2, 3] + discriminator = Discriminator(input_dim=50, discriminator_dim=discriminator_dim, pac=7) + + assert discriminator.pac == 7 + assert discriminator.pacdim == 350 + assert len(discriminator.seq) == 3 * len(discriminator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. Notice that the input_dim = input_size. + + Setup: + - initialize with input_size, discriminator_dim, pac + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N/pac, 1) + """ + discriminator = Discriminator(input_dim=50, discriminator_dim=[100, 200, 300], pac=7) + output = discriminator(torch.randn(70, 50)) + assert output.shape == (10, 1) + + # Check to make sure no gradients attached + for parameter in discriminator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in discriminator.parameters(): + assert parameter.grad is not None + + +class TestResidual(TestCase): + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with input_size, output_size + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, input_size + output_size) + """ + residual = Residual(10, 2) + output = residual(torch.randn(100, 10)) + assert output.shape == (100, 12) + + # Check to make sure no gradients attached + for parameter in residual.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in residual.parameters(): + assert parameter.grad is not None + + +class TestGenerator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure `self.seq` has same length as `generator_dim` + 1. + + Setup: + - Create Generator + + Input: + - embedding_dim = positive integer + - generator_dim = list of integers + - data_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq` + """ + generator_dim = [1, 2, 3] + generator = Generator(embedding_dim=50, generator_dim=generator_dim, data_dim=7) + + assert len(generator.seq) == len(generator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with embedding_dim, generator_dim, data_dim + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, data_dim) + """ + generator = Generator(embedding_dim=60, generator_dim=[100, 200, 300], data_dim=500) + output = generator(torch.randn(70, 60)) + assert output.shape == (70, 500) + + # Check to make sure no gradients attached + for parameter in generator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in generator.parameters(): + assert parameter.grad is not None + + +def _assert_is_between(data, lower, upper): + """Assert all values of the tensor 'data' are within range.""" + assert all((data >= lower).numpy().tolist()) + assert all((data <= upper).numpy().tolist()) + + +class TestCTGANSynthesizer(TestCase): + + def test__apply_activate_(self): + """Test `_apply_activate` for tables with both continuous and categoricals. + + Check every continuous column has all values between -1 and 1 + (since they are normalized), and check every categorical column adds up to 1. + + Setup: + - Mock `self._transformer.output_info_list` + + Input: + - data = tensor of shape (N, data_dims) + + Output: + - tensor = tensor of shape (N, data_dims) + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(3, 'softmax')], + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')] + ] + + data = torch.randn(100, 6) + result = model._apply_activate(data) + + assert result.shape == (100, 6) + _assert_is_between(result[:, 0:3], 0.0, 1.0) + _assert_is_between(result[: 3], -1.0, 1.0) + _assert_is_between(result[:, 4:6], 0.0, 1.0) + + def test__cond_loss(self): + """Test `_cond_loss`. + + Test that the loss is purely a function of the target categorical. + + Setup: + - mock transformer.output_info_list + - create two categoricals, one continuous + - compute the conditional loss, conditioned on the 1st categorical + - compare the loss to the cross-entropy of the 1st categorical, manually computed + + Input: + data - the synthetic data generated by the model + c - a tensor with the same shape as the data but with only a specific one-hot vector + corresponding to the target column filled in + m - binary mask used to select the categorical column to condition on + + Output: + loss scalar; this should only be affected by the target column + + Note: + - even though the implementation of this is probably right, I'm not sure if the idea + behind it is correct + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')], + [SpanInfo(3, 'softmax')], # this is the categorical column we are conditioning on + [SpanInfo(2, 'softmax')], # this is the categorical column we are bry jrbec on + ] + + data = torch.tensor([ + # first 3 dims ignored, next 3 dims are the prediction, last 2 dims are ignored + [0.0, -1.0, 0.0, 0.05, 0.05, 0.9, 0.1, 0.4], + ]) + + c = torch.tensor([ + # first 3 dims are a one-hot for the categorical, + # next 2 are for a different categorical that we are not conditioning on + # (continuous values are not stored in this tensor) + [0.0, 0.0, 1.0, 0.0, 0.0], + ]) + + # this indicates that we are conditioning on the first categorical + m = torch.tensor([[1, 0]]) + + result = model._cond_loss(data, c, m) + expected = torch.nn.functional.cross_entropy( + torch.tensor([ + [0.05, 0.05, 0.9], # 3 categories, one hot + ]), + torch.tensor([2]) + ) + + assert (result - expected).abs() < 1e-3 + + def test__validate_discrete_columns(self): + """Test `_validate_discrete_columns` if the discrete column doesn't exist. + + Check the appropriate error is raised if `discrete_columns` is invalid, both + for numpy arrays and dataframes. + + Setup: + - Create dataframe with a discrete column + - Define `discrete_columns` as something not in the dataframe + + Input: + - train_data = 2-dimensional numpy array or a pandas.DataFrame + - discrete_columns = list of strings or integers + + Output: + None + + Side Effects: + - Raises error if the discrete column is invalid. + + Note: + - could create another function for numpy array + """ + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['doesnt exist'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: {\'doesnt exist\'}'): + ctgan.fit(data, discrete_columns) + + def test_sample(self): + """Test `sample` correctly sets `condition_info` and `global_condition_vec`. + + Tests the first 7 lines of sample by mocking the DataTransformer and DataSampler + and checking that they are being correctly used. + + Setup: + - Create and fit the synthesizer + - Mock DataTransformer, DataSampler + + Input: + - n = integer + - condition_column = string (not None) + - condition_value = string (not None) + + Output: + Not relevant + + Note: + - I'm not sure we need this test + """ + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cff981a86078d1689bec7bb5a37856aa903b68e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py @@ -0,0 +1,123 @@ +"""TVAESynthesizer unit testing module.""" + +from unittest import TestCase + + +class TestEncoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`compress_dims`. + + Setup: + - Create Encoder + + Input: + - data_dim = positive integer + - compress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.fc1` and `self.fc2` + """ + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct and that std is positive. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(mu) + torch.mean(std) + torch.mean(logvar)`. + + Setup: + - Create random tensor + + Input: + - input = random tensor of shape (N, data_dim) + + Output: + - Tuple of (mu, std, logvar): + mu - tensor of shape (N, embedding_dim) + std - tensor of shape (N, embedding_dim), non-negative values + logvar - tensor of shape (N, embedding_dim) + """ + + +class TestDecoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`decompress_dims` + 1. + + Setup: + - Create Decoder + + Input: + - data_dim = positive integer + - decompress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.sigma` + """ + + +class TestLossFunction(TestCase): + + def test__loss_function(self): + """Test `_loss_function`. + + Check loss values = to specific numbers. + + Setup: + Build all the tensors, lists, etc. + + Input: + recon_x = tensor of shape (N, data_dims) + x = tensor of shape (N, data_dims) + sigmas = tensor of shape (N,) + mu = tensor of shape (N,) + logvar = tensor of shape (N,) + output_info = list of SpanInfo objects from the data transformer, + including at least 1 continuous and 1 discrete + factor = scalar + + Output: + reconstruction loss = scalar = f(recon_x, x, sigmas, output_info, factor) + kld loss = scalar = f(logvar, mu) + """ + + +class TestTVAESynthesizer(TestCase): + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..305f84ee5e57d156348b54400a5c6138d3466b40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py @@ -0,0 +1,473 @@ +"""Data transformer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock, patch + +import numpy as np +import pandas as pd + +from ctgan.data_transformer import ColumnTransformInfo, DataTransformer, SpanInfo + + +class TestDataTransformer(TestCase): + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test___fit_continuous(self, MockBGM): + """Test ``_fit_continuous`` on a simple continuous column. + + A ``BayesGMMTransformer`` will be created and fit with some ``data``. + + Setup: + - Mock the ``BayesGMMTransformer`` with ``valid_component_indicator`` as + ``[True, False, True]``. + - Initialize a ``DataTransformer``. + + Input: + - A dataframe with only one column containing random float values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``BayesGMMTransformer`` instance. + - ``output_dimensions`` is 3 (matches size of ``valid_component_indicator``). + - ``output_info`` assigns the correct activation functions. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.valid_component_indicator = [True, False, True] + transformer = DataTransformer() + data = pd.DataFrame(np.random.normal((100, 1)), columns=['column']) + + # Run + info = transformer._fit_continuous(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == bgm_instance + assert info.output_dimensions == 3 + assert info.output_info[0].dim == 1 + assert info.output_info[0].activation_fn == 'tanh' + assert info.output_info[1].dim == 2 + assert info.output_info[1].activation_fn == 'softmax' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__fit_continuous_max_clusters(self, MockBGM): + """Test ``_fit_continuous`` with data that has less than 10 rows. + + Expect that a ``BayesGMMTransformer`` is created with the max number of clusters + set to the length of the data. + + Input: + - Data with less than 10 rows. + + Side Effects: + - A ``BayesGMMTransformer`` is created with the max number of clusters set to the + length of the data. + """ + # Setup + data = pd.DataFrame(np.random.normal((7, 1)), columns=['column']) + transformer = DataTransformer() + + # Run + transformer._fit_continuous(data) + + # Assert + MockBGM.assert_called_once_with(max_clusters=len(data)) + + @patch('ctgan.data_transformer.OneHotEncodingTransformer') + def test___fit_discrete(self, MockOHE): + """Test ``_fit_discrete_`` on a simple discrete column. + + A ``OneHotEncodingTransformer`` will be created and fit with the ``data``. + + Setup: + - Mock the ``OneHotEncodingTransformer``. + - Create ``DataTransformer``. + + Input: + - A dataframe with only one column containing ``['a', 'b']`` values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``OneHotEncodingTransformer`` instance. + - ``output_dimensions`` is 2. + - ``output_info`` assigns the correct activation function. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + ohe_instance = MockOHE.return_value + ohe_instance.dummies = ['a', 'b'] + transformer = DataTransformer() + data = pd.DataFrame(np.array(['a', 'b'] * 100), columns=['column']) + + # Run + info = transformer._fit_discrete(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == ohe_instance + assert info.output_dimensions == 2 + assert info.output_info[0].dim == 2 + assert info.output_info[0].activation_fn == 'softmax' + + def test_fit(self): + """Test ``fit`` on a np.ndarray with one continuous and one discrete columns. + + The ``fit`` method should: + - Set ``self.dataframe`` to ``False``. + - Set ``self._column_raw_dtypes`` to the appropirate dtypes. + - Use the appropriate ``_fit`` type for each column. + - Update ``self.output_info_list``, ``self.output_dimensions`` and + ``self._column_transform_info_list`` appropriately. + + Setup: + - Create ``DataTransformer``. + - Mock ``_fit_discrete``. + - Mock ``_fit_continuous``. + + Input: + - A table with one continuous and one discrete columns. + - A list with the name of the discrete column. + + Side Effects: + - ``_fit_discrete`` and ``_fit_continuous`` should each be called once. + - Assigns ``self._column_raw_dtypes`` the appropriate dtypes. + - Assigns ``self.output_info_list`` the appropriate ``output_info``. + - Assigns ``self.output_dimensions`` the appropriate ``output_dimensions``. + - Assigns ``self._column_transform_info_list`` the appropriate + ``column_transform_info``. + """ + # Setup + transformer = DataTransformer() + transformer._fit_continuous = Mock() + transformer._fit_continuous.return_value = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + transformer._fit_discrete = Mock() + transformer._fit_discrete.return_value = ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + + data = pd.DataFrame({ + 'x': np.random.random(size=100), + 'y': np.random.choice(['yes', 'no'], size=100) + }) + + # Run + transformer.fit(data, discrete_columns=['y']) + + # Assert + transformer._fit_discrete.assert_called_once() + transformer._fit_continuous.assert_called_once() + assert transformer.output_dimensions == 6 + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__transform_continuous(self, MockBGM): + """Test ``_transform_continuous``. + + Setup: + - Mock the ``BayesGMMTransformer`` with the transform method returning + some dataframe. + - Create ``DataTransformer``. + + Input: + - ``ColumnTransformInfo`` object. + - A dataframe containing a continuous column. + + Output: + - A np.array where the first column contains the normalized part + of the mocked transform, and the other columns are a one hot encoding + representation of the component part of the mocked transform. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + data = pd.DataFrame({'x': np.array([0.1, 0.3, 0.5])}) + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._transform_continuous(column_transform_info, data) + + # Assert + expected = np.array([ + [0.1, 1, 0, 0], + [0.2, 0, 1, 0], + [0.3, 0, 1, 0], + ]) + np.testing.assert_array_equal(result, expected) + + def test_transform(self): + """Test ``transform`` on a dataframe with one continuous and one discrete columns. + + It should use the appropriate ``_transform`` type for each column and should return + them concanenated appropriately. + + Setup: + - Initialize a ``DataTransformer`` with a ``column_transform_info`` detailing + a continuous and a discrete columns. + - Mock the ``_transform_discrete`` and ``_transform_continuous`` methods. + + Input: + - A table with one continuous and one discrete columns. + + Output: + - np.array containing the transformed columns. + + Side Effects: + - ``_transform_discrete`` and ``_transform_continuous`` should each be called once. + """ + # Setup + data = pd.DataFrame({ + 'x': np.array([0.1, 0.3, 0.5]), + 'y': np.array(['yes', 'yes', 'no']) + }) + + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + transformer._transform_continuous = Mock() + selected_normalized_value = np.array([[0.1], [0.3], [0.5]]) + selected_component_onehot = np.array([ + [1, 0, 0], + [0, 1, 0], + [0, 1, 0], + ]) + return_value = np.concatenate( + (selected_normalized_value, selected_component_onehot), axis=1) + transformer._transform_continuous.return_value = return_value + + transformer._transform_discrete = Mock() + transformer._transform_discrete.return_value = np.array([ + [0, 1], + [0, 1], + [1, 0], + ]) + + # Run + result = transformer.transform(data) + + # Assert + transformer._transform_continuous.assert_called_once() + transformer._transform_discrete.assert_called_once() + + expected = np.array([ + [0.1, 1, 0, 0, 0, 1], + [0.3, 0, 1, 0, 0, 1], + [0.5, 0, 1, 0, 1, 0], + ]) + assert result.shape == (3, 6) + assert (result[:, 0] == expected[:, 0]).all(), 'continuous-cdf' + assert (result[:, 1:4] == expected[:, 1:4]).all(), 'continuous-softmax' + assert (result[:, 4:6] == expected[:, 4:6]).all(), 'discrete' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__inverse_transform_continuous(self, MockBGM): + """Test ``_inverse_transform_continuous``. + + Setup: + - Create ``DataTransformer``. + - Mock the ``BayesGMMTransformer`` where: + - ``get_output_types`` returns the appropriate dictionary. + - ``reverse_transform`` returns some dataframe. + + Input: + - A ``ColumnTransformInfo`` object. + - A np.ndarray where: + - The first column contains the normalized value + - The remaining columns correspond to the one-hot + - sigmas = np.ndarray of floats + - st = index of the sigmas ndarray + + Output: + - Dataframe where the first column are floats and the second is a lable encoding. + + Side Effects: + - The ``reverse_transform`` method should be called with a dataframe + where the first column are floats and the second is a lable encoding. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.get_output_types.return_value = { + 'x.normalized': 'numerical', + 'x.component': 'numerical' + } + + bgm_instance.reverse_transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + column_data = np.array([ + [0.1, 1, 0, 0], + [0.3, 0, 1, 0], + [0.5, 0, 1, 0], + ]) + + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._inverse_transform_continuous( + column_transform_info, column_data, None, None) + + # Assert + expected = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + np.testing.assert_array_equal(result, expected) + + expected_data = pd.DataFrame({ + 'x.normalized': [0.1, 0.3, 0.5], + 'x.component': [0, 1, 1] + }) + + pd.testing.assert_frame_equal( + bgm_instance.reverse_transform.call_args[0][0], + expected_data + ) + + def test_inverse_transform(self): + """Test ``inverse_transform`` on a np.ndarray with continuous and discrete columns. + + It should use the appropriate '_fit' type for each column and should return + the corresponding columns. Since we are using the same example as the 'test_transform', + and these two functions are inverse of each other, the returned value here should + match the input of that function. + + Setup: + - Mock _column_transform_info_list + - Mock _inverse_transform_discrete + - Mock _inverse_trarnsform_continuous + + Input: + - column_data = a concatenation of two np.ndarrays + - the first one refers to the continuous values + - the first column contains the normalized values + - the remaining columns correspond to the a one-hot + - the second one refers to the discrete values + - the columns correspond to a one-hot + Output: + - numpy array containing a discrete column and a continuous column + + Side Effects: + - _transform_discrete and _transform_continuous should each be called once. + """ + + def test_convert_column_name_value_to_id(self): + """Test ``convert_column_name_value_to_id`` on a simple ``_column_transform_info_list``. + + Tests that the appropriate indexes are returned when a table of three columns, + discrete, continuous, discrete, is passed as '_column_transform_info_list'. + + Setup: + - Mock ``_column_transform_info_list``. + + Input: + - column_name = the name of a discrete column + - value = the categorical value + + Output: + - dictionary containing: + - ``discrete_column_id`` = the index of the target column, + when considering only discrete columns + - ``column_id`` = the index of the target column + (e.g. 3 = the third column in the data) + - ``value_id`` = the index of the indicator value in the one-hot encoding + """ + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('y', 'yes') + + # Assert + assert result['column_id'] == 1 # this is the 2nd column + assert result['discrete_column_id'] == 0 # this is the 1st discrete column + assert result['value_id'] == 1 # this is the 2nd dimension in the one hot encoding + + def test_convert_column_name_value_to_id_multiple(self): + """Test ``convert_column_name_value_to_id``.""" + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1, 0] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ), + ColumnTransformInfo( + column_name='z', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('z', 'yes') + + # Assert + assert result['column_id'] == 2 # this is the 3rd column + assert result['discrete_column_id'] == 1 # this is the 2nd discrete column + assert result['value_id'] == 1 # this is the 1st dimension in the one hot encoding diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tox.ini b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tox.ini new file mode 100644 index 0000000000000000000000000000000000000000..5fbffba409c0fee10719de58cf5a5bf4639b374e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/CTGAN/tox.ini @@ -0,0 +1,19 @@ +[tox] +envlist = py38-lint, py3{6,7,8,9}-{unit,integration,readme} + +[testenv] +skipsdist = false +skip_install = false +deps = + invoke + readme: rundoc +extras = + lint: dev + unit: test + integration: test +commands = + lint: invoke lint + unit: invoke unit + integration: invoke integration + readme: invoke readme + invoke rmdir --path {envdir} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/pipeline_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/pipeline_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cd8f0c4afd222607db65aae70fe969385ea4d79b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/pipeline_tvae.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_tvae( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_tvae( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/train_sample_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/train_sample_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..7db74590f2826edf87938d3707bf12fdcfbf2b5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/train_sample_tvae.py @@ -0,0 +1,117 @@ +import lib +import os +import numpy as np +import argparse +from CTGAN.ctgan import TVAESynthesizer +from pathlib import Path +import torch +import pickle +import warnings +from sklearn.exceptions import ConvergenceWarning + +warnings.filterwarnings("ignore", category=ConvergenceWarning) + +def train_tvae( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = TVAESynthesizer( + **train_params, + device=device + ) + + synthesizer.fit(X, cat_features) + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "tvae.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_tvae( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + with open(parent_dir / "tvae.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.decoder = synthesizer.decoder.to(device) + + gen_data = synthesizer.sample(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + y = y.astype(float) + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + y = y.astype(int) + np.save(parent_dir / 'y_train', y) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_tvae(args.parent_dir, args.real_data_path, change_val=True) + sample_tvae(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/tune_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/tune_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..0b6558c024ea45bdc43b09025ba4f233417de999 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/CTGAN/tune_tvae.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 3, 6, 9 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [1000]) + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + embedding_dim = 2 ** trial.suggest_int('embedding_dim', 6, 10) + loss_factor = trial.suggest_loguniform('loss_factor', 0.001, 10) + + + train_params = { + "lr": lr, + "epochs": steps, + "embedding_dim": embedding_dim, + "batch_size": batch_size, + "loss_factor": loss_factor, + "compress_dims": d_layers, + "decompress_dims": d_layers + } + + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_tvae( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_tvae( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/tvae/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/tvae/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_tvae( + parent_dir=f"exp/{Path(real_data_path).name}/tvae/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "tvae", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/LICENSE.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/LICENSE.md new file mode 100644 index 0000000000000000000000000000000000000000..3c105473f782136fd5659e03d454cfc3ba31252e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/LICENSE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022 Akim Kotelnikov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/README.md new file mode 100644 index 0000000000000000000000000000000000000000..517e9aa2f8024a8412a9028529e7fe88f6c57dec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/README.md @@ -0,0 +1,99 @@ +# TabDDPM: Modelling Tabular Data with Diffusion Models +This is the official code for our paper "TabDDPM: Modelling Tabular Data with Diffusion Models" ([paper](https://arxiv.org/abs/2209.15421)) + + + +## Setup the environment +1. Install [conda](https://docs.conda.io/en/latest/miniconda.html) (just to manage the env). +2. Run the following commands + ```bash + export REPO_DIR=/path/to/the/code + cd $REPO_DIR + + conda create -n tddpm python=3.9.7 + conda activate tddpm + + pip install torch==1.10.1+cu111 -f https://download.pytorch.org/whl/torch_stable.html + pip install -r requirements.txt + + # if the following commands do not succeed, update conda + conda env config vars set PYTHONPATH=${PYTHONPATH}:${REPO_DIR} + conda env config vars set PROJECT_DIR=${REPO_DIR} + + conda deactivate + conda activate tddpm + ``` + +## Running the experiments + +Here we describe the neccesary info for reproducing the experimental results. +Use `agg_results.ipynb` to print results for all dataset and all methods. + +### Datasets + +We upload the datasets used in the paper with our train/val/test splits (link below). We do not impose additional restrictions to the original dataset licenses, the sources of the data are listed in the paper appendix. + +You could load the datasets with the following commands: + +``` bash +conda activate tddpm +cd $PROJECT_DIR +wget "https://www.dropbox.com/s/rpckvcs3vx7j605/data.tar?dl=0" -O data.tar +tar -xvf data.tar +``` + +### File structure +`tab-ddpm/` -- implementation of the proposed method +`tuned_models/` -- tuned hyperparameters of evaluation model (CatBoost or MLP) + +All main scripts are in `scripts/` folder: + +- `scripts/pipeline.py` are used to train, sample and eval TabDDPM using a given config +- `scripts/tune_ddpm.py` -- tune hyperparameters of TabDDPM +- `scripts/eval_[catboost|mlp|simple].py` -- evaluate synthetic data using a tuned evaluation model or simple models +- `scripts/eval_seeds.py` -- eval using multiple sampling and multuple eval seeds +- `scripts/eval_seeds_simple.py` -- eval using multiple sampling and multuple eval seeds (for simple models) +- `scripts/tune_evaluation_model.py` -- tune hyperparameters of eval model (CatBoost or MLP) +- `scripts/resample_privacy.py` -- privacy calculation + +Experiments folder (`exp/`): +- All results and synthetic data are stored in `exp/[ds_name]/[exp_name]/` folder +- `exp/[ds_name]/config.toml` is a base config for tuning TabDDPM +- `exp/[ds_name]/eval_[catboost|mlp].json` stores results of evaluation (`scripts/eval_seeds.py`) + +To understand the structure of `config.toml` file, read `CONFIG_DESCRIPTION.md`. + +Baselines: +- `smote/` +- `CTGAN/` -- TVAE [official repo](https://github.com/sdv-dev/CTGAN) +- `CTAB-GAN/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN) +- `CTAB-GAN-Plus/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN-Plus) + +### Examples + +Run TabDDPM tuning. + +Template and example (`--eval_seeds` is optional): +```bash +python scripts/tune_ddpm.py [ds_name] [train_size] synthetic [catboost|mlp] [exp_name] --eval_seeds +python scripts/tune_ddpm.py churn2 6500 synthetic catboost ddpm_tune --eval_seeds +``` + +Run TabDDPM pipeline. + +Template and example (`--train`, `--sample`, `--eval` are optional): +```bash +python scripts/pipeline.py --config [path_to_your_config] --train --sample --eval +python scripts/pipeline.py --config exp/churn2/ddpm_cb_best/config.toml --train --sample +``` +It takes approximately 7min to run the script above (NVIDIA GeForce RTX 2080 Ti). + +Run evaluation over seeds +Before running evaluation, you have to train the model with the given hyperparameters (the example above). + +Template and example: +```bash +python scripts/eval_seeds.py --config [path_to_your_config] [n_eval_seeds] [ddpm|smote|ctabgan|ctabgan-plus|tvae] synthetic [catboost|mlp] [n_sample_seeds] +python scripts/eval_seeds.py --config exp/churn2/ddpm_cb_best/config.toml 10 ddpm synthetic catboost 5 +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/_compat_run.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/_compat_run.py new file mode 100644 index 0000000000000000000000000000000000000000..77f1230651645a74d0f38b3ff44204cbe28e07ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/_compat_run.py @@ -0,0 +1,6 @@ +import collections, collections.abc +for _a in ('Sequence','MutableSequence','MutableMapping','Mapping','MutableSet','Set','Callable','Iterable','Iterator'): + if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None)) +import sys, runpy +sys.argv = sys.argv[1:] +runpy.run_path(sys.argv[0], run_name='__main__') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/agg_results.ipynb b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/agg_results.ipynb new file mode 100644 index 0000000000000000000000000000000000000000..b2265036321a1b9a52a99daf500759ef4b03d60a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/agg_results.ipynb @@ -0,0 +1,315 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Aggregating results to DataFrame" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import os\n", + "import lib\n", + "import numpy as np\n", + "import pandas as pd\n", + "\n", + "DATASETS = [\n", + " \"abalone\",\n", + " \"adult\",\n", + " \"buddy\",\n", + " \"california\",\n", + " \"cardio\",\n", + " \"churn2\",\n", + " \"default\",\n", + " \"diabetes\",\n", + " \"fb-comments\",\n", + " \"gesture\",\n", + " \"higgs-small\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + " \"miniboone\",\n", + " \"wilt\"\n", + "]\n", + "\n", + "_REGRESSION = [\n", + " \"abalone\",\n", + " \"california\",\n", + " \"fb-comments\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + "]\n", + "\n", + "\n", + "method2exp = {\n", + " \"real\": \"exp/{}/ddpm_cb_best/\",\n", + " \"tab-ddpm\": \"exp/{}/ddpm_cb_best/\",\n", + " \"smote\": \"exp/{}/smote/\",\n", + " \"ctabgan+\": \"exp/{}/ctabgan-plus/\",\n", + " \"ctabgan\": \"exp/{}/ctabgan/\",\n", + " \"tvae\": \"exp/{}/tvae/\"\n", + "}\n", + "\n", + "eval_file = \"eval_catboost.json\"\n", + "show_std = False\n", + "df = pd.DataFrame(columns=[\"method\"] + [_[:3].upper() for _ in DATASETS])\n", + "\n", + "for algo in method2exp: \n", + " algo_res = []\n", + " for ds in DATASETS:\n", + " if not os.path.exists(os.path.join(method2exp[algo].format(ds), eval_file)):\n", + " algo_res.append(\"--\")\n", + " continue\n", + " metric = \"r2\" if ds in _REGRESSION else \"f1\"\n", + " res_dict = lib.load_json(os.path.join(method2exp[algo].format(ds), eval_file))\n", + "\n", + " if algo == \"real\":\n", + " res = f'{res_dict[\"real\"][\"test\"][metric + \"-mean\"]:.4f}' \n", + " if show_std: res += f'+-{res_dict[\"real\"][\"test\"][metric + \"-std\"]:.4f}'\n", + " else:\n", + " res = f'{res_dict[\"synthetic\"][\"test\"][metric + \"-mean\"]:.4f}'\n", + " if show_std: res += f'+-{res_dict[\"synthetic\"][\"test\"][metric + \"-std\"]:.4f}'\n", + "\n", + " algo_res.append(res)\n", + " df.loc[len(df)] = [algo] + algo_res" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "
\n", + "\n", + "\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "
methodABAADUBUDCALCARCHUDEFDIAFB-GESHIGHOUINSKINMINWIL
0real0.55620.81520.90630.85680.73790.74030.68800.78490.83710.63650.72380.66160.81370.90700.93420.8982
1tab-ddpm0.54990.79510.90570.83620.73740.75480.69100.73980.71280.59670.72180.67660.80920.83310.93620.9045
2smote0.54860.79120.89060.83970.73230.74320.69300.68350.80350.65790.72190.66250.81190.84160.93230.9127
3ctabgan+0.46720.77240.88440.52470.73270.70240.68650.73390.50880.40550.66390.50400.79660.44380.89200.7983
4ctabgan--0.78310.8552--0.71710.68750.64370.7310--0.39220.5748------0.88920.9060
5tvae0.43280.78100.86380.75180.71740.73170.65640.71360.68530.43400.63780.49260.78420.82380.91250.5006
\n", + "
" + ], + "text/plain": [ + " method ABA ADU BUD CAL CAR CHU DEF DIA \\\n", + "0 real 0.5562 0.8152 0.9063 0.8568 0.7379 0.7403 0.6880 0.7849 \n", + "1 tab-ddpm 0.5499 0.7951 0.9057 0.8362 0.7374 0.7548 0.6910 0.7398 \n", + "2 smote 0.5486 0.7912 0.8906 0.8397 0.7323 0.7432 0.6930 0.6835 \n", + "3 ctabgan+ 0.4672 0.7724 0.8844 0.5247 0.7327 0.7024 0.6865 0.7339 \n", + "4 ctabgan -- 0.7831 0.8552 -- 0.7171 0.6875 0.6437 0.7310 \n", + "5 tvae 0.4328 0.7810 0.8638 0.7518 0.7174 0.7317 0.6564 0.7136 \n", + "\n", + " FB- GES HIG HOU INS KIN MIN WIL \n", + "0 0.8371 0.6365 0.7238 0.6616 0.8137 0.9070 0.9342 0.8982 \n", + "1 0.7128 0.5967 0.7218 0.6766 0.8092 0.8331 0.9362 0.9045 \n", + "2 0.8035 0.6579 0.7219 0.6625 0.8119 0.8416 0.9323 0.9127 \n", + "3 0.5088 0.4055 0.6639 0.5040 0.7966 0.4438 0.8920 0.7983 \n", + "4 -- 0.3922 0.5748 -- -- -- 0.8892 0.9060 \n", + "5 0.6853 0.4340 0.6378 0.4926 0.7842 0.8238 0.9125 0.5006 " + ] + }, + "execution_count": 2, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "df" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3.9.7 ('base')", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.9.7" + }, + "orig_nbformat": 4, + "vscode": { + "interpreter": { + "hash": "a06af253165e97d0c1e75e8bf6d3252013856f30b8177e11b02d3fa36c37333d" + } + } + }, + "nbformat": 4, + "nbformat_minor": 2 +} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..4440c9036b27a7ff5f55a6f733751f0d1d5caa0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db1cf55340ae5364a05a1c840094ca47fff79dd584850c9ee751b2a097f7b075 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..415f08cd7f0cafb12c8a8e86a587ca54e17e128a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dcb118d387bd15e6a79e571ad80c7a4fe900858c45ccea903e70a9550c86203 +size 256 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..239282facabecb1d9f1223c79c3fef51fe2be053 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe8c63e9f9a09cd9ca89affd4bb5e4d1545d59cdb31f9f73fb486257bbfd447f +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1bce1d2e055e5b55b325fe6842697c47a89b8461 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6bd872ae66f715fffcc92f2c7c4cc2246980b4df0e02b93738a8c9b4f697af0 +size 539 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2d0fab15dfaf04b2a9fb717ea0802d8e62fee7fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42a3a2e2f22ebc24b66aaa3403869283f6576ce04e5fafa81fec15735d66aee3 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6310c4aa9115b015b514b2a282c61d68fc369a75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d6478bba03b9309a26ef6e1247d95ce86668437fa08a6c5f15776ec9848a5e2 +size 2424 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9eb5c94dab72a3d1610e5222c6de3ddad5cd6c41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc6aa7d00bb5078f766e5d73ea4e04bbe8437bac44636cfd80a36b9262df0a01 +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76e24715bde6ce626bf4308daece11c372c83fef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7ef5506437037908e0c0d5f0bd0c5eb3c61747d9de491d345dc0e8e8be3845b8 +size 909 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..e1b158afbd5ef2c36faf553bf457b116fb84307c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe4a3e4e117924a65d2da76254394ba8aae00555e30bebae916e154a925f0e3e +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..49ecaecc1998e6d60b6cf38839b1801c76106646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aaf9df7911d5911b85f1a805c48a1c6d0e978e287c10f9ef78365b08a14da806 +size 4809 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json new file mode 100644 index 0000000000000000000000000000000000000000..d6c8c3f0aa45c5f991ef888e56074644c40f7643 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0684462d69e5c1c8db2b1fad1ae7760be1849abcc5a623b5eaf07255b04a17f8 +size 454 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json new file mode 100644 index 0000000000000000000000000000000000000000..812b1fa0d26104fc94f9d73497c59db5bda8c81b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce2cdfb51f7d37053edfa2250af17d1adef47d3e0eb141926a6a74a613c6cbb2 +size 442 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..38785f12fa8a0a5c6ec6924e5ddf9222ec12dd11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c621cbd0dcc71b7f8c19d01e2aa6e3497f82d84a40a97a2bfac4ed83e3e0df42 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..7e3f93f4f09ff79f86157b296529a7e893d25078 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1b145c01ef06f81e77de7b8438cb942b863881a21cd76afbcb96b7a61100e96 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e1290d33f1f124f533c3159f32d21a3e917e8872 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d17baaaca34b2ff7aa0e7a68f062bfa12782bd4c483d07e7f97758a1f6a8357 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2a6ae85d7cb08d2200c0fd578de2cd4e0cacea2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00526ecd9377b1904c01ed6cce54c0e9b691c850e292f0588107f770ca1f8fc2 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..91fdedad84e55e1fef159b04ee30ed4841dc7692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3996ee9bde79e3982c88235d2b1122b8988c89611bb7c41dee2d1c12139e3bb +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa9932fd4604af72d4378fa0f4c66c2b7d3218e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e9cb8da939d962852869d248afad2320f27d30ac1900442e6f1379fe88051b76 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..41fdb7e2dca3291094b85592a2b047e69f29f529 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:207d7dcbfac7bbfc854a941b32c95a76a51496bb71717c2a5ff2a2dbb829b26e +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9bc4cdcb8f275644399a66aa1b80f60616bc3e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7df36381315039d5cb9a27726a08f74032f27bce1000fefbbb01aed9b3e4b2ae +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c623de2b0e3bf0dd3be30de30b65a60c9436a979 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df8ce015eace899092d39efd5c2b7d3fde374ed529dc16feac566fb6447990d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..511f215474c59b8543820b3d0b88de78e0de0d9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:559fcc7559fdf7b84792453eb40b37ba2940146f16519894b6f6fd37fa3bb5b3 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b6a8ec4bb5bd70ce60006afd3a7dff1822feb169 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20b5b6b62d80477424158fc13250fd86a5c810bffbf9f930efb7a1e3bcddf0af +size 2407 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a9fb552c41e001e71154ecafb476a465879687a7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c6b40deb21de47336a7784135e055cae8e4162fec33c39b78c3a41e3f74c948 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4da4fc191a2e5f0676788c852c5e1cbed41d32ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9f78af172c35514168b0ba7aa97d29f9d9e44ba99293de739049be2e3705645 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3723363ce4b36e338ef02bdf850bc9f02336320d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0290647040001ea9a368bf406a5f0fe3bfd8ad34fc91e12f9b3cbe4de489cd9c +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac7bcb5f706eeea6d76d7540548852531b06071a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bd237e3800561b53e3ad33f78abd40d90631f66532d2efdcef113e02a239cc46 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..32cb493748339cff60f7fded2233546e5e32cc84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d181d9e4e274ba8953549a2a86feb4f9fd0d344a56fc0c23dee58489fb2f4dea +size 2412 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/abalone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c91eaa420a435b2548fe9f6fa7cf86aca25a447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82fa681345385f4cbddf6c2946308525a747b4e8502e5eb0700402911680c3ee +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5f1a10d99f376c73048318bd2af6ae390e8a4490 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b99ae92eed9a1e581aa7ff0d271cd67f0955d0cf09a510dc5e1cc6a385e21b3 +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..38203892c516eb52a6199e64ce8d12d24b452965 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc182a50c2f168db47f03cf6e35aad805d855e67504c16b7abf4a54010869fe +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..66d6fdbcc81074fe3726c4679a8f0f06df75877d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98523dda3ed661941608fe1b376806a9d0affc87834ca87779f4671ba571c54b +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fbc7353d875b05901555aa21421fdbed1c536705 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea807b1b78a37648296de632ce735f58d486a97f4b24e932aa779c67e25acb9f +size 552 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..53d639a085e90b656b18c69da21e580cea010516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c80c4d789cbc01a2220a215ce23df5afd3492eed59f66682ac55336b42bcab6b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bef94f899e84c5df37d7988dd17dcb902600974b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85088d7d9b8600f758d5ff5571b8a8c6704d5a59ca6abe26fd4904ae19c55632 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..63cd2f794eb62ec7a0ee29203f9a9a9d4dff5462 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:289633f5b676d2316c97619996c97c873176e1210dd6db4a61191a6f4bb17f80 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d0d477a0e57573a39b7fd81b710503bd4e73724d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e8bc409e88198d374b05d90076684ca2b90d591045db6766a5e936801333b53f +size 945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4ca38c916877e7e9eaf024c9fb6c28a56f3c474e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b8d5261312695be59977ccae61c966a26b0cb69a14c644c68f922ac8f893a32 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2d09f8eb221ed76948966ea9f07fc9563f632d58 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2af8c461fb0755cb3b48fcc7f09188e00cf86cd81eda9c0b4bd578f27a7e4958 +size 1317 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6daff009fa1786d5a82839aa85d058902b799602 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fb01634aa14168c902aa056ab75585f0e651d9f26731512fd0012ae3e689318 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab913f002d23e5ae0a7f14750752565fcbfd8ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2b61e81512f6e5be97135a46ef8fd46a22f64a9a53d6659700abdc151142c9 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..36d2e6dda9874bdd9bab29341f3c433d97584768 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df063802251823342ba95960aefc6e9a7860c912f1d086b50145bb973c372b69 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0402c64128c1641e1847800e507d54d189c6f51f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ccdb7ba1c26da827d15509d3040ebe6465586801b404cd099913fcd39dff534 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1cc8823537ac8759cdf13cf468f7da760c1dceb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42ae10d1554df7b8b364f5e0ac4701986cd67aecb9967eb70ea2e077bb134652 +size 901 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..55a0bb6fcaf422c13a2c2ff53c58a57f8b9331d3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b61d18963acc154eb7ea64dfddcf182ed993a93b15c86cd757bc53cacbb9a23 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..139a662dcc89b87ec89a84edfd564e8c2de7cd30 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fdf95abca172dac3b978818cd21f1505d45d69d95bcd9d87e51cc0ee74025d4b +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d32d9411660891640b125047bf880d1fe4b25ab7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:62d657b20c19d7f33e7e5b64472078bd7db69f460cc77bce2b9da69939f7d13d +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..46589fdd2546416d8423587d17e49ab98f2fdb72 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:537b8d3c395d476ad7191337d6f7ca04e938ca5743ccec0bdc0ff94bd48997d2 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7ab60cea704ce4061d24f98827d49d17a1c9d10 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a2a0754baabf29b1ecb6a70d42bd4d1586800bfc47b6bbb0f1f304bb1242b09c +size 3324 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..00321a9ffa3e714125668ab0501694db50470136 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba31f53b7ae00081599032869b9b661df43572e336d56db4fa08beff271a4abb +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8f9ac5ebeb685a33a38e5c51e47b623dde84802e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d91e2295ca75ac6be7cb33c17ef83238dfb8a2e8b2b92237ed405bbaf111d6d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65e9f57bae10cf98cf7283cffec68a0a5fad217a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25a126b5e9fe86493e96b5df30b1a53919680a3a444f6f2605f45fba1d1598e2 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..872de3d2083c260dc16bcac5c091025328ed54dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ae76a56a721fb2229982da25398fc47af989bf8c76be29b8ec07d16eb8963c3 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bab398cb86a7bd5b269964545090c18d3004f9a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cf5cf2766e0d2e778fd96198b87441aeb3272204d8c8ec028f9e1ef671f99db6 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/adult/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fec2e348eead32758349c9ff196afdaab3864d9d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a44105b82634b3c9b91016d8e954a0094ffad036e51845477eabd00e7d4094c9 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..30aad0f91dff111a4fedd1215e6009a644b61e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9e3cc82640c33eb1b4b850f705145d9f84c7c20b787c0db7c3fbe856dc4b11b2 +size 535 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..42f18f71c16e70c9d9b070942fca0f017000e140 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:83d2c2f95c8958abaab28a0adba1d1d3d1e3702d2045c6b4533e35a63a55e604 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b0b6c1aa4f31697486bb4e03a22cc21ba57c7b99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab1c4263a713421bc1d7552aaa52a651e1020f71e1fe7a42b3723e4e7e143d1c +size 2393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2561375d3b6eb2798994bd9db1120b027b7a1cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b238f1464d4e714993012382f3e052a3fc0722743a200411551aa5031fe0874 +size 516 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4021982c6c299c4de244288a83dc31e691242289 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98856815bb0939c1231594e31ce2b910e1fc809f185d28ffaf7a0b6603664c9a +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bb60ee553f1ea7d4c2d8540e3c2248a14b69f74c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2620ed0d33427576a9c706e74f86ae948076ac55615e4b87a82ba1daf9c789db +size 2394 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..49363d44b0b4c826d5d675158164c93de19c68d2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d35a863d159b0cd489d94ae8ae1cfb9b916fc02c99a931ce487cdf189532f3e4 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..722c460979cf67531c5b946aa745fd20ddb80a07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba6dda074f72eee74b8afbc2b18fd4626e710a2d3583d4379509cf9025edcac +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac199ba6cbf5784bc6a656c727d92923bb947df3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61aa5b3aaa5ab7da9c58c291c32533b9945e60b67f43f898ab179a9b3060d895 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..81d026923d55ab59b3dc3c6383b52450a1a03f0c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b941bcd7d8c5cb1cc585540ec98f24a0c12236698bea9b81f59b95e3783eeb30 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..47e136ee719855e17287e833b4946e398a10e2b1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb18ddf958aa699f11e0af740a81cd39b8f6df95860b5fbd18185bbe47ddad4a +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6041d3975ff389fe0d3062e98b03c07159250e16 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b15ec2d2c0d7b64cc6c3c65f03be04a7b813ad6f58ac10c92591045cc079cde +size 307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..52f8c0995c704b748fee904d2b83d774f1717913 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c3675f54196bc3cb4b2d19bcb5618d8577268882c082a4e64c52e5f1f7f05c9 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c846e6c961316abf6d4e1a63f0e0b8247e643f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aac333513d83a2571f92a1ccd30688bcbb74b4c2334da701d2514a83605d652f +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3e5fb807e5fbc4e8b6daeae882cbf7220dfad65a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86ea8bc3b6b08c587585c1cd2287359abff44cc3e717767bd85cbc6a390e0870 +size 962 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae7fd0cda795fa6c97a342a0c128db17b5d7a763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b849b1a0af8d78f67ccbd04a3a35dee96b72f8aeb10ce3090ff3e11f6b425b5 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..778b938d4d50038bb857dddcffec813f70a4b1ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc2aec212d7363d486a316be109ee1d435c0944022f9f3a0279588b3ab4fc456 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c068a90386d6600e32f428498170073bd7e8990 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa163009f809658f57d8d5128088de7586d4b689e127f65c61583796611e5c56 +size 399 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..318d2bf2e09df253811516d67ebca9f7c7f0695c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fde8a58d975533a542c08c06ea1b796065a6dee6cb0cfd4378e1b985818c71d0 +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7833ba5f315b943a8d73137b7ed675646fb2715 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f71aaa39f6f7126dd425a82aa795129a6fc31019607c8ea99f4b6f8bf523a7e +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..f2c93e38fc570c526ef27a6db0f2d0234937f642 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:84f60f6dfb97afdb242b799a412b7c73905b61bde1593a62a7729e6c3f3c246a +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..45d86aec79a33b80cfbbcacdc2a7ee1bcd2760ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9f43aacc1c469ef228585feae4b8ee193ce1602a6855ab41bf5bac7f30f2386 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5fa9cedcd3cf536a2a379ff590486c9b4eedcb53 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49a118abbde6ea1ca044c5f60965e23689dd5faef50a612bb571bd6b1774c57e +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..338bb99b41bfe233281929d5d2e05416b1095031 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2235588571940c74c58717080910fd181be9fae29e9a387b6d34ead239db91a9 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c27447695997806191b34155281cd904003c4235 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d66bfbd3170e741c11c189ab9c40e4d4ba0310d70df88fede66df233d7a13e6a +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/buddy/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..269fa24454c2b0228ea9d70a27f3217c50cd73fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:47fa5e3a33f17e31a9a3a7a986c4d189aa6de421185bf67340c6f851c5f68503 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9389e17f5523a293bafcbf07879c4fa7ba402a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c263f7234c47093e6b0c0ae04e54ff853ef64604141527e6099587da4c158fbc +size 536 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c01ed90eace99eefca1d9ddec2b75aebbea0c968 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:45cedb6e79c0e481d2608def3e1fcef07f832f989acc78d1397e373b261dfada +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..de5b58adce509a35f047a0ed963404afd0acdbbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ff12d95e026451c0ea70fc9877fdeeaa06a5e55e8424c151b14ea8d5c4a65d +size 2425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..645123d51e5899d9ae6aa4d041c63d8c5f40b69a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b7f06bd35da5fa1b2a7af11faf1517e42bc7300a33804adc14a6a937d40e0b99 +size 961 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0c21aedc0ea78626a22795cfebdea5f097649bea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b8c5497ed9e9dd29cd6423795998a32a9e064afe3e25fa166429d1d4531c7632 +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..183d6bf2f7200c58fab0537bc71eea8dd9029042 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f45f5378800af031cc1189625a89e6f971f244084ab6a1ec44851c1cc97791bd +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4cd56144fff8b9f7435faaa60e0495f1b25eb902 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:449806d716989b618e9937da4fcd1d1b34a3303af0fed823518593f10210dc08 +size 4815 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c94ec5f2c60e366c93758984ccedf7276f71cce2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a28f54c683196f15422a3de9fd1729928800c9c6d9f2b2c4f306781a58bb0d57 +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..65f9bc67bb2bb4816ecc0159070ed355b2bc882a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25c3b72ca028e0ac20a23ef943128c03c5be2361341e312f6fb970bbadbea62a +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0914fb8061937287fa55186e588aee0978202325 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db0bf0f16268095c085c9578c9dc6929619b25d85de4beafa71e2e2c0b8aba9a +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc53309f95d9da1956bf01d9d813899524f1a2ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:043cbac22ddcc78d3bf1ba8667bfd3319f2ef4d20be12171ddd794f02e3819b2 +size 974 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e6a741bc6e80d9a8caa8cd4d5aced901340df557 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f473c3dbf1df529cb9c83e61d15ece198d860dc01b2a2e89eb85fe9ddfb71e09 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2a303e9844c21875d49583eb43bde27f212fdd91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d349508f350d7d86ab8f1bccd80706db33b4c493d8d0fbbe7a78dda7daa7bad +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..455675f5055f90694438c7fb7b00c6ab6a1f776e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2d64e51d8b6b24265a2c3948da7bf7ebf652a479ffc356690c7c32e7d05de0 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..110388b3920b6cc8b54b8d5674f95d816e8401fb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d918b0594fae87d25263c250b82a3481da89d2b27414bc5f46fc15a128e3dec7 +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..cbd3b9076dc55fdf3c0d603ffe7c1128a83f2ab1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db184ee0c7f1a2f3b154833c774c7cc95247bee0f0bb332fdf2f81fee52d2980 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..422c57be1a335bc126ae19e81f8de261046667c8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:684c20875442fd0af9aef20e258408265a0afefd337b3095e30f383f558f4e66 +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ebf8752d97e0b55ee67d6b25ea55a0a6035bec7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cba89f4f5a0ee277861f5c59874977e192052179029bae2ce1d4d51afcdf3ba0 +size 2409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a63e8c4e3026a48b79e8f373d7b97101cb791ebb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfc716ea0562b0304e5fc93363c2b47e3c62c6f3b53efdf627d4016698dc628a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..57ac452fdc6cba483d2217dfdebff391e5ef5679 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:31f62570889e2465b493833d65252ee55965ed96a5621737168d7908c8847592 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..11fcabb46bddd9db63302a9187e507bce762f416 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2040299a5b6055953f17fb97dadaaf61b71b994f54639358a474976448bafe99 +size 620 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9aa6e63ec8e0a96295b61ede2f6fa3bfbcc3c4d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d208514a5cbe37b42c4a6d9be3ac9e2f32f359162f9e6e8c4f4482b5e487880d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e2392a3b0b097544d9e26713aaae9629aa1625a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46f24cdcb144018444629866ac8d0cb66b41c004e3fdb3f30e037c63cf5676c8 +size 2427 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/california/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..32d5bd49be0dc36ca2706cd274f3d7a528666572 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7559f0164dc80330ee436b9c6776f02149f6292e4b43c6a46ae5e14dc42ac6bd +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c49810fdd2e5118eca066398387f600036483e15 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b8f5e646194ff57dcb4e98faf5ddd4bdf7bda7b88e30cd5467ed28b3bc3cca9 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e9acecbbb72edbbbad89031bd6ca7c1f812bafba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4741f1db86513a094d4851c28387739323b4a120db20c6876fb1c3c4882e8d90 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b37393fca5e2296bbb3f6766189c46f04372a0ab --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc5de6dffe429c643429ece101cb1c96a9fb69ff584943a3900e1c708b97781d +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6958fa6c7bdb05b6cdb345ec7a2b502db956de63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89520a1f3bea8b05349191737c397a74f73628e809f1b3e8812a9598676c95ba +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d54495c34176f8c6c531042f06f9cc6b328dc961 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7f673d62b4ca86b684d165166a9af155b8a46a2d04c3ff142119f3183b6c089d +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..359ad3f5de3d94dee020f29f1ed8e06d6dfe8b45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4092df04bdfa1202c4b36ae7b546150c9eb8b4208c2fdd0a10ec0fc8bc734df0 +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48aaa3431e36e4baf682bf2feced3c975e00af7b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ee347b13e03324fa6939416de58aa2d45353abf49d2974268edb9195cbb626c +size 950 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5b257cb1dad201b5cdf58957295f53d2956a44c2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfa9f334e88216ec3f8c3dbdf41093ff0625bd58366228b8f18693763e4c8ed5 +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..da7a7e578cf69534d49bc1e245f9baa6572df901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d20ca1246e05efc45538fa88921adcf96a1cff065e9596a56ebb6a3e898349d2 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e40f16736ba413da0169a57765b841abaf1a17ef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1ebb005049375997ae5edad683d9be7aabe9e9fe61adb441fcf2570dc3a67409 +size 6635 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..698e4c1f1677c0dcc9913dd979e88babc5138ea1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46040801014c5a90ce5594329dc9aa6df9f5149b14a31a0ebde94b8af530a2cb +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b5f8f7a4b101dba67cee17287d52bc9b3a4e502b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8059543ac2410dd6a9fcc21fdf78b27a52590fd11ad5ae78e8c0ec4c50562a1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..d27f58b1a316a4f1ec709075333dfba96bd26cc9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49914d0e4622823c539bf12671155b3eeba24785cf041e53d063c497a7aa8d84 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0fb1249b15b018b8e114a958355be527821c6f44 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddd98643049e38978a0c8ae1a9bf130dcffe50dd1d273f2ff9818c574ad577 +size 940 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..69342c6e3076359aacd57f8e4586aa0c5303f6e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:241fd60dff540e7a6cffc88bf736287b5a9782b2feb0c4e06b64c549dd9a6a05 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4fb60954e12fb8aaddaf1ea7e5fccd9a97a93a62 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c310bd2406837fa0bd6a0923ac0627f101f55858cdb76829377b7e09371253d3 +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..62ba2b0042239c143d50e65943ea37b201e89849 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f063a4c004754b6c20bf16e11367ccb025f0fe33950f8109db30b8526421a74 +size 419 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..24cac350450f348792b320bbd64757b74b48964a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:37181708cfd498a42c52b35bda7e7f8e53d2f79fe33bbb5badce97ab7e4a7a56 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6dee1e9c9b67a46cf3bb307905801fa58e17f2f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca153ba761027a6e81093233805f135627203e9fe4b42746a95078cb14b6c3f +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b0806ac8edf41b2e83d7de62a63399e9c7777a09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef17a4731ea97162ec746c119be4f28692a05e2d754f03d1b0e078955ae6e35a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ff39c3baec69488d818d8e8862c15e6ba8697bc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d2cf3e6141978001f881e237a047125480c5d708c02bb2a8d2b8f8adfc3ca991 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..989257f2cd7879e01e0bae118eb99dc460a7135b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d60432905833e78c163a5ca441762a3457df059ee5f863599d7bf5f05573d206 +size 645 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac1b0d7e901fad6a33299d8096cce6f7180b04db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6d4572c0f1c4eb5fa790e3626f7625b2278ef32a7d1d5571fcacb8e1c4a4239 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ba5d09d21c650c6a429bb224f86a64d69ab8b056 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7c30896741da121fa904dd52b9512b9d1c46dcc2ea99073d445cdaf46255c970 +size 3323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/cardio/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6f116f2fba5dd8fc3b3d3a10760f8dfb7b20085c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5b571a95162a652fb0bf6963894d4f7bd0ad6af23c8d2e127d86ae8dc999d72 +size 900 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..890861bb0bd5c3b987c7bda6bda240ac57b5d287 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e427c6255a473f42cfc122abab8aac0663a8097a41c3ac82d1c937dd870df391 +size 514 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..23d90d8e9e197920c034ac32fee3128856b1ad32 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bee7ae165c8bd90f9599466bd937fbcc6382c85d4343664f002ae95323fd72e +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d9ea289193f0768b7476e5d29c6b1091d578ecaf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e6e0154410a192860debc43db1cc1bf95f1d64cc640e1be959ce864e14681ea +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e71bbfb5fe8ff8bbf9acb97402fa7f2c9752be4a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aeeef2beec0f188de9c8750c3ba9bff9ba497d52f60356a7cb1a6e307655d8bb +size 517 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..02da94123d89e9965060193a542baf1006d1e3e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5d8435dc0d389e501f8610b20dfa241443a4f26f0b490de7a2d3217e9b4fbaa3 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..82588f08417a5ac5d0b69922556c30b885479731 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26a4c16b1bef3bb88df83fe744e9fe90f7ae6bf920c9d8ae07001a367c8c1c01 +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2979b9f99debb0c439adf35c53038c5cf739b938 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:54167a575ecc0ef5b9cfa8601a300b5158e88351e24f2bc4ff6d5051ddf27def +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c6027d7b382d2b945c75241a2f2d08a06940710 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a89baf17b151d566d008c18ac8c7c932fcc6b4bcd600cce2606683d2aa0a235 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..02a7c3eb6688aafb9a1c0f16e33158d2194fb695 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c601b334e49062a1fe2da765c22767626e2478bf295faf6313bd704732c5e6d4 +size 968 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76d80d8440204dc23c300538cec7bb957590aadd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04804a5fcb64dce7ee245ec0ae19ea2ba235aaa0b63364afcac4200a76b7b5a2 +size 1322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0ae295960b595eda7c3ba37879df08b75c1aded8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebf7c222b1216e92accff79804b4a00d2fd44919d5dd31bc6a6e60acd036fcc3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..dbde9454a5b06bf37c29db5e87b6bdec7a036723 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c003338c5f3ca1f6f85454ca4ae95e5c1716661addb4736e5e4df477fba9c332 +size 6633 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..74d365aa8e41d2a522edf59c2ea076c9b3dbe7f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8a2a35828ecd06e28b595f77b8033817d57b2ac1d399b487e8913c9b99080b8f +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..74568be19440089618d17c6a8a09ca1250c8baa2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4597ad66b89668b391f34929896e5efd8143ec192b8dd09743a5f369a4726e1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3785c98a3859f8e1c87cbe724aa130a396e5c792 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd10ce7b695ccc05ee555915c57cfe784c6b193d66223143542ad70fd2b95aff +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b743faede98137b4da69b7e73dd3c37e68f66090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4fed4a225190587ae6f6c5e7f6e9222dee02300e601232414b778488a3722dc +size 963 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9f709c6f28b5d6bb427d30148e84c6d040da00c9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2da779761d080f7f5b172c2cfb91aed74a04df83cbae1434f4fddbb188835820 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..c58de36a0ba076ba18f7edc3eec2d4c86e85b59c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b2062ba7a64a8c780bd72d03857641634071932507e5028ab8569d0a6839ebc4 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..1fd295065a538b8d64556e1134450227a6ab8450 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1486d35116d842c5f007c9638c5f9a042f6cc16fe64e3013c495af69cd76631f +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7ee39b00043cbce7f8f6551b74b9caf8d33a5f33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aebb8344a19ee1acce6ddc539289e78027660b8a4a1b31412a337cf189e8d7e0 +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..259b9c28e2216da88f2de4a2ada5f41fad0f3f66 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225c399903d85eecfa1180717481779c5181f957bdb0f19181252966d8e073b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f15da93f1bd7db41b61ab7274b891ecc9770ac3c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa30c8613e72c13f6f7c50feee02b7613ab54dd1e83e855c5ad884e88953fd24 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f23f43a640a36e089355ff831b1b3337f792d8ca --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3525848bbb0c7286606562d2141eacc717f087121cd663688fc213aaec6b04c5 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..87edb0ad883ac38f933339b7871283e57f5824b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f81553f0c9478bf6d53738d42abc5d200ae3c7dcba6c65952be292b66ad840e8 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..37910800c4a09e68e3c9d10588d70892ea76dc93 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:55674c76480d2de69613c7e6b3ed340f4cd8264e71cdcc0245d50ca2602cb406 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d6efa05500f2c702f445ed863ecd0ce0e6741e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8147293b90e33b933bcc4f90367f4321618d12c6a6dd8062b34a30b527a4ed29 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e61dff9649ff3977e3095a15a1b52ecb8814bb40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4902b279f2280269a77b7716d7029fbc4138d8341241ecf70733f6c72c2aecad +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1717d47b45f0d8bf948c052a264464bb740b7213 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7957770c239db6b73a5f331fa0bb2a6833f357ab9f1f64a7b8b09cdf949c27ec +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/churn2/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d30f0ede012a7833c2dd8b4a4b770d76147c8577 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:19952c8a0f8428d5490cb019e5126a86ba664b4ebc8fc003c4890b9527a934e4 +size 927 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d4aa3f601a85d94ecb748a479d8aef67264e933b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:735c7bce4b893f0d9e465858a37825e849e4042d4f226f9f47f0683eae5bf81e +size 521 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ce2910d3a7adde56c554a761c5e9955a44ebe99d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6686b110d578fce74aeff473f802b92e7cc4427df7461775f7b361f6661aa28 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3960734418f032c074d955fe7aedd33694c6e57d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb99b57d00d4fb78c9e05cdcab9744c7745d8aa1f099110fa7443e283a822359 +size 3337 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ae426a48600b38c867dc7ea13eb3c93a61a29901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:92b8d1bdb969df86f55c7f6a142aee1c5e7112e3c6ccf99c06d2b6bf8a0f2c0e +size 518 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5a7ecf664d2aed9530c9d93c71b6ea94c78409db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8f02e8ac53b185b01b03c28fd7eaf41ef6f8bdbcd0524bee7abbf2f80d3ebdeb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..7045c60ead66c0e3751c7a6a1d51ab959399eaa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0ee8dc771d2fb906975727cecddf706e80992b06407b16e43fa754c807005f6 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..cff6db9f8bd0a9dfbe13f3161ca7d146a8b8d9e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dd27a87c527c36e6b159360409614c204ece2116e30231f22c504dddcbcad72f +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..99b9db3416effd012701e0bd8d1a0d077a7da75d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6f3a62be3bb3e7bcbb49a451de901401bab916647596899f5b4a507a92073f6 +size 967 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da6b9ef6dd806fbaf4e6f1b3f4906c09487319bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ad87d4183c7897af8fa6d4a05a27527358bf028b3a7c5a7ba9c340f7618bbc3 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5a402f4ff2521978ec9a1cc58e0a87954e46948e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d11c6eca82e0a9100d0d50d57a43acc0d06991b2e21eb6eff7b089245368685 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d92579fd95aee209837d45082b3b356c9716ca8b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:15f8e3024dd62268a2398a89d07ae61e96e1d41531a74a919f3f025fa938c5ee +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5b0a2432100fc991c08f4124a8690c4a7102626c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db7e6bfc7b94bd5ad744097626148c79ab7334ad5cb3de320ff4f8b36a4e719c +size 259 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2a46dc0294af8413320fc3d932da96d5ceca964d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a4f55e7fd33edfead9868f09aa942bee3a0d6dd071564fce97612f875ea8160 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..bc3c5d4770e88eb3df2eeb57fd0a36b2abb756a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0718b6963905101eec88b075186859e2379f3f61d70f492e30941b323072c94 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65ed7fb261953c72d2734e4d1dfbd5c1fa61ff24 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:206e30cd29010a15d526d9bf307ff9e220b93d9d65e142498c913baa5b2e6794 +size 905 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b2525ddf750cb43cb10446426478ca0d352f9d87 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c378d9fa551517824323a936dd4bfa1176ac6daa2ebd7a0948e5537a27e1b64c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f6999ba31d01ec9f118325fbb37a1bdc1f1c97dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25ac461df4235687a4012bf375919c8416dd3d5f4934002a33a47359702f31e0 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..14e1055fbe71324f8d1b316e7c42fba105dcd5ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4df813362412b44dc398a2d105242831190a9f46b54a0baf14f319ab9b0a43f +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3a0d3c9b2e132ba75b354c6d433fe5c6e3dccf69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1903dbe282b8414db88bd733bed0abf2cb61970b92826102a0da5e3cd04374 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f5723c53a582026c2ee3b1e92972272e297ac8a2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9fbe41349d882083cd3eecc13ca6f3af44bc47878ef9426ecf24ddf30aa1a1b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1351825de5ca06090b694cd42c3ceba59d97e794 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6358398a28b79dd57ee851c40462f5a514180d6d06158a58ed104e9af3b16dd3 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..44ecb044b241ed35d3bb8e36d0d236c93cece41a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f7abe796aa6e50dd2efe53f6285070f2b3b38e68ea8e02ab9b324faefac47b75 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7a22dac1ca8ef349cf2e70b8e8c3aa8147f43bba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6be0b028d0c36c4dc84cef8da80044c409ae99bea5e4032a5f657e14778d0bf9 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d79bc224a67304eed73f67dab601806dd36cc011 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6a642fcfa77c00fcdc72b9601b3ac97ce51ffa4c6ed8597fd40fa813c6c441c +size 578 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..07c8183cb7a115a895147e636b4f94c773b98112 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:229cd05169992e974284aef4dce3a714d7f621072d7e3ba47bd0147d952c2032 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c933269e3b15eff51fd2530aadda7bbe13e702ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eb14e8186c7ee0cc954ea8c674750026de784be55db0371d7eda25ac7119a74a +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/default/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db8a2977a47b2e060bdbf2c7bf7c835c7ac3b701 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1044d3337e80aa3a09e1aaf07c6e0f944b8232c70027d2d650c99a29cf4ce84 +size 918 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..64169b1082ba9f39304adafa7713b56f2fc1cc5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1d6b146369ba3283478dc5a0016a8f42ed56d7df0a9057e41604f197e5cd4b0 +size 534 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e2c3ce3255a8b50b919da411cdf7186713c7be4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16cab54b8dbe820078b4538ecc0b3a44b264e2c1b060dec84f891ecd5cd8e2da +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f565d2a7b29d12eda6696ce249df33284dc3e942 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a89df37209f3ea372a4aa65a723aa80ae696502d7e39d61b96368b764b41ef3f +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c9238ac80736514455ce9f40ef17558e459f3811 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:020ad746993891a7b7e1e3680345c1d05515c059d0685a126c4473129166e150 +size 554 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c461843206ad3cbec9b3d2a03ebff8734dbcc8b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef0eef618b42ccf2c403385457cd075ea3815ac3b323206e0899b30524cfc7b1 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..45028174fec008f49746f487921eff5a9ecabda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16f7e4f7a24d25d699923ba9731a92b9abbd4808ce3dc14368d657114f701ecd +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..9df42bc64e8658d641d774b89b55bfa9cb15409a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5490d1e7ff5355cae1350dc796760ad6f75259ff7fd92387d0c18ffdffc3c85b +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0d61611df3edb22a4fa7e17866b3528ae725e646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b22a91aade7709026caa9df573adef3919be7295d2aa42f8adeee2e4f6cee8ef +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..1e3be13787ef2353940c2ff97f4e3c458b859d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d554d53508f81e3d86513abaed89d81369c452e67648b445fa8e245bb8fb3ccf +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae8c50f8789756015254621cee945d1bdf240692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:619f95f0490e193ed51da45ee60e9fdb393f6ee5e441117bf0446d763304ab1b +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..406ff1087ad01f0f5924482b967d16b657344a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5970542d676a9e85db91793c1a6567883769ab254860f446948750825e715d2 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c97fdc4bf623c0bd2820e22b138e0e8db2554855 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:74f92933f99075ac5696382e6a75e06808873d41d47ddae66d1bc0f73a87dc51 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..c6548854b54b44b909f204e40525c40e25142db7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ea4fa210ad435e41e9bf2632985560871ad757febc593f33fc1c6ab9fcf52d8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..eb6fd2749050c7886b58f0521b256f7f4d054875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c50563d980018084c24fe631e2b4a5f3c37a4c483d5d1f3f71c0d1001bf17cdd +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f4e72e3ca6322a41543e3b2817a682244ad04229 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b41c4feba56797309e908d0c41c8a91a0fa443c9ef5813c34daa30b0cb61b9b +size 951 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f354a7eb9b7cba64e1beb92da8258b3df548716 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0502b6755b48092f0e9ddc0a1f9e7910d8c6a6febcae015f5fa52cab91da1b4e +size 659 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..d3733b848b938dd807ec0a3cbc198e43a038264d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91a7a88913f932cf51b78509880337d29ce7aee87fc0488f5c686615f3a7f1c7 +size 661 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..93259a0b10c64dd8521ba6d3778a597b9caa9c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b9e7252bf842b1368f383a1fda59c5052d65cfcd691ce22185b0b3bd3a15e94 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fb86c4fa071f539308d8942d26bc788ca701dd7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1684541d340d8245725a274cb0f3a8df4269897bae8c0cab5ab13c9ec3410c9 +size 425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2c465e0671a0d8eacbc90fe6eca9bc28592b154c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d6e731c0d11226bcba2aa47683a707a8d0f85448d76466083b2c860f14dcad2 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa2b02b1418f83403abb6bd83fe1fe510ba64feb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1930c824d53c8691382820704e0cad315325343252257232c15fcc7ced22593 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..80d37feed69d46b96bef16cfad0033c3867079af --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a2d82505f43d7cd538c651690be0eb1b6750dd63ddae81f3da55f3366de78cb +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..3047c8a18b85dd975e5a5fede0fa4f3c4924e447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0b8decc62991b71d8d02bdfe76474fae54dc771e37cb7e5cb388ba93e2b5f63 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..12c19d9c8b4f9ff69e3b8b64a4dd72c542ffb26a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e72aa8a518936938f25ea7332941c9797ae045cf0aacf15b210496f546374e6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc2cdf43a114c76d6f4d2f31044559cb0ffb41b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c2c01bd6c97390826b97479ff7d2e267bd8a938b2d94838c2f2011bb2996b2dc +size 612 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..55801536016e53760cefd438950112a0ab992a01 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f50a6eb92711153300e23c4e8bbec37739c833cdbb38b12ea7e58e9e6689dbb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab187e19301452f9b46d116fd253c282a43b6d0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91404eee27abb530eeb50afcced5735db92546d32521326001405be6a5c40707 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/diabetes/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..333f6c895f63304005939bed734c5b4a3ba23495 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1bd2f7237c6614f727625e42237b558e33e022c2fbd79752fb3246f7b44eede9 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f7158576596ae7788b845467937ea3a4ad9b7889 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f1723bffa9730b2dc8d2e657be7336222ea277f78a841ed2e9f575416ddc7b4 +size 541 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..436b7fbc02226c3d4a24fd72c27d268fbf54b790 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a79a0099644def29c2966fd35dff1dec2e05baf62b955be7410128dcace002f +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..8fc348a12063c0c14bb14d84fe5f3f42ab00b40d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:519804cbf1f8f280277dd9beea08329578e68c3b22758bdb696f8178e57ba3a7 +size 2505 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d221aeaa17043ac673ddfa8ace328304852d5f9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e91f5a1d1f3302edde0c65a604cdc23cfafe6c0b418cf2a8b83b841c7c342b44 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..61fd254efcfbc44b3885c31c0616e157f66e720b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:601d66c4668274449c4a46b98255fc3bcea1cbeb0052f0936ece08fe190fda5d +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ebe53d92f95f03144b958faca7db5cf3e15b1a42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17c0e6a89a4b5bc58d756d439888ce605ef74efa9b177a8e8c6af9b405f1361b +size 4800 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..61c51c1d3b9ad8057df88c53dfd6a5bd442fa328 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d743a8baedd8c4c815620260fbf23b7330b1498a3d7b26f84fd1ab4ec64a1b73 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f224d16ca9341abd1dae347b7de8de6fbceaa3bd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e2bedbc213977a3b3fe5e11a7c04b32ee3017838a7d09a887bc460ee8227ff6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5ffd2305107e6b846c8e211b14255e83446be141 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3cce986a96cbf4423cf1bcda4f374410adf9474e039fd149961c8c806580c03 +size 413 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c617c43c04116720c9d654763c72be848070f707 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94eedba18072bbae480e6fbdf10104f668d6666848d6365be3c36cdc9bd66a35 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..85d3c0e39f51b351408d4f0435173c1a395eb070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2392f0e4394cd09cb0cd45b87aaf5188496af4bc5ccb1cd946540678a31fe655 +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7278ce874ed61570ccd5c1763a3aa160a24d8499 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:048378c429d0dbd4891b9b12c50903e3554e9d84114bc23846e0b648b579d1a0 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fced6196078064e5431ec67e3ca68252a8e1fef6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7b25fc4d49942d7b08d84b9168f733f4b9734d568962c4521943a3c849662f62 +size 589 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3d15815d1593a179fcc73748e47a4ab5fc2af4a0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0a72d23a0ab11b3df278791ad149095aed53d782d7a6ccc3511f4a860f80970 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..55d8628bc23724a14f674ade448134b1567e4520 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1db91a1ce3ffd88daf75415408cf9472ac868bcc8168a0cf75366dade0b5caf +size 2408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/fb-comments/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..06bc386a1db8469c5f21b3c8a2c81d1741dd446d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0a64df287ee37f9431a592eb17b0280e440d02a003fee701ff2945ab5c37325 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d7413f0670c6edd7361c9c7b82d9fa85aa6a0908 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:32c35703b248e0f0372b9e4612acc3a640730c95fe5e451abbe4c15731b5d6e0 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4d367e9abe1b44d5bb3b0dfccd75ea9967e01916 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa6e6bad2cf4145ea9388b0d207adc07ac8c571c2f779596e036e32e42b09fd7 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b10013726142a28b922fdbbae928562aee46db9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a12961a2ed12d47994fc41d22bc8f7f7e8d4c958d0d73edecbdcc5f8e07b4435 +size 2395 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..047615bee199b90843580fb20f179582f8f09996 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4613d2c2e1fe45c33d3545570f7cd4c035281c1909252be0415c0b95e298356e +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f01095b225b915cbb53e7577a076e32017c1c8e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51071871bd60b5388d81e23d9d36258836180796270dc482ba564e9621a2a643 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4d08b1150e13ad1bfe9fa4bf5c4a564a07b0eee0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30a844cd0dd2933bbc3dfcab3d87e669552edf034821ffd0a6a4a18f71d813fe +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..348755b263dded3e570682a653db8f053ca1357f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b3e6cd385cf4f905f491d54e29cc2ca35d9e6f910999af71ba913b3c5ef802c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..feed14b0f46d70949715e5e0c01a36d92a853510 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0993f5e522483b64d082bdea9503f95aae33fd65167630c12d82197f46c6dbc +size 929 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b13723f7431bf66f747a541e4991ee427f7c149a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0b25543c558ddd0bb6c114fcbf3e06b3c101f7733543b9013a9229e02d394b5 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..3f4e583bb1fd4b2ba0ac11ec89b8b9e2a2a9f5e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0ab5ece732683c2d181b262d5bccab99821fb12b880ceed78f4e040b8c31993 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..28deac7fa9e4a94c6242e0f0c6ffa4f353e8e08f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b63b0a26f2f87c7d2661655b8c9268aad1265ff4d7fe4f99535099c6b36338dc +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4c7232e3157e1133cb14ddc0f32436404e94c0f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d63b0ecacc41763b74551295b1542ce7c29c00b558c404b533671f3200842833 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..10d829f9802860a47baba3df9e9d8f7ea585c8a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:951c1d3750cc6631207ca7d6703a58c674a0409ab2eb63370aa2d5ba4700d7c9 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7237a8277a25f0c18163cc5c8f02a0495ddac37a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:11337372964d7148d6daf843a3f8a8456fcc2abb21a7d3bb1b2d71ee714f139b +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..24334b8d23bc604089b3b05e472de861477bd5f6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:48e3c7798c169dff4e5c80a35c11bb71eea5b91b14cb3c80f1ab78fb1cc8b34e +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c6f4f10d7bf4debd0e0baced9bba617420fe901b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d055d710a9d9743c9088059f5f3ac687c3b4a0039ecf6749df6f669542add73f +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a32da369bdcb78b612f903c8ee05338643be7afe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:398f0937631d218f8637e9cbbef1383fa54bbb88b4f9ffe33acc1a836a479d29 +size 2386 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..03d0abb886e6c6779a9ee57a90d867d538b266d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:be8a997b12a5ec6cd39aeaf7c46fc98936f8611977942d0474a0a20255899bdc +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..497c8110776c7faa8eeb0a2a35accc0b0cdee6cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d28d5b507fba9281f6f44380755b807674395417b853bd9442ee8ad52fd0f43 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..45c057f2486ac293fedac404bee4615cd59c1a97 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1099d2e1bfcc8f278c6b0a4cd6688526707eb2b7d80c7ea784d2d20db8b3da9 +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0754e116055863fcd9138a0aeb61e3fcc087d219 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00542b3e7203234bbf573df38c9c5f06ddefa0658f337b5049ba8c35a4004905 +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..800189407f477c0ac2ec1e17adc27f582d5d4a7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:97fcef113d1275c3927abce0ee6745447b6c2482baaab3eea683c8cbcde7e43c +size 2384 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/gesture/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..03fedb7c3dc25ad84d634da3a8b9380a858b678e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6a307600a0653c256432674bf2aa90990aba5f6a2a106e98e9618d588dcc7b8 +size 948 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ffc4c8ebe2fc39c897e30d7de49fdc1c2d31a66f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:760a12bb8b1a4b9ad522cdd0b61eb121b7d284024fd33f55493d07f96c1cdd5a +size 542 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b8d4afdedbe29648262787959ef96af1044f5f4f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de053c21039056c72a5cc3f09c7ddbf4ca3f9d16a7470c2f151e8c2c5bc461a8 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f8f46a3b3f773b4b986da71fd770b536d8aaa389 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a213faae594be359b84b406ab2e095cda9db5f9ab84e615970f1704259419fff +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..39618b0cdfe57e8f1b175668ee707b4e9910e808 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b991465bc1317d2e6ef0e57d37db6aff1108f4e6b492153c9e8389ad2512bf78 +size 546 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..75c93249436dc211b3c88c2dd76b0ac75ae03555 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00ba696dd5ebad1b715361d289aab901914cabc28e4462205016e273fce0d66b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..011849d3f534676137699f3a314759da540695ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d55c8036621ff2c9b35825e8268b11630b73ecea40c3854395f027fc44a29550 +size 3335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2f712d395035e226a28266e663d1036707bf132e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cea498edc79f0cdfa0d9cb168b8500a2832a3a2089775e33587710d887beb4fc +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..dcbb2d611176a2d8bf2043af45f560aaace04ce5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20a3fa610b0ea4fd4c5b66bde8f49a35b185a8c74908324bbb603d36ed4b7428 +size 989 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2dee08d78e7baa81ad1f2a43ec880583703c019c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c23a761b16ed59a3bf4294de51155c8fecd406103e3a5be1c757d5754d8acc6 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0cc09486dec2ed58becf0eac48fbccd216ff907e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f508f21ff5d6e2510fce419fcc73db98fa0913b263a0aa8074b3b588ed51b1c +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f950dec45a8f48ebe7a2488eb48e30043f36f109 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f8469720ccb837070f8d1f0b4b63151ce8e6434620f869b7c5ac9ff36fdc1b5e +size 6634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8e705ffbaa56cfed732689cd10dcb69c4decc919 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852e37effd946fb65b7f394fea65547d8f8f3890f63eb9db6c06a4cb6503e85a +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..75556e02a7e1071f92f499e9b9e13ea1d7db7c6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2705772e9869c7fca46bab06caaa10e427e5a1cd4d6ab5042a6e279a22e720f9 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7c62e69622e87f6d7e57ec9c82c66d61390c2d18 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6561fb96f7fcefa5ad991ed8e641629aefadb88e54ad82a072a3e83e22ccb35d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3f3d1c6e95ec4d69e9b8553aac109247c799bb91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c3ca4a3f3ead7e37b28bd406afdc57ac1739d5ef6508fcdc0e201b0bbe4204ec +size 414 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e4875ccf24467d05d4e8cbdc06cddb4a5180dbd0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:344d767fe2a9eb740e16d18883d7741ccb939978a3b99d7e73563766adaad05f +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a52d447e1aaab3ea5f028cea2de591aafcf45424 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d72f0802d95c5420400626fb325cefc9aa236cb6dc58314632ec5d4169c4df67 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6a33a35d66132cbc14f5658343ceacae40cee5ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cceedc073ade6c8c8c944873e34bf2938ac96cbcbb6eaf05954c50b6d9085e4e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9e8df7d13edf6634d616b42d800942e08d955062 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a557708d6af14a05fa86398f34357b5d6ef232e4296786a5d8e9ffa9c08c538 +size 622 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..25679afa0ba5ce7a6c2a746f04b2f46f0292f4ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:615fecbbd6b5ff85730ba4e9fa56efeece74fbe38f9ea1bf618d440acda6a3c0 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1cf49237444d6800803452dcc9bbedeb8bc8e950 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:927b6b4caf572c95a34e24ede594379a2c1e726db80161d2947b1593f0cdd138 +size 6665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/higgs-small/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e7e2b814e25f5bad1bf9fcc595954e7298eb3ea9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:528b40c2d3222184ffe33f75d19cff368f89da842a9ecf026f79d5f27bbe5276 +size 937 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0a7a4de2400da5fd39dbaeea852e919158901d45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bd3302bb25952c83194457388db6fea312a7df0745ba8ec476a158c566d70cc +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..80c84796e2f248316457ea713365801da14d237b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0a1bbba8b256a7aed551747d9063887f788472058b7e293948c4d47e242d23b +size 469 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..181bf61c695df6664b710767b0fb71afc8437d81 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ac9e6f524f29c2632ed8b9a2646c5425a50feae61118d3132d65320d608d19a7 +size 2479 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ff88133c4fcb328ac7b16552747fb8296426105f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225d032d97754931a2c9ee8811d21e445ceffedcb5035ccf634ef48ff87302ad +size 995 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d20d4457b1232ba47edbce4f64cec5f6fe7f1c99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9c7e4b3aea3b986a6636149776c64ddddb2cc600f26b257f262e4b56618b3e8 +size 930 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b8ba0ab926f1cfdffa5fc258c9f4d77982ce44d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:666746502985de8e700a9fcc0039bacc9bd146af432fb05b82b54355ab2424fd +size 933 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..042dcc933ac97e20ed3a22ff880465b27dd5ab9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb98360a56b180db06997eebd23a60482932a3747975bac918508bf02f4fb9ce +size 4915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5fff3289c7229732080c62d40d12efc032146f78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a7328a8b0d0c9a7de6226a7a1b8e514564d3c1083eb12c4ba617c5c6807e0228 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a693dec0d8434fab0336b794dd1e28c68c0241aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9045f8011c485cb55e81c9b4e95ca0fb052c9a3435e35a69a97b41797cf282f9 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..b7fb08dad9f572208abbeddd84e0740aa356c230 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bcee542673a48e33a23092776d8e96e6c1e4f3b21b7b8787d1f3a9073f218f91 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..adc4214b1b074d65987ed797ca6cf6448a5747d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ffa43c89ab8722792d7bcc54bc7dfcf5d41bcf20e3f3abf3d8e88a5b98e5978 +size 952 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5724f365db7fa2c28eed384744e97dc87946f445 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:23b8b7b4d549a42eacca574e4ce2266e7c8bceda5272a33c987eeaf80b7499a5 +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..2a998cf2f7de0b928103b222f8535d6c0a047e2f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7fe0b81e4deea87c242192e524807db9ab3f66e1dfc74aed2e3a78bde723f0ff +size 294 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0aa03ba62b1f302975116c4708a8a2efeda92ba5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2442f27f517cfb43bbaf59502be5cc6db24b9a097d51358fcc9df365d552dbb7 +size 402 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..314883b6eb24933d65156973e1afc1b27172f10b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d4ffd3b7adf6fcf1d327e847091368ecf0f71b40cb8b90436c604dc8a54669b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f4655be603ea1109fa208164026d376cce26be50 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b70d420cdffb87014e9fd9ef019ffdffddc58b56804ca2e611218f803cf28ebd +size 2458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..d624e6d584ff582a265185a7e5c00e6263171faa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10dce84b0bbee2494ea0aa43beaee9c88dfb5a403bffe74defa700d6c785999c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e4e13829933f8764d73215cddebec4a13a2bdc43 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ca465ee811e532a4c5bef81a989ec7d2f6244a5d4742d0c363f74400f207d533 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0553bd45d276e79f8b49d933bab6b0cf2932682d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:200ede2a5a9a98be57706e3fd0590aeae7ec160b4ac513f18623c24115764bc3 +size 574 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c071992f864790d496ae83ffbee48595a2ee851b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b6611f4f0149cc926920743e7476379b114acddd6afd49d1bf6d21f85071ca6 +size 470 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1aea951026ffb023621fece858640941afb21e9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:861abd015a5284bd3a0f736764f7da77b85787132d418ee479a80208c480e7be +size 2465 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/house/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..2c731f01b582631631de6dd5b69699a73dda7413 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82f4a7e5f3e84c7becbb90e602fb8b151e344a33b3f312e8e7387c05994688f0 +size 942 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db7dd19a68e8eaa1a90ac71139a334fb0687f77a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c9c1217f32b6b6726f227a57f803421e181ba4e35157f1db5f9ba914658f5b94 +size 532 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..82defe6d7f8b1ef7a378ca83226604cef31b6aef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd069f690164256d25dfbde0ad8790f77b5e232dd3f0adf64410b640bb54c231 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3cf46d58eca19c1941ec9ee42c919739cfd8e614 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4c846e7b87f5eb231776d149668781c3c940551ed2fa64ef6a5954b49fad91d +size 2460 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..82b2a87a76a82cf7e0f9098ff754cb6038329b13 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d7188e5d993b28be90477dda30d16dc4fd1492c0beb9938af03db9ac3093d8b +size 999 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3bfd8fc770eb00509cc2d7c43232a98b8dfd6cac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cb22042a278459b9fcb7136bbb89dfdb1f13ff0258629814005e0cffbcea145 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..59869ca6d0de7c94394c981e70dc95c0e1d77a48 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9de0fa18e75155189845e29cc0befcf4d490d93264d96daf62cf75a30c90266 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0676cea17ec67a31e17a9cce1fdf6d11fd3b227f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89bc8213e080f76469119ea5b91e606453193d49e4a866cc495b0a589a9a0c68 +size 4889 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f0ffcb99149d3510c70a5924f8c422c8a76150e5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:43b70402cda9d2dbe0bb5b51677c5c9882bedc445928c28a8c3d88f0a7722597 +size 261 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..6726199f5fc33e63365f3a27b1d556e34018d3ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:323963077416988f3290d9e3816e6550f872cd8744295396c19e5b6f5dfc9c14 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..2f84826ccac5e886b0d45f3c7c185c7f194576b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc777a785cb2c512f87e6116d47f4a3d9fa5260f629c979d6bbb23839473670 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..68c17c15294f2a17eefce1027bc156e07915aecc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a64ff8200cb6bb6f30ee4998d6aace8fc8066b3c66b8337b16a24f0b57f4c8de +size 956 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e68da611dd63a6d7d426532a1ebf0e81cf3b9ea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e8beb48203d2108f658644d5cb799fd535d800dde8c722ee8e5bfa2bc21e153 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f1e0cfac11b1db4108d81e074b24ee18d854dc1e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a8db2791e30a92cfd9d3fb5d6186b60cdd93fe10a154ad1d3f6c0d18c1f83e45 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5bb618075a1cd648a4818610f2382e789cd4864d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddbec95d017fd0f2afbfebfcb57b24d887f5f2878e4d732234866172e05cbb +size 304 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..96cf783f5a78a8b7ef0943912a1c8a4e7c1a9b04 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8325b46ce43140b516ff717a80827ea672bd68ac683a1d57bcdc8339d931fac +size 408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8e34e5dba6cc530710d3f1cf3202447d4f58bc69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9121c85b1e76356f3655e4188d9df2b4dcbb6da03d44803100e78f535ce1cc90 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..96a4fb49c1309ee79dbaf34b2b2bf4d72897937e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ad727af1046c6fda6ee582100b49c9a7ed67c1c0c833b1738d205d0fa7808a +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cde2235be891eb6caf968e73420ccb7e93804e79 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:21c2d26d84679802f8b4132dc40995239cd6f33e70767dd3bc120baa6823d895 +size 2451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1d8ea5d488d6df9d75a1923b24f3125b08db535a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e76cff7f9b4eb2fb998b889fc817cf39bb249629db4daa02bb446e67f07508b5 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8caac97df53e7631ff8245ffb7f93f77993cea33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a03e4df9aabb8171933be16412b46e6b923800570a38e64e5d4eb47678b24dbb +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..637a56dffa6df001c96821966fe51c863121f1f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30af5515640c2f6e99eb4c3c548da06f3655333620c97cfaa8cc8973d656b9b9 +size 613 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b2ffb33dd7f41e85f904227b5db70e908beb69b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:935545449f1a16d3bad494acb6696a8b7748aabad97ecd0ab08f8207d4720518 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ba59bcf12636686aec9d51472c29b53e312cda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93c7fd438e02f13da168a75942fa3f688fe5bcdea85fa36d0d3a7ea9a5166e60 +size 2453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/insurance/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..01b0c1903a668d152e59453c4e4825741590925f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2501990a6f1a9971d56afe74d8325eb72316b430eab61f47c20a4733816718e8 +size 915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..23caef05e9d2f190d9c86804e5aeae5964c0a74b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0410035c53684e65b6334f5656d05b0f07bea79dacd6572a2b4dd53997c8d9e1 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..84a7af1afc2b623f4a2d67bb18f87acbe786e635 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a52646d49fcab248f6444fd18ee3c49d18dc08626d7217040171f968fe3362e9 +size 474 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f946659046f385d36df7e50003affca94254b83c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5c540660e687338c470bc5aefa1e709ccd01c1670b59f7ecffd2787dd1afc2da +size 2494 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..89dc12ec8c39aba29a00ba8c25104fdbd2ba42ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0e482c20284d6d6000c0148e8d374cbdb418c41f2c1b3ade6319b328b1a6a02 +size 955 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e142ed3b2f59d2438094cbe8677e78e8c04f660 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9549ce6fe83ea01af03e88d8de5fb0005c92f42b572c47b8dee23d8dbfbb67c +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a73dca158c0ad485c1ddf5a609df587a5995ec9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a54c016ba583d3ef7edabe2b91352de11dba9ddbd0a62b7166ca2494c6277a18 +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..9d034d585ff4a822b9e63c222e54536ff12c2a57 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5972998ede37836bda6c5e6eeb12e20c861d3909c4b744f6dd58459495168f3 +size 4945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8705207de466575515cb19bb0881cda69d13280d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0087b68b0690a0d317050eab0c6368ce49c6798a84f7bfd43029c2b0cb9cf1aa +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..60be27b26835fa89f9ee4b9579363c81b641519d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f114df937a0945e54dc4283963aced75bcb1e5d5fbd416c5ff5e7e812cd3fe3 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ca413e55e34e5a914ca4b0ffecfd729517122e63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d0499695456bfd89bcbb3e16775dfbf3491afb98b31a6aef86406f485bc2165 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59ce7d1bc92bf414ea62fd8a190b32f3b8ac6c5e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc3ec78379ff2b32d2f5a96626e368cd86dd2f41195097f858a4c7df201405a7 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..77acc58bc044cc342c01f2499f0e486614a8f070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b185de1dadacab2591684c34b38139226160249070984909d5850f69e8be919b +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..7b1cff297b211e9d7fe781917de6cb1832d3ffaa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdd2ac1705b46fa74fd91bb9a9d298ed2c2619522583f2b04e6deec9507da733 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..eb3dcf1ba4fab107a4980cc00e2947dae446a951 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04e492ffe3461aaf60a3e057f86b7e53393d186e1056fa50eff7f58f79f10dc7 +size 398 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8a61230d936a15c4a41d014a7363aeba42516d47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5e598f7893e22d41860ceeafea212a0099f57d612b866a6712780c54f049539b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee911fbd3baabd3aa7892d4b0added38441098f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6611343af6c0bba0fe21919246a40ef932677f1a34a511cfccb5396c6298e73 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..68c9b9046264a2174c9961b75eff74206ed377de --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6857de43e22b45c9e4d371ad7c24ee19a913bd39e60cd16b1a2f3229cf5038a8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7926254c224b0a0f65174156f0fec386102bb541 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94644b28f3612e23555b0475725f1ad18f9620b7acee9348b501a40852bf5b3c +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..619c2e20cfed2e5293d150b872a5733e1f096c11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4fa9c2b6c9c0379e006e4490691f7ca47d95732a984433835017b5dc8c6a4bc +size 572 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..a96478c5ab30457034d6a7a0e1948a25dedbae3f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b221985167ba83bf9b2e8a913d0e683a9a71701aa8a918d674c292180dbd85b0 +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cbeb7697694fa8b8ca4812825c752ecb6083aa7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:194eeb00b693f9f992dc12f48d96eb1e99ce8fa94baaf7a28bd5ffc83657c390 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/king/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59217f5e124abdb29822b055764cb2336192324e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d27dd7c459b26f8da75d5d114d757d3504c4e2ff1fabc9145ff0163269268523 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..a21b74b88b43869b7621a6fa69ba3cee54f99782 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de9e1c2397774b4f140e72195d67299087201e8f7c3398f553a6ddbedc37dacb +size 548 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..dcb82579a446de24c76a01048e7ee8b45dc416ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dcf46d3c26fef0a4bd282a1dd5540c51306a6c6d27a7e021bdc3fa1f04aaba8d +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b964e2eca120d5390d8dfd54da9bca84a89b0964 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b1ecaf38c6e4e86723eca4b70df721230ea37325f3e31417136f680ab6d60eda +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..005f4532ca87e7bad99569be51c03d60c2e731bc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0873d39afcde743c203e38b936cf02263464359ed77ac9a4f897f4f0003ee8cc +size 543 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..95cec34a17bdc318a6f58a5142d836684ca8b741 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f94910601e7921ad016dccf2efd73b43f3ddcebe8222554c961020572046f8b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e263b0da0906813ed00fe2505223f178721e46da --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c0ff62cc7415bfa76cfb5f8675f03443908fd52539f49078ea10f6f78f6785e +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f75e316f0a7cdfa1d46f9089211b3bc1790045cb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e11ee201bd58bbd68ed03ac5c6e098db1691d6ba740612efd613d2e21a7eba5 +size 947 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ecb3c2934097a8b7eb1f1c2e8bfdcc1bb6c25cb9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c24ba2f25d79231cd18c84ab6b5505c3800302f52c60ea4c470761fa0664826 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..318516c152168e5aa47c6ec1b99f2de9abab8478 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f11aad0bf39ecbcdfd2e236f22f5686c5bf53941e2bf72066b650a0495bcfcee +size 6636 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..b877e61d6fccc1cf63a37573330494d8c250a097 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4f4ef7a360cd7c0246258ceccae40c700bff07b1c2450aaea29678ec997c8fb +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a4c5e18b0426ed2e74a44a403050bf1a5e2be397 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:156845e255990d64868edf68e6e94e4b630a35ef3703908d4658bb4205e6f520 +size 219 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..07359eb10ef90d970d2fd3da8589d23419ba30e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6eb570950be50161b508f032ab7b386834970b1b8320ea009df29b04fb4f59e4 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b71c94cdcd14cfc6ad2b5769feeb0e46b742b038 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d399bad7ab925769e8dfe3077fdab3bc853c456621aa535dbf11b13b649442bf +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e434db77ae4112e9c66a54159b515bcabbc35500 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:daca0ef299413efeb2fd8bc598c2884ea7fa8e31cce9f5b22453149824003a31 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..fe89340b3e1abd6c60af42955bdb945c8c73fd0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d264ff9ea11ec6a85605548a246318adf764036594d2487c6fcd011e0451f468 +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4e0b74e541216117ba45eadda4227de72b77a583 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86e468ac66b04c5880e87d36fa4a0d0f3a8ccab2d862ca9b2a087704161aaf5e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..8e31eabdede3c3151591a3355d35481bd467ce49 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4fdf1a753db96dd0306665a4fd7ff63d384e63c5e38427c3ea885cde8bc25758 +size 564 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..fc3508af285bfd1620c768ae0ce85d0aefcc3fed --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ee426c8141756e86ed8ce7d5e105d1696811c92fe3065d5f9a542fbcdb2cb41c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..65895fb508351e878a6f865720c80608c59f1419 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aae996fb7337a2dba7582f817f088044dd4fb6e356600663f63c85387a24adc +size 3333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/miniboone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..126909bc3023b69440daf8f5981671a32775db42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0a8bd128e8d1a59c0fd1a6bb71d659c72bb66d99d25b64a083055aa5ae633481 +size 903 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48207110d55524677f763b36f2ea6d082538c8e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df7a70b973fe406e3364c2b6674fc4be7e63a60edaf4bd81fb74939cca9fb1ea +size 526 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e47d814bd5c743b65a2e956899c1a85ec99c2971 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdc03d3794d9a6fd78252a8f39e39f6a821f2499675d821b05ff4512e594de7a +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0d59d5db6217391068a935e4eebbd36a7dfa9797 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c65acdf11e5ec81bcd0551c6ee0e1bb1da03acdbf8fd61ce8cc84b595e4eeac +size 3326 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..992ed273159fe044446338ef18d20b301c4389fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:abb13507a3bb052941db91eb54f82c61763476196c0f582cac37b54b205a63b7 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..113e4f8760a40e53ac65debb316e5334adfdb6dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14c54983a20fd19a7ba0656cb4ba0882dda6ded11e1a3be406d047acbebabc21 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee4457b8f96d7e9890ea1b76a6c65bde78330030 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c10fd9c09819253effcae1c1af19dbdf17bfdc061427e24047454e53e300f57e +size 3316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..fecfedfed0d23c1f5790b4d32fc72b2b927abf9c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61cceaf47946a5b94f37258fa4d53bdae5417731ec3cd7969824506746355ef7 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7040f0d2c1d564884b20d1aff4f998c352df6e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ec6bd6a69e0b83faae6acdbf6c0d22d33fa77f18fc9aa4dded05cee01d011c +size 958 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b1489b2408568ef856f9b7691a6de90395656d55 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6760aab482af996cbd94742720668a0a900919957db2413eeb1f18f047330ae3 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..360331f72e267548c985238e8dddb33ecf33efa7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df86c0b6c8fc0e216a53438e3f26bd9e46670c1f5b3dc77426259c971d210f3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..15b6cea0fb960e83bce61a19c94bef54ea0aaecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f8ca0f43e784616f459b84a576d98839d9abe41af934709640dc8e81efb4e98 +size 6621 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6e1b013baf19c0e01499e397492cadb90ffd0cf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04f31ef7049dee20af09577fe45fb41d805af0907e8e137ee3516d0e90d2554f +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1a8fd05bfd33b99eb361fba9b6bc1c00e7fa7d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f42ff2e01094cd2102a388e7fd6124eb7b7cbf899b465cacf0860127e4c99e78 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6c0fa171f2c97dde10256df4376995c3177a281e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c87fcede2165d9a1cc54de5f114c0cfdaa21c0dc8a1dbe6ed1232e8e930df025 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..533af56ce20919d8164fa0093972d0f1209ac88e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:636b5d5b2495c4c123f00fead30911369c615118fbffa66f12610fcfc4c730ba +size 936 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..88505d5882f86ee3507f9e953138a818dc57caa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:722b3ac7a315c79a1bc37fe46cec8ac815bef9599406c0734cb78c095698f0f8 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a718382837cf353aa21a2455e5519c638b6aeac8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e04b6d0b94b457eacd407d0338fa99146f6749339d4b64b48001287daa5b7b5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..a036f5707506ec7bfea76a21e2ee20a931c05065 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9cc24aa23a4db246ab5dfe17125252a50009917323d54e5677507aba6b7f0a38 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..66c9afda1050096fedb7688d56a9a03ea9926b47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e161c1def56ea993fc1e643c986456388df3cabfae0c4213cb15565a17e0dcd2 +size 400 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da1d999c49a6040603a6b508b4baa2b9a6719090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4712ec1d5d364761ad171d82d98b083e0e8b567649793dfa488478beef453c08 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..956bfdeffb7135603d0fabdaa6c8879918cb2384 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9063998cac822118a02b7b2d2a568d909c04fc994db129345a81a481a4fd0956 +size 1315 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..36dc119e8917134f5fe5bed0b6ea84ccba3c2ad8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61fe10a9440af4534e2826cbc566e5192f7ae8947c598d2e84fe619b37a359ac +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..188742f3a544abe1953ff5dbd12f1238d1b9ce41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a5b6a5e9214b8d7e50524a5e9177419661add5dc4d3b06ecffe68c7cb4c5f392 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f3e143c3c192cbda659bcd16a90b1d26c7f3d2e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aa03c0df6c8ca6742c1489e8e37ac08f68c342c863bddf7ca3143426920c576 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..cc8427f26ad1f9ca2dcb4cc6943fab932096ffc8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50edc7be21196e9e790fe8990bc332150d0550db1b2c46e60d19810e875a3ece +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..021c8067d431ea8362123e590cc238472e801ae5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36cf4c644fe1879a25693cfb68d88db11c3afb7a9c075e3f4d2d1ea201ca67c5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bd44eefcc1486f6bd4d79b60858ec5796da81e78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b55d374b6630709cb9d4c5814d856dd2520386b992937a3b24d80d71eb2e035c +size 3307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/exp/wilt/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..54d6f6bbd104c00418af09162967e1fde1dea4fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/__init__.py @@ -0,0 +1,12 @@ +import torch +from icecream import install + +torch.set_num_threads(1) +install() + +from . import env # noqa +from .data import * # noqa +from .deep import * # noqa +from .env import * # noqa +from .metrics import * # noqa +from .util import * # noqa diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/data.py new file mode 100644 index 0000000000000000000000000000000000000000..de47f283d607c411a23df48a364f19f43d2727d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/data.py @@ -0,0 +1,719 @@ +import hashlib +from collections import Counter +from copy import deepcopy +from dataclasses import astuple, dataclass, replace +from importlib.resources import path +from pathlib import Path +from typing import Any, Literal, Optional, Union, cast, Tuple, Dict, List + +import numpy as np +import pandas as pd +from sklearn.model_selection import train_test_split +from sklearn.pipeline import make_pipeline +import sklearn.preprocessing +import torch +import os +from category_encoders import LeaveOneOutEncoder +from sklearn.impute import SimpleImputer +from sklearn.preprocessing import StandardScaler +from scipy.spatial.distance import cdist + +from . import env, util +from .metrics import calculate_metrics as calculate_metrics_ +from .util import TaskType, load_json + +ArrayDict = Dict[str, np.ndarray] +TensorDict = Dict[str, torch.Tensor] + + +CAT_MISSING_VALUE = '__nan__' +CAT_RARE_VALUE = '__rare__' +Normalization = Literal['standard', 'quantile', 'minmax'] +NumNanPolicy = Literal['drop-rows', 'mean'] +CatNanPolicy = Literal['most_frequent'] +CatEncoding = Literal['one-hot', 'counter'] +YPolicy = Literal['default'] + + +class StandardScaler1d(StandardScaler): + def partial_fit(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().partial_fit(X[:, None], *args, **kwargs) + + def transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().transform(X[:, None], *args, **kwargs).squeeze(1) + + def inverse_transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().inverse_transform(X[:, None], *args, **kwargs).squeeze(1) + + +def get_category_sizes(X: Union[torch.Tensor, np.ndarray]) -> List[int]: + """Return K[i] s.t. F.one_hot(x[:,i], K[i]) is valid. Requires K[i] > max(x[:,i]).""" + XT = X.T.cpu().tolist() if isinstance(X, torch.Tensor) else X.T.tolist() + return [int(np.max(x)) + 1 if len(x) > 0 else 0 for x in XT] + + +@dataclass(frozen=False) +class Dataset: + X_num: Optional[ArrayDict] + X_cat: Optional[ArrayDict] + y: ArrayDict + y_info: Dict[str, Any] + task_type: TaskType + n_classes: Optional[int] + + @classmethod + def from_dir(cls, dir_: Union[Path, str]) -> 'Dataset': + dir_ = Path(dir_) + splits = [k for k in ['train', 'val', 'test'] if dir_.joinpath(f'y_{k}.npy').exists()] + + def load(item) -> ArrayDict: + return { + x: cast(np.ndarray, np.load(dir_ / f'{item}_{x}.npy', allow_pickle=True)) # type: ignore[code] + for x in splits + } + + if Path(dir_ / 'info.json').exists(): + info = util.load_json(dir_ / 'info.json') + else: + info = None + return Dataset( + load('X_num') if dir_.joinpath('X_num_train.npy').exists() else None, + load('X_cat') if dir_.joinpath('X_cat_train.npy').exists() else None, + load('y'), + {}, + TaskType(info['task_type']), + info.get('n_classes'), + ) + + @property + def is_binclass(self) -> bool: + return self.task_type == TaskType.BINCLASS + + @property + def is_multiclass(self) -> bool: + return self.task_type == TaskType.MULTICLASS + + @property + def is_regression(self) -> bool: + return self.task_type == TaskType.REGRESSION + + @property + def n_num_features(self) -> int: + return 0 if self.X_num is None else self.X_num['train'].shape[1] + + @property + def n_cat_features(self) -> int: + return 0 if self.X_cat is None else self.X_cat['train'].shape[1] + + @property + def n_features(self) -> int: + return self.n_num_features + self.n_cat_features + + def size(self, part: Optional[str]) -> int: + return sum(map(len, self.y.values())) if part is None else len(self.y[part]) + + @property + def nn_output_dim(self) -> int: + if self.is_multiclass: + assert self.n_classes is not None + return self.n_classes + else: + return 1 + + def get_category_sizes(self, part: str) -> List[int]: + return [] if self.X_cat is None else get_category_sizes(self.X_cat[part]) + + def calculate_metrics( + self, + predictions: Dict[str, np.ndarray], + prediction_type: Optional[str], + ) -> Dict[str, Any]: + metrics = { + x: calculate_metrics_( + self.y[x], predictions[x], self.task_type, prediction_type, self.y_info + ) + for x in predictions + } + if self.task_type == TaskType.REGRESSION: + score_key = 'rmse' + score_sign = -1 + else: + score_key = 'accuracy' + score_sign = 1 + for part_metrics in metrics.values(): + part_metrics['score'] = score_sign * part_metrics[score_key] + return metrics + +def change_val(dataset: Dataset, val_size: float = 0.2): + # should be done before transformations + + y = np.concatenate([dataset.y['train'], dataset.y['val']], axis=0) + + ixs = np.arange(y.shape[0]) + if dataset.is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + + dataset.y['train'] = y[train_ixs] + dataset.y['val'] = y[val_ixs] + + if dataset.X_num is not None: + X_num = np.concatenate([dataset.X_num['train'], dataset.X_num['val']], axis=0) + dataset.X_num['train'] = X_num[train_ixs] + dataset.X_num['val'] = X_num[val_ixs] + + if dataset.X_cat is not None: + X_cat = np.concatenate([dataset.X_cat['train'], dataset.X_cat['val']], axis=0) + dataset.X_cat['train'] = X_cat[train_ixs] + dataset.X_cat['val'] = X_cat[val_ixs] + + return dataset + +def num_process_nans(dataset: Dataset, policy: Optional[NumNanPolicy]) -> Dataset: + assert dataset.X_num is not None + nan_masks = {k: np.isnan(v) for k, v in dataset.X_num.items()} + if not any(x.any() for x in nan_masks.values()): # type: ignore[code] + assert policy is None + return dataset + + assert policy is not None + if policy == 'drop-rows': + valid_masks = {k: ~v.any(1) for k, v in nan_masks.items()} + assert valid_masks[ + 'test' + ].all(), 'Cannot drop test rows, since this will affect the final metrics.' + new_data = {} + for data_name in ['X_num', 'X_cat', 'y']: + data_dict = getattr(dataset, data_name) + if data_dict is not None: + new_data[data_name] = { + k: v[valid_masks[k]] for k, v in data_dict.items() + } + dataset = replace(dataset, **new_data) + elif policy == 'mean': + new_values = np.nanmean(dataset.X_num['train'], axis=0) + X_num = deepcopy(dataset.X_num) + for k, v in X_num.items(): + num_nan_indices = np.where(nan_masks[k]) + v[num_nan_indices] = np.take(new_values, num_nan_indices[1]) + dataset = replace(dataset, X_num=X_num) + else: + assert util.raise_unknown('policy', policy) + return dataset + + +# Inspired by: https://github.com/yandex-research/rtdl/blob/a4c93a32b334ef55d2a0559a4407c8306ffeeaee/lib/data.py#L20 +def normalize( + X: ArrayDict, normalization: Normalization, seed: Optional[int], return_normalizer : bool = False +) -> ArrayDict: + X_train = X['train'] + if normalization == 'standard': + normalizer = sklearn.preprocessing.StandardScaler() + elif normalization == 'minmax': + normalizer = sklearn.preprocessing.MinMaxScaler() + elif normalization == 'quantile': + normalizer = sklearn.preprocessing.QuantileTransformer( + output_distribution='normal', + n_quantiles=max(min(X['train'].shape[0] // 30, 1000), 10), + subsample=int(1e9), + random_state=seed, + ) + # noise = 1e-3 + # if noise > 0: + # assert seed is not None + # stds = np.std(X_train, axis=0, keepdims=True) + # noise_std = noise / np.maximum(stds, noise) # type: ignore[code] + # X_train = X_train + noise_std * np.random.default_rng(seed).standard_normal( + # X_train.shape + # ) + else: + util.raise_unknown('normalization', normalization) + normalizer.fit(X_train) + if return_normalizer: + return {k: normalizer.transform(v) for k, v in X.items()}, normalizer + return {k: normalizer.transform(v) for k, v in X.items()} + + +def cat_process_nans(X: ArrayDict, policy: Optional[CatNanPolicy]) -> ArrayDict: + assert X is not None + nan_masks = {k: np.asarray(v == CAT_MISSING_VALUE) for k, v in X.items()} + if any(np.asarray(x).any() for x in nan_masks.values()): # type: ignore[code] + if policy is None: + X_new = X + elif policy == 'most_frequent': + imputer = SimpleImputer(missing_values=CAT_MISSING_VALUE, strategy=policy) # type: ignore[code] + imputer.fit(X['train']) + X_new = {k: cast(np.ndarray, imputer.transform(v)) for k, v in X.items()} + else: + util.raise_unknown('categorical NaN policy', policy) + else: + assert policy is None + X_new = X + return X_new + + +def cat_drop_rare(X: ArrayDict, min_frequency: float) -> ArrayDict: + assert 0.0 < min_frequency < 1.0 + min_count = round(len(X['train']) * min_frequency) + X_new = {x: [] for x in X} + for column_idx in range(X['train'].shape[1]): + counter = Counter(X['train'][:, column_idx].tolist()) + popular_categories = {k for k, v in counter.items() if v >= min_count} + for part in X_new: + X_new[part].append( + [ + (x if x in popular_categories else CAT_RARE_VALUE) + for x in X[part][:, column_idx].tolist() + ] + ) + return {k: np.array(v).T for k, v in X_new.items()} + + +def cat_encode( + X: ArrayDict, + encoding: Optional[CatEncoding], + y_train: Optional[np.ndarray], + seed: Optional[int], + return_encoder : bool = False +) -> Tuple[ArrayDict, bool, Optional[Any]]: # (X, is_converted_to_numerical) + if encoding != 'counter': + y_train = None + + # Step 1. Map strings to 0-based ranges + + if encoding is None: + unknown_value = np.iinfo('int64').max - 3 + oe = sklearn.preprocessing.OrdinalEncoder( + handle_unknown='use_encoded_value', # type: ignore[code] + unknown_value=unknown_value, # type: ignore[code] + dtype='int64', # type: ignore[code] + ).fit(X['train']) + encoder = make_pipeline(oe) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + max_values = X['train'].max(axis=0) + for part in X.keys(): + if part == 'train': continue + for column_idx in range(X[part].shape[1]): + X[part][X[part][:, column_idx] == unknown_value, column_idx] = ( + max_values[column_idx] + 1 + ) + if return_encoder: + return (X, False, encoder) + return (X, False) + + # Step 2. Encode. + + elif encoding == 'one-hot': + ohe = sklearn.preprocessing.OneHotEncoder( + handle_unknown='ignore', sparse=False, dtype=np.float32 # type: ignore[code] + ) + encoder = make_pipeline(ohe) + + # encoder.steps.append(('ohe', ohe)) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + elif encoding == 'counter': + assert y_train is not None + assert seed is not None + loe = LeaveOneOutEncoder(sigma=0.1, random_state=seed, return_df=False) + encoder.steps.append(('loe', loe)) + encoder.fit(X['train'], y_train) + X = {k: encoder.transform(v).astype('float32') for k, v in X.items()} # type: ignore[code] + if not isinstance(X['train'], pd.DataFrame): + X = {k: v.values for k, v in X.items()} # type: ignore[code] + else: + util.raise_unknown('encoding', encoding) + + if return_encoder: + return X, True, encoder # type: ignore[code] + return (X, True) + + +def build_target( + y: ArrayDict, policy: Optional[YPolicy], task_type: TaskType +) -> Tuple[ArrayDict, Dict[str, Any]]: + info: Dict[str, Any] = {'policy': policy} + if policy is None: + pass + elif policy == 'default': + if task_type == TaskType.REGRESSION: + mean, std = float(y['train'].mean()), float(y['train'].std()) + y = {k: (v - mean) / std for k, v in y.items()} + info['mean'] = mean + info['std'] = std + else: + util.raise_unknown('policy', policy) + return y, info + + +@dataclass(frozen=True) +class Transformations: + seed: int = 0 + normalization: Optional[Normalization] = None + num_nan_policy: Optional[NumNanPolicy] = None + cat_nan_policy: Optional[CatNanPolicy] = None + cat_min_frequency: Optional[float] = None + cat_encoding: Optional[CatEncoding] = None + y_policy: Optional[YPolicy] = 'default' + + +def transform_dataset( + dataset: Dataset, + transformations: Transformations, + cache_dir: Optional[Path], + return_transforms: bool = False +) -> Dataset: + # WARNING: the order of transformations matters. Moreover, the current + # implementation is not ideal in that sense. + if cache_dir is not None: + transformations_md5 = hashlib.md5( + str(transformations).encode('utf-8') + ).hexdigest() + transformations_str = '__'.join(map(str, astuple(transformations))) + cache_path = ( + cache_dir / f'cache__{transformations_str}__{transformations_md5}.pickle' + ) + if cache_path.exists(): + cache_transformations, value = util.load_pickle(cache_path) + if transformations == cache_transformations: + print( + f"Using cached features: {cache_dir.name + '/' + cache_path.name}" + ) + return value + else: + raise RuntimeError(f'Hash collision for {cache_path}') + else: + cache_path = None + + if dataset.X_num is not None: + dataset = num_process_nans(dataset, transformations.num_nan_policy) + + num_transform = None + cat_transform = None + X_num = dataset.X_num + + if X_num is not None and transformations.normalization is not None: + X_num, num_transform = normalize( + X_num, + transformations.normalization, + transformations.seed, + return_normalizer=True + ) + num_transform = num_transform + + if dataset.X_cat is None: + assert transformations.cat_nan_policy is None + assert transformations.cat_min_frequency is None + # assert transformations.cat_encoding is None + X_cat = None + else: + X_cat = cat_process_nans(dataset.X_cat, transformations.cat_nan_policy) + if transformations.cat_min_frequency is not None: + X_cat = cat_drop_rare(X_cat, transformations.cat_min_frequency) + X_cat, is_num, cat_transform = cat_encode( + X_cat, + transformations.cat_encoding, + dataset.y['train'], + transformations.seed, + return_encoder=True + ) + if is_num: + X_num = ( + X_cat + if X_num is None + else {x: np.hstack([X_num[x], X_cat[x]]) for x in X_num} + ) + X_cat = None + + y, y_info = build_target(dataset.y, transformations.y_policy, dataset.task_type) + + dataset = replace(dataset, X_num=X_num, X_cat=X_cat, y=y, y_info=y_info) + dataset.num_transform = num_transform + dataset.cat_transform = cat_transform + + if cache_path is not None: + util.dump_pickle((transformations, dataset), cache_path) + # if return_transforms: + # return dataset, num_transform, cat_transform + return dataset + + +def build_dataset( + path: Union[str, Path], + transformations: Transformations, + cache: bool +) -> Dataset: + path = Path(path) + dataset = Dataset.from_dir(path) + return transform_dataset(dataset, transformations, path if cache else None) + + +def prepare_tensors( + dataset: Dataset, device: Union[str, torch.device] +) -> Tuple[Optional[TensorDict], Optional[TensorDict], TensorDict]: + X_num, X_cat, Y = ( + None if x is None else {k: torch.as_tensor(v) for k, v in x.items()} + for x in [dataset.X_num, dataset.X_cat, dataset.y] + ) + if device.type != 'cpu': + X_num, X_cat, Y = ( + None if x is None else {k: v.to(device) for k, v in x.items()} + for x in [X_num, X_cat, Y] + ) + assert X_num is not None + assert Y is not None + if not dataset.is_multiclass: + Y = {k: v.float() for k, v in Y.items()} + return X_num, X_cat, Y + +############### +## DataLoader## +############### + +class TabDataset(torch.utils.data.Dataset): + def __init__( + self, dataset : Dataset, split : Literal['train', 'val', 'test'] + ): + super().__init__() + + self.X_num = torch.from_numpy(dataset.X_num[split]) if dataset.X_num is not None else None + self.X_cat = torch.from_numpy(dataset.X_cat[split]) if dataset.X_cat is not None else None + self.y = torch.from_numpy(dataset.y[split]) + + assert self.y is not None + assert self.X_num is not None or self.X_cat is not None + + def __len__(self): + return len(self.y) + + def __getitem__(self, idx): + out_dict = { + 'y': self.y[idx].long() if self.y is not None else None, + } + + x = np.empty((0,)) + if self.X_num is not None: + x = self.X_num[idx] + if self.X_cat is not None: + x = torch.cat([x, self.X_cat[idx]], dim=0) + return x.float(), out_dict + +def prepare_dataloader( + dataset : Dataset, + split : str, + batch_size: int, +): + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader( + torch_dataset, + batch_size=batch_size, + shuffle=(split == 'train'), + num_workers=1, + ) + while True: + yield from loader + +def prepare_torch_dataloader( + dataset : Dataset, + split : str, + shuffle : bool, + batch_size: int, +) -> torch.utils.data.DataLoader: + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader(torch_dataset, batch_size=batch_size, shuffle=shuffle, num_workers=1) + + return loader + +def dataset_from_csv(paths : Dict[str, str], cat_features, target, T): + assert 'train' in paths + y = {} + X_num = {} + X_cat = {} if len(cat_features) else None + for split in paths.keys(): + df = pd.read_csv(paths[split]) + y[split] = df[target].to_numpy().astype(float) + if X_cat is not None: + X_cat[split] = df[cat_features].to_numpy().astype(str) + X_num[split] = df.drop(cat_features + [target], axis=1).to_numpy().astype(float) + + dataset = Dataset(X_num, X_cat, y, {}, None, len(np.unique(y['train']))) + return transform_dataset(dataset, T, None) + +class FastTensorDataLoader: + """ + A DataLoader-like object for a set of tensors that can be much faster than + TensorDataset + DataLoader because dataloader grabs individual indices of + the dataset and calls cat (slow). + Source: https://discuss.pytorch.org/t/dataloader-much-slower-than-manual-batching/27014/6 + """ + def __init__(self, *tensors, batch_size=32, shuffle=False): + """ + Initialize a FastTensorDataLoader. + :param *tensors: tensors to store. Must have the same length @ dim 0. + :param batch_size: batch size to load. + :param shuffle: if True, shuffle the data *in-place* whenever an + iterator is created out of this object. + :returns: A FastTensorDataLoader. + """ + assert all(t.shape[0] == tensors[0].shape[0] for t in tensors) + self.tensors = tensors + + self.dataset_len = self.tensors[0].shape[0] + self.batch_size = batch_size + self.shuffle = shuffle + + # Calculate # batches + n_batches, remainder = divmod(self.dataset_len, self.batch_size) + if remainder > 0: + n_batches += 1 + self.n_batches = n_batches + def __iter__(self): + if self.shuffle: + r = torch.randperm(self.dataset_len) + self.tensors = [t[r] for t in self.tensors] + self.i = 0 + return self + + def __next__(self): + if self.i >= self.dataset_len: + raise StopIteration + batch = tuple(t[self.i:self.i+self.batch_size] for t in self.tensors) + self.i += self.batch_size + return batch + + def __len__(self): + return self.n_batches + +def prepare_fast_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + if D.X_num is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_cat[split]).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + while True: + yield from dataloader + +def prepare_fast_torch_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + return dataloader + +def round_columns(X_real, X_synth, columns): + for col in columns: + uniq = np.unique(X_real[:,col]) + dist = cdist(X_synth[:, col][:, np.newaxis].astype(float), uniq[:, np.newaxis].astype(float)) + X_synth[:, col] = uniq[dist.argmin(axis=1)] + return X_synth + +def concat_features(D : Dataset): + if D.X_num is None: + assert D.X_cat is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_cat.items()} + elif D.X_cat is None: + assert D.X_num is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_num.items()} + else: + X = { + part: pd.concat( + [ + pd.DataFrame(D.X_num[part], columns=range(D.n_num_features)), + pd.DataFrame( + D.X_cat[part], + columns=range(D.n_num_features, D.n_features), + ), + ], + axis=1, + ) + for part in D.y.keys() + } + + return X + +def concat_to_pd(X_num, X_cat, y): + if X_num is None: + return pd.concat([ + pd.DataFrame(X_cat, columns=list(range(X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + if X_cat is not None: + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(X_cat, columns=list(range(X_num.shape[1], X_num.shape[1] + X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + +def read_pure_data(path, split='train'): + y = np.load(os.path.join(path, f'y_{split}.npy'), allow_pickle=True) + X_num = None + X_cat = None + if os.path.exists(os.path.join(path, f'X_num_{split}.npy')): + X_num = np.load(os.path.join(path, f'X_num_{split}.npy'), allow_pickle=True) + if os.path.exists(os.path.join(path, f'X_cat_{split}.npy')): + X_cat = np.load(os.path.join(path, f'X_cat_{split}.npy'), allow_pickle=True) + + return X_num, X_cat, y + +def read_changed_val(path, val_size=0.2): + path = Path(path) + X_num_train, X_cat_train, y_train = read_pure_data(path, 'train') + X_num_val, X_cat_val, y_val = read_pure_data(path, 'val') + is_regression = load_json(path / 'info.json')['task_type'] == 'regression' + + y = np.concatenate([y_train, y_val], axis=0) + + ixs = np.arange(y.shape[0]) + if is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + y_train = y[train_ixs] + y_val = y[val_ixs] + + if X_num_train is not None: + X_num = np.concatenate([X_num_train, X_num_val], axis=0) + X_num_train = X_num[train_ixs] + X_num_val = X_num[val_ixs] + + if X_cat_train is not None: + X_cat = np.concatenate([X_cat_train, X_cat_val], axis=0) + X_cat_train = X_cat[train_ixs] + X_cat_val = X_cat[val_ixs] + + return X_num_train, X_cat_train, y_train, X_num_val, X_cat_val, y_val + +############# + +def load_dataset_info(dataset_dir_name: str) -> Dict[str, Any]: + path = Path("data/" + dataset_dir_name) + info = util.load_json(path / 'info.json') + info['size'] = info['train_size'] + info['val_size'] + info['test_size'] + info['n_features'] = info['n_num_features'] + info['n_cat_features'] + info['path'] = path + return info diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/deep.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/deep.py new file mode 100644 index 0000000000000000000000000000000000000000..aeed3e2ada4f9d0ee1a6f86b7e5d1a35d486149f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/deep.py @@ -0,0 +1,168 @@ +import statistics +from dataclasses import dataclass +from typing import Any, Callable, Literal, cast + +import rtdl +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim as optim +import zero +from torch import Tensor + +from .util import TaskType + + +def cos_sin(x: Tensor) -> Tensor: + return torch.cat([torch.cos(x), torch.sin(x)], -1) + + +@dataclass +class PeriodicOptions: + n: int # the output size is 2 * n + sigma: float + trainable: bool + initialization: Literal['log-linear', 'normal'] + + +class Periodic(nn.Module): + def __init__(self, n_features: int, options: PeriodicOptions) -> None: + super().__init__() + if options.initialization == 'log-linear': + coefficients = options.sigma ** (torch.arange(options.n) / options.n) + coefficients = coefficients[None].repeat(n_features, 1) + else: + assert options.initialization == 'normal' + coefficients = torch.normal(0.0, options.sigma, (n_features, options.n)) + if options.trainable: + self.coefficients = nn.Parameter(coefficients) # type: ignore[code] + else: + self.register_buffer('coefficients', coefficients) + + def forward(self, x: Tensor) -> Tensor: + assert x.ndim == 2 + return cos_sin(2 * torch.pi * self.coefficients[None] * x[..., None]) + + +def get_n_parameters(m: nn.Module): + return sum(x.numel() for x in m.parameters() if x.requires_grad) + + +def get_loss_fn(task_type: TaskType) -> Callable[..., Tensor]: + return ( + F.binary_cross_entropy_with_logits + if task_type == TaskType.BINCLASS + else F.cross_entropy + if task_type == TaskType.MULTICLASS + else F.mse_loss + ) + + +def default_zero_weight_decay_condition(module_name, module, parameter_name, parameter): + del module_name, parameter + return parameter_name.endswith('bias') or isinstance( + module, + ( + nn.BatchNorm1d, + nn.LayerNorm, + nn.InstanceNorm1d, + rtdl.CLSToken, + rtdl.NumericalFeatureTokenizer, + rtdl.CategoricalFeatureTokenizer, + Periodic, + ), + ) + + +def split_parameters_by_weight_decay( + model: nn.Module, zero_weight_decay_condition=default_zero_weight_decay_condition +) -> list[dict[str, Any]]: + parameters_info = {} + for module_name, module in model.named_modules(): + for parameter_name, parameter in module.named_parameters(): + full_parameter_name = ( + f'{module_name}.{parameter_name}' if module_name else parameter_name + ) + parameters_info.setdefault(full_parameter_name, ([], parameter))[0].append( + zero_weight_decay_condition( + module_name, module, parameter_name, parameter + ) + ) + params_with_wd = {'params': []} + params_without_wd = {'params': [], 'weight_decay': 0.0} + for full_parameter_name, (results, parameter) in parameters_info.items(): + (params_without_wd if any(results) else params_with_wd)['params'].append( + parameter + ) + return [params_with_wd, params_without_wd] + + +def make_optimizer( + config: dict[str, Any], + parameter_groups, +) -> optim.Optimizer: + if config['optimizer'] == 'FT-Transformer-default': + return optim.AdamW(parameter_groups, lr=1e-4, weight_decay=1e-5) + return getattr(optim, config['optimizer'])( + parameter_groups, + **{x: config[x] for x in ['lr', 'weight_decay', 'momentum'] if x in config}, + ) + + +def get_lr(optimizer: optim.Optimizer) -> float: + return next(iter(optimizer.param_groups))['lr'] + + +def is_oom_exception(err: RuntimeError) -> bool: + return any( + x in str(err) + for x in [ + 'CUDA out of memory', + 'CUBLAS_STATUS_ALLOC_FAILED', + 'CUDA error: out of memory', + ] + ) + + +def train_with_auto_virtual_batch( + optimizer, + loss_fn, + step, + batch, + chunk_size: int, +) -> tuple[Tensor, int]: + batch_size = len(batch) + random_state = zero.random.get_state() + loss = None + while chunk_size != 0: + try: + zero.random.set_state(random_state) + optimizer.zero_grad() + if batch_size <= chunk_size: + loss = loss_fn(*step(batch)) + loss.backward() + else: + loss = None + for chunk in zero.iter_batches(batch, chunk_size): + chunk_loss = loss_fn(*step(chunk)) + chunk_loss = chunk_loss * (len(chunk) / batch_size) + chunk_loss.backward() + if loss is None: + loss = chunk_loss.detach() + else: + loss += chunk_loss.detach() + except RuntimeError as err: + if not is_oom_exception(err): + raise + chunk_size //= 2 + else: + break + if not chunk_size: + raise RuntimeError('Not enough memory even for batch_size=1') + optimizer.step() + return cast(Tensor, loss), chunk_size + + +def process_epoch_losses(losses: list[Tensor]) -> tuple[list[float], float]: + losses_ = torch.stack(losses).tolist() + return losses_, statistics.mean(losses_) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/env.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/env.py new file mode 100644 index 0000000000000000000000000000000000000000..64be89d7d72c70e2ed9c7e0ecbbe682c14da3517 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/env.py @@ -0,0 +1,39 @@ +""" +Have not used in TabDDPM project. +""" + +import datetime +import os +import shutil +import typing as ty +from pathlib import Path + +PROJ = Path('tab-ddpm/').absolute().resolve() +EXP = PROJ / 'exp' +DATA = PROJ / 'data' + + +def get_path(path: ty.Union[str, Path]) -> Path: + if isinstance(path, str): + path = Path(path) + if not path.is_absolute(): + path = PROJ / path + return path.resolve() + + +def get_relative_path(path: ty.Union[str, Path]) -> Path: + return get_path(path).relative_to(PROJ) + + +def duplicate_path( + src: ty.Union[str, Path], alternative_project_dir: ty.Union[str, Path] +) -> None: + src = get_path(src) + alternative_project_dir = get_path(alternative_project_dir) + dst = alternative_project_dir / src.relative_to(PROJ) + dst.parent.mkdir(parents=True, exist_ok=True) + if dst.exists(): + dst = dst.with_name( + dst.name + '_' + datetime.datetime.now().strftime('%Y%m%dT%H%M%S') + ) + (shutil.copytree if src.is_dir() else shutil.copyfile)(src, dst) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/metrics.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/metrics.py new file mode 100644 index 0000000000000000000000000000000000000000..bdcac8171208065da730e974024aae0dc32b4665 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/metrics.py @@ -0,0 +1,158 @@ +import enum +from typing import Any, Optional, Tuple, Dict, Union, cast +from functools import partial + +import numpy as np +import scipy.special +import sklearn.metrics as skm + +from . import util +from .util import TaskType + + +class PredictionType(enum.Enum): + LOGITS = 'logits' + PROBS = 'probs' + +class MetricsReport: + def __init__(self, report: dict, task_type: TaskType): + self._res = {k: {} for k in report.keys()} + if task_type in (TaskType.BINCLASS, TaskType.MULTICLASS): + self._metrics_names = ["acc", "f1"] + for k in report.keys(): + self._res[k]["acc"] = report[k]["accuracy"] + self._res[k]["f1"] = report[k]["macro avg"]["f1-score"] + if task_type == TaskType.BINCLASS: + self._res[k]["roc_auc"] = report[k]["roc_auc"] + self._metrics_names.append("roc_auc") + + elif task_type == TaskType.REGRESSION: + self._metrics_names = ["r2", "rmse"] + for k in report.keys(): + self._res[k]["r2"] = report[k]["r2"] + self._res[k]["rmse"] = report[k]["rmse"] + else: + raise "Unknown TaskType!" + + def get_splits_names(self) -> list[str]: + return self._res.keys() + + def get_metrics_names(self) -> list[str]: + return self._metrics_names + + def get_metric(self, split: str, metric: str) -> float: + return self._res[split][metric] + + def get_val_score(self) -> float: + return self._res["val"]["r2"] if "r2" in self._res["val"] else self._res["val"]["f1"] + + def get_test_score(self) -> float: + return self._res["test"]["r2"] if "r2" in self._res["test"] else self._res["test"]["f1"] + + def print_metrics(self) -> None: + res = { + "val": {k: np.around(self._res["val"][k], 4) for k in self._res["val"]}, + "test": {k: np.around(self._res["test"][k], 4) for k in self._res["test"]} + } + + print("*"*100) + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + + return res + +class SeedsMetricsReport: + def __init__(self): + self._reports = [] + + def add_report(self, report: MetricsReport) -> None: + self._reports.append(report) + + def get_mean_std(self) -> dict: + res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + res[split][metric] = [x.get_metric(split, metric) for x in self._reports] + + agg_res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + for k, f in [("count", len), ("mean", np.mean), ("std", np.std)]: + agg_res[split][f"{metric}-{k}"] = f(res[split][metric]) + self._res = res + self._agg_res = agg_res + + return agg_res + + def print_result(self) -> dict: + res = {split: {k: float(np.around(self._agg_res[split][k], 4)) for k in self._agg_res[split]} for split in ["val", "test"]} + print("="*100) + print("EVAL RESULTS:") + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + print("="*100) + return res + +def calculate_rmse( + y_true: np.ndarray, y_pred: np.ndarray, std: Optional[float] +) -> float: + rmse = skm.mean_squared_error(y_true, y_pred) ** 0.5 + if std is not None: + rmse *= std + return rmse + + +def _get_labels_and_probs( + y_pred: np.ndarray, task_type: TaskType, prediction_type: Optional[PredictionType] +) -> Tuple[np.ndarray, Optional[np.ndarray]]: + assert task_type in (TaskType.BINCLASS, TaskType.MULTICLASS) + + if prediction_type is None: + return y_pred, None + + if prediction_type == PredictionType.LOGITS: + probs = ( + scipy.special.expit(y_pred) + if task_type == TaskType.BINCLASS + else scipy.special.softmax(y_pred, axis=1) + ) + elif prediction_type == PredictionType.PROBS: + probs = y_pred + else: + util.raise_unknown('prediction_type', prediction_type) + + assert probs is not None + labels = np.round(probs) if task_type == TaskType.BINCLASS else probs.argmax(axis=1) + return labels.astype('int64'), probs + + +def calculate_metrics( + y_true: np.ndarray, + y_pred: np.ndarray, + task_type: Union[str, TaskType], + prediction_type: Optional[Union[str, PredictionType]], + y_info: Dict[str, Any], +) -> Dict[str, Any]: + # Example: calculate_metrics(y_true, y_pred, 'binclass', 'logits', {}) + task_type = TaskType(task_type) + if prediction_type is not None: + prediction_type = PredictionType(prediction_type) + + if task_type == TaskType.REGRESSION: + assert prediction_type is None + assert 'std' in y_info + rmse = calculate_rmse(y_true, y_pred, y_info['std']) + r2 = skm.r2_score(y_true, y_pred) + result = {'rmse': rmse, 'r2': r2} + else: + labels, probs = _get_labels_and_probs(y_pred, task_type, prediction_type) + result = cast( + Dict[str, Any], skm.classification_report(y_true, labels, output_dict=True) + ) + if task_type == TaskType.BINCLASS: + result['roc_auc'] = skm.roc_auc_score(y_true, probs) + return result diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/util.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/util.py new file mode 100644 index 0000000000000000000000000000000000000000..75e05c9c9d1f0f9d6687f6d5fe1e91cad1b4ea20 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/lib/util.py @@ -0,0 +1,433 @@ +import argparse +import atexit +import enum +import json +import os +import pickle +import shutil +import sys +import time +import uuid +from copy import deepcopy +from dataclasses import asdict, fields, is_dataclass +from pathlib import Path +from pprint import pprint +from typing import Any, Callable, List, Dict, Type, Optional, Tuple, TypeVar, Union, cast, get_args, get_origin + +import __main__ +import numpy as np +import tomli +import tomli_w +import torch +import zero + +from . import env + +RawConfig = Dict[str, Any] +Report = Dict[str, Any] +T = TypeVar('T') + + +class Part(enum.Enum): + TRAIN = 'train' + VAL = 'val' + TEST = 'test' + + def __str__(self) -> str: + return self.value + + +class TaskType(enum.Enum): + BINCLASS = 'binclass' + MULTICLASS = 'multiclass' + REGRESSION = 'regression' + + def __str__(self) -> str: + return self.value + + +class Timer(zero.Timer): + @classmethod + def launch(cls) -> 'Timer': + timer = cls() + timer.run() + return timer + + +def update_training_log(training_log, data, metrics): + def _update(log_part, data_part): + for k, v in data_part.items(): + if isinstance(v, dict): + _update(log_part.setdefault(k, {}), v) + elif isinstance(v, list): + log_part.setdefault(k, []).extend(v) + else: + log_part.setdefault(k, []).append(v) + + _update(training_log, data) + transposed_metrics = {} + for part, part_metrics in metrics.items(): + for metric_name, value in part_metrics.items(): + transposed_metrics.setdefault(metric_name, {})[part] = value + _update(training_log, transposed_metrics) + + +def raise_unknown(unknown_what: str, unknown_value: Any): + raise ValueError(f'Unknown {unknown_what}: {unknown_value}') + + +def _replace(data, condition, value): + def do(x): + if isinstance(x, dict): + return {k: do(v) for k, v in x.items()} + elif isinstance(x, list): + return [do(y) for y in x] + else: + return value if condition(x) else x + + return do(data) + + +_CONFIG_NONE = '__none__' + + +def unpack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x == _CONFIG_NONE, None)) + return config + + +def pack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x is None, _CONFIG_NONE)) + return config + + +def load_config(path: Union[Path, str]) -> Any: + with open(path, 'rb') as f: + return unpack_config(tomli.load(f)) + + +def dump_config(config: Any, path: Union[Path, str]) -> None: + with open(path, 'wb') as f: + tomli_w.dump(pack_config(config), f) + # check that there are no bugs in all these "pack/unpack" things + assert config == load_config(path) + + +def load_json(path: Union[Path, str], **kwargs) -> Any: + return json.loads(Path(path).read_text(), **kwargs) + + +def dump_json(x: Any, path: Union[Path, str], **kwargs) -> None: + kwargs.setdefault('indent', 4) + Path(path).write_text(json.dumps(x, **kwargs) + '\n') + + +def load_pickle(path: Union[Path, str], **kwargs) -> Any: + return pickle.loads(Path(path).read_bytes(), **kwargs) + + +def dump_pickle(x: Any, path: Union[Path, str], **kwargs) -> None: + Path(path).write_bytes(pickle.dumps(x, **kwargs)) + + +def load(path: Union[Path, str], **kwargs) -> Any: + return globals()[f'load_{Path(path).suffix[1:]}'](Path(path), **kwargs) + + +def dump(x: Any, path: Union[Path, str], **kwargs) -> Any: + return globals()[f'dump_{Path(path).suffix[1:]}'](x, Path(path), **kwargs) + + +def _get_output_item_path( + path: Union[str, Path], filename: str, must_exist: bool +) -> Path: + path = env.get_path(path) + if path.suffix == '.toml': + path = path.with_suffix('') + if path.is_dir(): + path = path / filename + else: + assert path.name == filename + assert path.parent.exists() + if must_exist: + assert path.exists() + return path + + +def load_report(path: Path) -> Report: + return load_json(_get_output_item_path(path, 'report.json', True)) + + +def dump_report(report: dict, path: Path) -> None: + dump_json(report, _get_output_item_path(path, 'report.json', False)) + + +def load_predictions(path: Path) -> Dict[str, np.ndarray]: + with np.load(_get_output_item_path(path, 'predictions.npz', True)) as predictions: + return {x: predictions[x] for x in predictions} + + +def dump_predictions(predictions: Dict[str, np.ndarray], path: Path) -> None: + np.savez(_get_output_item_path(path, 'predictions.npz', False), **predictions) + + +def dump_metrics(metrics: Dict[str, Any], path: Path) -> None: + dump_json(metrics, _get_output_item_path(path, 'metrics.json', False)) + + +def load_checkpoint(path: Path, *args, **kwargs) -> Dict[str, np.ndarray]: + return torch.load( + _get_output_item_path(path, 'checkpoint.pt', True), *args, **kwargs + ) + + +def get_device() -> torch.device: + if torch.cuda.is_available(): + assert os.environ.get('CUDA_VISIBLE_DEVICES') is not None + return torch.device('cuda:0') + else: + return torch.device('cpu') + + +def _print_sep(c, size=100): + print(c * size) + + +def start( + config_cls: Type[T] = RawConfig, + argv: Optional[List[str]] = None, + patch_raw_config: Optional[Callable[[RawConfig], None]] = None, +) -> Tuple[T, Path, Report]: # config # output dir # report + parser = argparse.ArgumentParser() + parser.add_argument('config', metavar='FILE') + parser.add_argument('--force', action='store_true') + parser.add_argument('--continue', action='store_true', dest='continue_') + if argv is None: + program = __main__.__file__ + args = parser.parse_args() + else: + program = argv[0] + try: + args = parser.parse_args(argv[1:]) + except Exception: + print( + 'Failed to parse `argv`.' + ' Remember that the first item of `argv` must be the path (relative to' + ' the project root) to the script/notebook.' + ) + raise + args = parser.parse_args(argv) + + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if snapshot_dir and Path(snapshot_dir).joinpath('CHECKPOINTS_RESTORED').exists(): + assert args.continue_ + + config_path = env.get_path(args.config) + output_dir = config_path.with_suffix('') + _print_sep('=') + print(f'[output] {output_dir}') + _print_sep('=') + + assert config_path.exists() + raw_config = load_config(config_path) + if patch_raw_config is not None: + patch_raw_config(raw_config) + if is_dataclass(config_cls): + config = from_dict(config_cls, raw_config) + full_raw_config = asdict(config) + else: + assert config_cls is dict + full_raw_config = config = raw_config + full_raw_config = asdict(config) + + if output_dir.exists(): + if args.force: + print('Removing the existing output and creating a new one...') + shutil.rmtree(output_dir) + output_dir.mkdir() + elif not args.continue_: + backup_output(output_dir) + print('The output directory already exists. Done!\n') + sys.exit() + elif output_dir.joinpath('DONE').exists(): + backup_output(output_dir) + print('The "DONE" file already exists. Done!') + sys.exit() + else: + print('Continuing with the existing output...') + else: + print('Creating the output...') + output_dir.mkdir() + + report = { + 'program': str(env.get_relative_path(program)), + 'environment': {}, + 'config': full_raw_config, + } + if torch.cuda.is_available(): # type: ignore[code] + report['environment'].update( + { + 'CUDA_VISIBLE_DEVICES': os.environ.get('CUDA_VISIBLE_DEVICES'), + 'gpus': zero.hardware.get_gpus_info(), + 'torch.version.cuda': torch.version.cuda, + 'torch.backends.cudnn.version()': torch.backends.cudnn.version(), # type: ignore[code] + 'torch.cuda.nccl.version()': torch.cuda.nccl.version(), # type: ignore[code] + } + ) + dump_report(report, output_dir) + dump_json(raw_config, output_dir / 'raw_config.json') + _print_sep('-') + pprint(full_raw_config, width=100) + _print_sep('-') + return cast(config_cls, config), output_dir, report + + +_LAST_SNAPSHOT_TIME = None + + +def backup_output(output_dir: Path) -> None: + backup_dir = os.environ.get('TMP_OUTPUT_PATH') + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if backup_dir is None: + assert snapshot_dir is None + return + assert snapshot_dir is not None + + try: + relative_output_dir = output_dir.relative_to(env.PROJ) + except ValueError: + return + + for dir_ in [backup_dir, snapshot_dir]: + new_output_dir = dir_ / relative_output_dir + prev_backup_output_dir = new_output_dir.with_name(new_output_dir.name + '_prev') + new_output_dir.parent.mkdir(exist_ok=True, parents=True) + if new_output_dir.exists(): + new_output_dir.rename(prev_backup_output_dir) + shutil.copytree(output_dir, new_output_dir) + # the case for evaluate.py which automatically creates configs + if output_dir.with_suffix('.toml').exists(): + shutil.copyfile( + output_dir.with_suffix('.toml'), new_output_dir.with_suffix('.toml') + ) + if prev_backup_output_dir.exists(): + shutil.rmtree(prev_backup_output_dir) + + global _LAST_SNAPSHOT_TIME + if _LAST_SNAPSHOT_TIME is None or time.time() - _LAST_SNAPSHOT_TIME > 10 * 60: + import nirvana_dl.snapshot # type: ignore[code] + + nirvana_dl.snapshot.dump_snapshot() + _LAST_SNAPSHOT_TIME = time.time() + print('The snapshot was saved!') + + +def _get_scores(metrics: Dict[str, Dict[str, Any]]) -> Optional[Dict[str, float]]: + return ( + {k: v['score'] for k, v in metrics.items()} + if 'score' in next(iter(metrics.values())) + else None + ) + + +def format_scores(metrics: Dict[str, Dict[str, Any]]) -> str: + return ' '.join( + f"[{x}] {metrics[x]['score']:.3f}" + for x in ['test', 'val', 'train'] + if x in metrics + ) + + +def finish(output_dir: Path, report: dict) -> None: + print() + _print_sep('=') + + metrics = report.get('metrics') + if metrics is not None: + scores = _get_scores(metrics) + if scores is not None: + dump_json(scores, output_dir / 'scores.json') + print(format_scores(metrics)) + _print_sep('-') + + dump_report(report, output_dir) + json_output_path = os.environ.get('JSON_OUTPUT_FILE') + if json_output_path: + try: + key = str(output_dir.relative_to(env.PROJ)) + except ValueError: + pass + else: + json_output_path = Path(json_output_path) + try: + json_data = json.loads(json_output_path.read_text()) + except (FileNotFoundError, json.decoder.JSONDecodeError): + json_data = {} + json_data[key] = load_json(output_dir / 'report.json') + json_output_path.write_text(json.dumps(json_data, indent=4)) + shutil.copyfile( + json_output_path, + os.path.join(os.environ['SNAPSHOT_PATH'], 'json_output.json'), + ) + + output_dir.joinpath('DONE').touch() + backup_output(output_dir) + print(f'Done! | {report.get("time")} | {output_dir}') + _print_sep('=') + print() + + +def from_dict(datacls: Type[T], data: dict) -> T: + assert is_dataclass(datacls) + data = deepcopy(data) + for field in fields(datacls): + if field.name not in data: + continue + if is_dataclass(field.type): + data[field.name] = from_dict(field.type, data[field.name]) + elif ( + get_origin(field.type) is Union + and len(get_args(field.type)) == 2 + and get_args(field.type)[1] is type(None) + and is_dataclass(get_args(field.type)[0]) + ): + if data[field.name] is not None: + data[field.name] = from_dict(get_args(field.type)[0], data[field.name]) + return datacls(**data) + + +def replace_factor_with_value( + config: RawConfig, + key: str, + reference_value: int, + bounds: Tuple[float, float], +) -> None: + factor_key = key + '_factor' + if factor_key not in config: + assert key in config + else: + assert key not in config + factor = config.pop(factor_key) + assert bounds[0] <= factor <= bounds[1] + config[key] = int(factor * reference_value) + + +def get_temporary_copy(path: Union[str, Path]) -> Path: + path = env.get_path(path) + assert not path.is_dir() and not path.is_symlink() + tmp_path = path.with_name( + path.stem + '___' + str(uuid.uuid4()).replace('-', '') + path.suffix + ) + shutil.copyfile(path, tmp_path) + atexit.register(lambda: tmp_path.unlink()) + return tmp_path + + +def get_python(): + python = Path('python3.9') + return str(python) if python.exists() else 'python' + +def get_catboost_config(real_data_path, is_cv=False): + ds_name = Path(real_data_path).name + C = load_json(f'tuned_models/catboost/{ds_name}_cv.json') + return C \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..0ce34ec62c2c3c306ad6b26213187ebdaedf8c60 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/requirements.txt @@ -0,0 +1,22 @@ +catboost==1.0.3 +category-encoders==2.3.0 +dython==0.5.1 +icecream==2.1.2 +libzero==0.0.8 +numpy==1.21.4 +optuna==2.10.1 +pandas==1.3.4 +pyarrow==6.0.0 +rtdl==0.0.9 +scikit-learn==1.0.2 +scipy==1.7.2 +skorch==0.11.0 +tomli-w==0.4.0 +tomli==1.2.2 +tqdm==4.62.3 + +# smote +imbalanced-learn==0.7.0 + +# tvae +rdt==0.6.4 \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_catboost.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_catboost.py new file mode 100644 index 0000000000000000000000000000000000000000..55066c2176c33c8fec14416d34736899e039a64f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_catboost.py @@ -0,0 +1,145 @@ +from catboost import CatBoostClassifier, CatBoostRegressor +from sklearn.metrics import classification_report, r2_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from pprint import pprint +from lib import concat_features, read_pure_data, get_catboost_config, read_changed_val + +def train_catboost( + parent_dir, + real_data_path, + eval_type, + T_dict, + seed = 0, + params = None, + change_val = True, + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + catboost_config = get_catboost_config(real_data_path, is_cv=True) + else: + catboost_config = params + + if 'cat_features' not in catboost_config: + catboost_config['cat_features'] = list(range(D.n_num_features, D.n_features)) + + for col in range(D.n_features): + for split in X.keys(): + if col in catboost_config['cat_features']: + X[split][col] = X[split][col].astype(str) + else: + X[split][col] = X[split][col].astype(float) + print(T_dict) + pprint(catboost_config, width=100) + print('-'*100) + + if D.is_regression: + model = CatBoostRegressor( + **catboost_config, + eval_metric='RMSE', + random_seed=seed + ) + predict = model.predict + else: + model = CatBoostClassifier( + loss_function="MultiClass" if D.is_multiclass else "Logloss", + **catboost_config, + eval_metric='TotalF1', + random_seed=seed, + class_names=[str(i) for i in range(D.n_classes)] if D.is_multiclass else ["0", "1"] + ) + predict = ( + model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit( + X['train'], D.y['train'], + eval_set=(X['val'], D.y['val']), + verbose=100 + ) + predictions = {k: predict(v) for k, v in X.items()} + print(predictions['train'].shape) + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_mlp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_mlp.py new file mode 100644 index 0000000000000000000000000000000000000000..396de4ef30589ff3c115b3bff7daa0bddeb9a57b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_mlp.py @@ -0,0 +1,176 @@ +from sklearn.metrics import classification_report, r2_score, f1_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from tab_ddpm.modules import MLP +from skorch.regressor import NeuralNetRegressor +from skorch.classifier import NeuralNetClassifier +from skorch.dataset import Dataset as SkDataset +from skorch.callbacks import EarlyStopping, EpochScoring +from skorch.helper import predefined_split +from torch.optim import AdamW +from torch.nn import MSELoss, BCEWithLogitsLoss, CrossEntropyLoss + +def train_mlp( + parent_dir, + real_data_path, + eval_type, + T_dict, + params = None, + change_val = False, + seed = 0, + device = "cuda:0" +): + zero.improve_reproducibility(seed) + synthetic_data_path = os.path.join(parent_dir) if parent_dir is not None else None + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = lib.read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(synthetic_data_path) + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print('loading synthetic data...') + X_num, X_cat, y = lib.read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = lib.read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = lib.read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = lib.read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = lib.concat_features(D) + + X["train"], D.y["train"] = shuffle(X["train"], D.y["train"], random_state=seed) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + params = lib.load_json(f"tuned_models/mlp/{Path(real_data_path).name}_cv.json") + + mlp_params = {} + if params is not None: + mlp_params["d_layers"] = params["d_layers"] + mlp_params["dropout"] = params["dropout"] + # mlp_params["n_blocks"] = params["n_blocks"] + # mlp_params["d_main"] = params["d_main"] + # mlp_params["d_hidden"] = params["d_hidden"] + # mlp_params["dropout_first"] = params["dropout_first"] + # mlp_params["dropout_second"] = params["dropout_second"] + mlp_params["d_in"] = X["train"].shape[1] + mlp_params["d_out"] = D.nn_output_dim + + model = MLP.make_baseline(**mlp_params) + + if D.is_regression: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + elif D.is_binclass: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + else: + y = {k: D.y[k].astype(np.int64) for k in D.y} + + train_ds = SkDataset(X = X["train"].to_numpy(), y = y["train"]) + val_ds = SkDataset(X = X["val"].to_numpy(), y = y["val"]) + es = EarlyStopping(monitor="valid_loss", patience=16) + + print('-'*100) + + def f1(net, X, y): + y_pred = net.predict(X) + return f1_score(y, y_pred, average="macro") + + def r2(net, X, y): + y_pred = net.predict(X) + return r2_score(y, y_pred) + + if D.is_regression: + net = NeuralNetRegressor( + model, + criterion=MSELoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(r2, lower_is_better=False)], + ) + + else: + net = NeuralNetClassifier( + model, + criterion=BCEWithLogitsLoss if D.is_binclass else CrossEntropyLoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(f1, lower_is_better=False)], + ) + + net.fit( + X=train_ds.X, + y=train_ds.y + ) + + print("LAST:", len(net.history)) + + predictions = {k: net.predict_proba(v.to_numpy())[:, 1] if D.is_binclass else + net.predict_proba(v.to_numpy()) if D.is_multiclass else + net.predict(v.to_numpy()) + for k, v in X.items() + } + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_mlp.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds.py new file mode 100644 index 0000000000000000000000000000000000000000..cc4970e2a7293234d9d08afba2798719499bfc75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds.py @@ -0,0 +1,121 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import shutil +from pathlib import Path +from copy import deepcopy +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabgan.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="catboost", + n_datasets=1, + dump=True, + change_val=False +): + + metrics_seeds_report = lib.SeedsMetricsReport() + parent_dir = Path(raw_config["parent_dir"]) + + if eval_type == 'real': + n_datasets = 1 + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real' and n_datasets > 1: + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + T_dict = deepcopy(raw_config['eval']['T']) + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + if model_type == "catboost": + T_dict["normalization"] = None + T_dict["cat_encoding"] = None + metric_report = train_catboost( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + elif model_type == "mlp": + T_dict["normalization"] = "quantile" + T_dict["cat_encoding"] = "one-hot" + metric_report = train_mlp( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report.add_report(metric_report) + + metrics_seeds_report.get_mean_std() + res = metrics_seeds_report.print_result() + if os.path.exists(parent_dir/ f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..187c88d31abc73efd4744bc1aa37bcc21d8c117f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_seeds_simple.py @@ -0,0 +1,130 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import pandas as pd +import numpy as np +from pathlib import Path +from eval_simple import train_simple +from copy import deepcopy +import shutil + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabganp.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="simple", + n_datasets=1, + dump=True, + change_val=False +): + parent_dir = Path(raw_config["parent_dir"]) + models = ["tree", "lr", "rf", "mlp"] + metrics_seeds_report = { + k: lib.SeedsMetricsReport() for k in models + } + + if eval_type == 'real': + n_datasets = 1 + + T_dict = deepcopy(raw_config['eval']['T']) + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real': + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + for model in models: + metric_report = train_simple( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + model_name=model, + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report[model].add_report(metric_report) + for k in models: + metrics_seeds_report[k].get_mean_std() + res = { + k: metrics_seeds_report[k].print_result() for k in models + } + + m1, m2 = ("r2-mean", "rmse-mean") if "r2-mean" in res["tree"]["val"] else ("f1-mean", "acc-mean") + res["avg"] = { + "val": { + m1: np.around(np.mean([res[k]["val"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["val"][m2] for k in models]), 4) + }, + "test": { + m1: np.around(np.mean([res[k]["test"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["test"][m2] for k in models]), 4) + }, + } + + if os.path.exists(parent_dir / f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..5e58199394b29839052de5abde1194530150abf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/eval_simple.py @@ -0,0 +1,141 @@ +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from lib import concat_features, read_pure_data, read_changed_val +from sklearn.utils import shuffle +import lib +from sklearn.tree import DecisionTreeClassifier, DecisionTreeRegressor +from sklearn.ensemble import RandomForestClassifier, RandomForestRegressor +from sklearn.linear_model import LogisticRegression, Ridge +from sklearn.neural_network import MLPClassifier, MLPRegressor + +def train_simple( + parent_dir, + real_data_path, + eval_type, + T_dict, + model_name = "tree", + seed = 0, + change_val = True, + params = None, # dummy + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + T = lib.Transformations(**T_dict) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + # ixs = np.random.choice(len(D.y["train"]), min(info["train_size"], len(D.y["train"])), replace=False) + # X["train"] = X["train"].iloc[ixs] + # D.y["train"] = D.y["train"][ixs] + + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + print(T_dict) + print('-'*100) + + if D.is_regression: + models = { + "tree": DecisionTreeRegressor(max_depth=28, random_state=seed), + "rf": RandomForestRegressor(max_depth=28, random_state=seed), + "lr": Ridge(max_iter=500, random_state=seed), + "mlp": MLPRegressor(max_iter=100, random_state=seed) + } + else: + models = { + "tree": DecisionTreeClassifier(max_depth=28, random_state=seed), + "rf": RandomForestClassifier(max_depth=28, random_state=seed), + "lr": LogisticRegression(max_iter=500, n_jobs=2, random_state=seed), + "mlp": MLPClassifier(max_iter=100, random_state=seed) + } + + model = models[model_name] + + predict = ( + model.predict + if D.is_regression + else model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit(X['train'], D.y['train']) + + predictions = {k: predict(v) for k, v in X.items()} + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + print(model.__class__.__name__) + metrics_report.print_metrics() + + # if parent_dir is not None: + # lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/pipeline.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/pipeline.py new file mode 100644 index 0000000000000000000000000000000000000000..64a297813fd582cb86438f00981939571b53c162 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/pipeline.py @@ -0,0 +1,112 @@ +import tomli +import shutil +import os +import argparse +from scripts.train import train +from scripts.sample import sample +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple +import pandas as pd +import matplotlib.pyplot as plt +import zero +import lib +import torch + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + if 'device' in raw_config: + device = torch.device(raw_config['device']) + else: + device = torch.device('cuda:1') + + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + + if args.train: + train( + **raw_config['train']['main'], + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + change_val=args.change_val + ) + if args.sample: + sample( + num_samples=raw_config['sample']['num_samples'], + batch_size=raw_config['sample']['batch_size'], + disbalance=raw_config['sample'].get('disbalance', None), + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_path=os.path.join(raw_config['parent_dir'], 'model.pt'), + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + seed=raw_config['sample'].get('seed', 0), + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + elif raw_config['eval']['type']['eval_model'] == 'mlp': + train_mlp( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val, + device=device + ) + elif raw_config['eval']['type']['eval_model'] == 'simple': + train_simple( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/resample_privacy.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/resample_privacy.py new file mode 100644 index 0000000000000000000000000000000000000000..54d320c3bb19ce5275d25704ad82f086601ee65d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/resample_privacy.py @@ -0,0 +1,257 @@ +""" +Adapted from https://github.com/Team-TUD/CTAB-GAN/tree/main/model/eval +""" + +import argparse +import lib +import os +import shutil +import zero +from sample import sample +from smote.sample_smote import sample_smote +from sklearn.preprocessing import MinMaxScaler, OneHotEncoder +from sklearn.metrics import pairwise_distances +from pathlib import Path +import tempfile +from eval_seeds import eval_seeds +import numpy as np +import subprocess +import warnings +import torch + +zero.improve_reproducibility(0) + +warnings.filterwarnings("ignore", category=FutureWarning) + + +def privacy_metrics(real_path,fake_path, data_percent=15): + + """ + Returns privacy metrics + + Inputs: + 1) real_path -> path to real data + 2) fake_path -> path to corresponding synthetic data + 3) data_percent -> percentage of data to be sampled from real and synthetic datasets for computing privacy metrics + Outputs: + 1) List containing the 5th percentile distance to closest record (DCR) between real and synthetic as well as within real and synthetic datasets + along with 5th percentile of nearest neighbour distance ratio (NNDR) between real and synthetic as well as within real and synthetic datasets + + """ + task_type = lib.load_json(real_path + "/info.json")["task_type"] + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_path, 'train') + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(fake_path, 'train') + + if task_type == 'regression': + X_num_real = np.concatenate([X_num_real, y_real[:, np.newaxis]], axis=1) + X_num_fake = np.concatenate([X_num_fake, y_fake[:, np.newaxis]], axis=1) + else: + if X_cat_fake is None: + X_cat_real = y_real[:, np.newaxis].astype(int).astype(str) + X_cat_fake = y_fake[:, np.newaxis].astype(int).astype(str) + else: + X_cat_real = np.concatenate([X_cat_real, y_real[:, np.newaxis].astype(int).astype(str)], axis=1) + X_cat_fake = np.concatenate([X_cat_fake, y_fake[:, np.newaxis].astype(int).astype(str)], axis=1) + + if len(y_real) > 50000: + ixs = np.random.choice(len(y_real), 50000, replace=False) + X_num_real = X_num_real[ixs] + X_cat_real = X_cat_real[ixs] if X_cat_real is not None else None + + if len(y_fake) > 50000: + ixs = np.random.choice(len(y_fake), 50000, replace=False) + X_num_fake = X_num_fake[ixs] + X_cat_fake = X_cat_fake[ixs] if X_cat_fake is not None else None + + + mm = MinMaxScaler().fit(X_num_real) + X_real = mm.transform(X_num_real) + X_fake = mm.transform(X_num_fake) + if X_cat_real is not None: + ohe = OneHotEncoder().fit(X_cat_real) + X_cat_real = ohe.transform(X_cat_real) / np.sqrt(2) + X_cat_fake = ohe.transform(X_cat_fake) / np.sqrt(2) + + X_real = np.concatenate([X_real, X_cat_real.todense()], axis=1) + X_fake = np.concatenate([X_fake, X_cat_fake.todense()], axis=1) + + # X_real = np.unique(X_real, axis=0) + # X_fake = np.unique(X_fake, axis=0) + + # Computing pair-wise distances between real and synthetic + dist_rf = pairwise_distances(X_fake, Y=X_real, metric='l2', n_jobs=-1) + # Computing pair-wise distances within real + # dist_rr = pairwise_distances(X_real, Y=None, metric='l2', n_jobs=-1) + # Computing pair-wise distances within synthetic + # dist_ff = pairwise_distances(X_fake, Y=None, metric='l2', n_jobs=-1) + + + # Removes distances of data points to themselves to avoid 0s within real and synthetic + # rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + # rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + + # Computing first and second smallest nearest neighbour distances between real and synthetic + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + # Computing first and second smallest nearest neighbour distances within real + # smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + # smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + # Computing first and second smallest nearest neighbour distances within synthetic + # smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + # smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + + + # Computing 5th percentiles for DCR and NNDR between and within real and synthetic datasets + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + # min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + # fifth_perc_rr = np.percentile(min_dist_rr,5) + # min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + # fifth_perc_ff = np.percentile(min_dist_ff,5) + # nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + # nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + # nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + # nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + # nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + # nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + + # return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) + return min_dist_rf # , min_dist_rr + +def sample_wrapper(method, config, num_samples=None, seed=0): + if method == "ddpm": + sample( + num_samples=num_samples, + batch_size=config['sample']['batch_size'], + disbalance=config['sample'].get('disbalance', None), + **config['diffusion_params'], + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + model_path=os.path.join(config['parent_dir'], 'model.pt'), + model_type=config['model_type'], + model_params=config['model_params'], + T_dict=config['train']['T'], + num_numerical_features=config['num_numerical_features'], + seed=seed, + change_val=False, + device=torch.device(config["device"]) + ) + elif method == "smote": + sample_smote( + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + **config['smote_params'], + seed=seed, + change_val=False + ) + +def resample_privacy(config_path, method, q): + with tempfile.TemporaryDirectory() as dir_: + config = lib.load_config(config_path) + if method == "ddpm": + shutil.copy2(os.path.join(config['parent_dir'], 'model.pt'), os.path.join(dir_, 'model.pt')) + config["parent_dir"] = str(dir_) + parent_dir = config["parent_dir"] + + sample_wrapper(method, config, num_samples=config["sample"].get("num_samples", 0)) + + dists = privacy_metrics(config["real_data_path"], parent_dir) + old_privacy = np.median(dists) + + q10 = np.quantile(dists, q=q) + print(f"Q: {q10}") + to_drop = np.where(dists < q10) + + X_num, X_cat, y = lib.read_pure_data(parent_dir) + num_samples = len(y) + X_num = np.delete(X_num, to_drop, axis=0) + X_cat = np.delete(X_cat, to_drop, axis=0) if X_cat is not None else None + y = np.delete(y, to_drop, axis=0) + i = 1 + + while len(y) < num_samples and i <= 10: + print(f"{len(y)}/{num_samples}") + + sample_wrapper(method, config, num_samples=config["sample"].get("batch_size", 0), seed=i) + + i += 1 + + X_num_t, X_cat_t, y_t = lib.read_pure_data(parent_dir) + dists = privacy_metrics(config["real_data_path"], parent_dir) + to_drop = np.where(dists < q10) + X_num_t = np.delete(X_num_t, to_drop, axis=0) + X_cat_t = np.delete(X_cat_t, to_drop, axis=0) if X_cat is not None else None + y_t = np.delete(y_t, to_drop, axis=0) + + X_num = np.concatenate([X_num, X_num_t], axis=0)[:num_samples] + X_cat = np.concatenate([X_cat, X_cat_t], axis=0)[:num_samples] if X_cat is not None else None + y = np.concatenate([y, y_t], axis=0)[:num_samples] + + # np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + # if X_cat is not None: + # np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + # np.save(os.path.join(parent_dir, 'y_train'), y) + + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if X_cat is not None: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y) + + new_dists = privacy_metrics(config["real_data_path"], parent_dir) + + res = eval_seeds( + config, + n_seeds=10, + eval_type="synthetic", + model_type="catboost", + n_datasets=1, + dump=False + ) + print(f"Old: {old_privacy:.4f}, New: {np.median(new_dists):.4f}") + + metric = "r2-mean" if "r2-mean" in res["test"] else "f1-mean" + return res["test"][metric], np.around(np.median(new_dists), 4) + +def resample_privacy_qs(config_path, method): + config = lib.load_config(config_path) + scores = [] + privacies = [] + + eval_res = lib.load_json(Path(config["parent_dir"]) / "eval_catboost.json")["synthetic"]["test"] + metric = "r2-mean" if "r2-mean" in eval_res else "f1-mean" + scores.append(eval_res[metric]) + privacies.append(np.median(privacy_metrics(config["real_data_path"], config["parent_dir"]))) + + for q in [0.1, 0.2, 0.3, 0.4]: + score, privacy = resample_privacy(config_path, method, q) + scores.append(score) + privacies.append(privacy) + + lib.dump_json( + {"scores": scores, "privacies": privacies}, + Path(config["parent_dir"]) / "privacies.json" + ) + +def calc_privacy(config_path, method, seed=0): + config = lib.load_config(config_path) + sample_wrapper(method, config, num_samples=config["sample"]["num_samples"], seed=seed) + timer = zero.Timer() + timer.run() + dists = privacy_metrics(config["real_data_path"], config["parent_dir"]) + privacy_val = np.median(dists) + lib.dump_json({"privacy": privacy_val}, os.path.join(config["parent_dir"], "privacy.json")) + print(f"Elapsed tine:{str(timer)}") + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('method', type=str) + args = parser.parse_args() + + calc_privacy( + args.config, + args.method + ) + +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/sample.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/sample.py new file mode 100644 index 0000000000000000000000000000000000000000..35d7f2158ba8c345bb57a840de1a7936ba59a0f6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/sample.py @@ -0,0 +1,160 @@ +import torch +import numpy as np +import zero +import os +from tab_ddpm.gaussian_multinomial_diffsuion import GaussianMultinomialDiffusion +from tab_ddpm.utils import FoundNANsError +from scripts.utils_train import get_model, make_dataset +from lib import round_columns +import lib + +def to_good_ohe(ohe, X): + indices = np.cumsum([0] + ohe._n_features_outs) + Xres = [] + for i in range(1, len(indices)): + x_ = np.max(X[:, indices[i - 1]:indices[i]], axis=1) + t = X[:, indices[i - 1]:indices[i]] - x_.reshape(-1, 1) + Xres.append(np.where(t >= 0, 1, 0)) + return np.hstack(Xres) + +def sample( + parent_dir, + real_data_path = 'data/higgs-small', + batch_size = 2000, + num_samples = 0, + model_type = 'mlp', + model_params = None, + model_path = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + disbalance = None, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + zero.improve_reproducibility(seed) + + T = lib.Transformations(**T_dict) + D = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(D.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + + num_numerical_features_ = D.X_num['train'].shape[1] if D.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features_ + model_params['d_in'] = int(d_in) + model = get_model( + model_type, + model_params, + num_numerical_features_, + category_sizes=D.get_category_sizes('train') + ) + + model.load_state_dict( + torch.load(model_path, map_location="cpu") + ) + + diffusion = GaussianMultinomialDiffusion( + K, + num_numerical_features=num_numerical_features_, + denoise_fn=model, num_timesteps=num_timesteps, + gaussian_loss_type=gaussian_loss_type, scheduler=scheduler, device=device + ) + + diffusion.to(device) + diffusion.eval() + + _, empirical_class_dist = torch.unique(torch.from_numpy(D.y['train']), return_counts=True) + # empirical_class_dist = empirical_class_dist.float() + torch.tensor([-5000., 10000.]).float() + if disbalance == 'fix': + empirical_class_dist[0], empirical_class_dist[1] = empirical_class_dist[1], empirical_class_dist[0] + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=False) + + elif disbalance == 'fill': + ix_major = empirical_class_dist.argmax().item() + val_major = empirical_class_dist[ix_major].item() + x_gen, y_gen = [], [] + for i in range(empirical_class_dist.shape[0]): + if i == ix_major: + continue + distrib = torch.zeros_like(empirical_class_dist) + distrib[i] = 1 + num_samples = val_major - empirical_class_dist[i].item() + x_temp, y_temp = diffusion.sample_all(num_samples, batch_size, distrib.float(), ddim=False) + x_gen.append(x_temp) + y_gen.append(y_temp) + + x_gen = torch.cat(x_gen, dim=0) + y_gen = torch.cat(y_gen, dim=0) + + else: + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=False) + + + # try: + # except FoundNANsError as ex: + # print("Found NaNs during sampling!") + # loader = lib.prepare_fast_dataloader(D, 'train', 8) + # x_gen = next(loader)[0] + # y_gen = torch.multinomial( + # empirical_class_dist.float(), + # num_samples=8, + # replacement=True + # ) + X_gen, y_gen = x_gen.numpy(), y_gen.numpy() + + ### + # X_num_unnorm = X_gen[:, :num_numerical_features] + # lo = np.percentile(X_num_unnorm, 2.5, axis=0) + # hi = np.percentile(X_num_unnorm, 97.5, axis=0) + # idx = (lo < X_num_unnorm) & (hi > X_num_unnorm) + # X_gen = X_gen[np.all(idx, axis=1)] + # y_gen = y_gen[np.all(idx, axis=1)] + ### + + num_numerical_features = num_numerical_features + int(D.is_regression and not model_params["is_y_cond"]) + + X_num_ = X_gen + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_unnorm'), X_gen[:, num_numerical_features:]) + # _, _, cat_encoder = lib.cat_encode({'train': X_cat_real}, T_dict['cat_encoding'], y_real, T_dict['seed'], True) + if T_dict['cat_encoding'] == 'one-hot': + X_gen[:, num_numerical_features:] = to_good_ohe(D.cat_transform.steps[0][1], X_num_[:, num_numerical_features:]) + X_cat = D.cat_transform.inverse_transform(X_gen[:, num_numerical_features:]) + + if num_numerical_features_ != 0: + # _, normalize = lib.normalize({'train' : X_num_real}, T_dict['normalization'], T_dict['seed'], True) + np.save(os.path.join(parent_dir, 'X_num_unnorm'), X_gen[:, :num_numerical_features]) + X_num_ = D.num_transform.inverse_transform(X_gen[:, :num_numerical_features]) + X_num = X_num_[:, :num_numerical_features] + + X_num_real = np.load(os.path.join(real_data_path, "X_num_train.npy"), allow_pickle=True) + disc_cols = [] + for col in range(X_num_real.shape[1]): + uniq_vals = np.unique(X_num_real[:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + print("Discrete cols:", disc_cols) + # 仅当 regression 且 y 在 X_num 中(非 is_y_cond)时才提取 y;否则 y_gen 已由 sample_all 返回 + if model_params['num_classes'] == 0 and not model_params.get('is_y_cond', True): + y_gen = X_num[:, 0] + X_num = X_num[:, 1:] + if len(disc_cols): + X_num = round_columns(X_num_real, X_num, disc_cols) + + if num_numerical_features != 0: + print("Num shape: ", X_num.shape) + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y_gen) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/train.py new file mode 100644 index 0000000000000000000000000000000000000000..84a4eef3c97b080d1cf1b122c7d4117b74a1cefd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/train.py @@ -0,0 +1,158 @@ +from copy import deepcopy +import torch +import os +import numpy as np +import zero +from tab_ddpm import GaussianMultinomialDiffusion +from scripts.utils_train import get_model, make_dataset, update_ema +import lib +import pandas as pd + +class Trainer: + def __init__(self, diffusion, train_iter, lr, weight_decay, steps, device=torch.device('cuda:1')): + self.diffusion = diffusion + self.ema_model = deepcopy(self.diffusion._denoise_fn) + for param in self.ema_model.parameters(): + param.detach_() + + self.train_iter = train_iter + self.steps = steps + self.init_lr = lr + self.optimizer = torch.optim.AdamW(self.diffusion.parameters(), lr=lr, weight_decay=weight_decay) + self.device = device + self.loss_history = pd.DataFrame(columns=['step', 'mloss', 'gloss', 'loss']) + self.log_every = 100 + self.print_every = 500 + self.ema_every = 1000 + + def _anneal_lr(self, step): + frac_done = step / self.steps + lr = self.init_lr * (1 - frac_done) + for param_group in self.optimizer.param_groups: + param_group["lr"] = lr + + def _run_step(self, x, out_dict): + x = x.to(self.device) + for k in out_dict: + out_dict[k] = out_dict[k].long().to(self.device) + self.optimizer.zero_grad() + loss_multi, loss_gauss = self.diffusion.mixed_loss(x, out_dict) + loss = loss_multi + loss_gauss + loss.backward() + self.optimizer.step() + + return loss_multi, loss_gauss + + def run_loop(self): + step = 0 + curr_loss_multi = 0.0 + curr_loss_gauss = 0.0 + + curr_count = 0 + while step < self.steps: + x, out_dict = next(self.train_iter) + out_dict = {'y': out_dict} + batch_loss_multi, batch_loss_gauss = self._run_step(x, out_dict) + + self._anneal_lr(step) + + curr_count += len(x) + curr_loss_multi += batch_loss_multi.item() * len(x) + curr_loss_gauss += batch_loss_gauss.item() * len(x) + + if (step + 1) % self.log_every == 0: + mloss = np.around(curr_loss_multi / curr_count, 4) + gloss = np.around(curr_loss_gauss / curr_count, 4) + if (step + 1) % self.print_every == 0: + print(f'Step {(step + 1)}/{self.steps} MLoss: {mloss} GLoss: {gloss} Sum: {mloss + gloss}') + self.loss_history.loc[len(self.loss_history)] =[step + 1, mloss, gloss, mloss + gloss] + curr_count = 0 + curr_loss_gauss = 0.0 + curr_loss_multi = 0.0 + + update_ema(self.ema_model.parameters(), self.diffusion._denoise_fn.parameters()) + + step += 1 + +def train( + parent_dir, + real_data_path = 'data/higgs-small', + steps = 1000, + lr = 0.002, + weight_decay = 1e-4, + batch_size = 1024, + model_type = 'mlp', + model_params = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + real_data_path = os.path.normpath(real_data_path) + parent_dir = os.path.normpath(parent_dir) + + zero.improve_reproducibility(seed) + + T = lib.Transformations(**T_dict) + + dataset = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(dataset.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + print(K) + + num_numerical_features = dataset.X_num['train'].shape[1] if dataset.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features + model_params['d_in'] = d_in + print(d_in) + + print(model_params) + model = get_model( + model_type, + model_params, + num_numerical_features, + category_sizes=dataset.get_category_sizes('train') + ) + model.to(device) + + # train_loader = lib.prepare_beton_loader(dataset, split='train', batch_size=batch_size) + train_loader = lib.prepare_fast_dataloader(dataset, split='train', batch_size=batch_size) + + + + diffusion = GaussianMultinomialDiffusion( + num_classes=K, + num_numerical_features=num_numerical_features, + denoise_fn=model, + gaussian_loss_type=gaussian_loss_type, + num_timesteps=num_timesteps, + scheduler=scheduler, + device=device + ) + diffusion.to(device) + diffusion.train() + + trainer = Trainer( + diffusion, + train_loader, + lr=lr, + weight_decay=weight_decay, + steps=steps, + device=device + ) + trainer.run_loop() + + trainer.loss_history.to_csv(os.path.join(parent_dir, 'loss.csv'), index=False) + torch.save(diffusion._denoise_fn.state_dict(), os.path.join(parent_dir, 'model.pt')) + torch.save(trainer.ema_model.state_dict(), os.path.join(parent_dir, 'model_ema.pt')) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_ddpm.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_ddpm.py new file mode 100644 index 0000000000000000000000000000000000000000..5a95dc23cab775a9ca7b7eb496bcefef58691dce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_ddpm.py @@ -0,0 +1,127 @@ +import subprocess +import lib +import os +import optuna +from copy import deepcopy +import shutil +import argparse +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('eval_model', type=str) +parser.add_argument('prefix', type=str) +parser.add_argument('--eval_seeds', action='store_true', default=False) + +args = parser.parse_args() +train_size = args.train_size +ds_name = args.ds_name +eval_type = args.eval_type +assert eval_type in ('merged', 'synthetic') +prefix = str(args.prefix) + +pipeline = f'scripts/pipeline.py' +base_config_path = f'exp/{ds_name}/config.toml' +parent_path = Path(f'exp/{ds_name}/') +exps_path = Path(f'exp/{ds_name}/many-exps/') # temporary dir. maybe will be replaced with tempdiвdr +eval_seeds = f'scripts/eval_seeds.py' + +os.makedirs(exps_path, exist_ok=True) + +def _suggest_mlp_layers(trial): + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 7, 10 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + return d_layers + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + d_layers = _suggest_mlp_layers(trial) + weight_decay = 0.0 + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [500]) # for debug + gaussian_loss_type = 'mse' + # scheduler = trial.suggest_categorical('scheduler', ['cosine', 'linear']) + num_timesteps = trial.suggest_categorical('num_timesteps', [100, 1000]) + num_samples = int(train_size * (2 ** trial.suggest_int('num_samples', -2, 1))) + + base_config = lib.load_config(base_config_path) + + base_config['train']['main']['lr'] = lr + base_config['train']['main']['steps'] = steps + base_config['train']['main']['batch_size'] = batch_size + base_config['train']['main']['weight_decay'] = weight_decay + base_config['model_params']['rtdl_params']['d_layers'] = d_layers + base_config['eval']['type']['eval_type'] = eval_type + base_config['sample']['num_samples'] = num_samples + base_config['diffusion_params']['gaussian_loss_type'] = gaussian_loss_type + base_config['diffusion_params']['num_timesteps'] = num_timesteps + # base_config['diffusion_params']['scheduler'] = scheduler + + base_config['parent_dir'] = str(exps_path / f"{trial.number}") + base_config['eval']['type']['eval_model'] = args.eval_model + if args.eval_model == "mlp": + base_config['eval']['T']['normalization'] = "quantile" + base_config['eval']['T']['cat_encoding'] = "one-hot" + + trial.set_user_attr("config", base_config) + + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--train', '--change_val'], check=True) + + n_datasets = 5 + score = 0.0 + + for sample_seed in range(n_datasets): + base_config['sample']['seed'] = sample_seed + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--sample', '--eval', '--change_val'], check=True) + + report_path = str(Path(base_config['parent_dir']) / f'results_{args.eval_model}.json') + report = lib.load_json(report_path) + + if 'r2' in report['metrics']['val']: + score += report['metrics']['val']['r2'] + else: + score += report['metrics']['val']['macro avg']['f1-score'] + + shutil.rmtree(exps_path / f"{trial.number}") + + return score / n_datasets + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +best_config_path = parent_path / f'{prefix}_best/config.toml' +best_config = study.best_trial.user_attrs['config'] +best_config["parent_dir"] = str(parent_path / f'{prefix}_best/') + +os.makedirs(parent_path / f'{prefix}_best', exist_ok=True) +lib.dump_config(best_config, best_config_path) +lib.dump_json(optuna.importance.get_param_importances(study), parent_path / f'{prefix}_best/importance.json') + +subprocess.run(['python3.9', f'{pipeline}', '--config', f'{best_config_path}', '--train', '--sample'], check=True) + +if args.eval_seeds: + best_exp = str(parent_path / f'{prefix}_best/config.toml') + subprocess.run(['python3.9', f'{eval_seeds}', '--config', f'{best_exp}', '10', "ddpm", eval_type, args.eval_model, '5'], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_evaluation_model.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_evaluation_model.py new file mode 100644 index 0000000000000000000000000000000000000000..8def5fd6cd1f609893e4de5f5c9708edb0a2efb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/tune_evaluation_model.py @@ -0,0 +1,145 @@ +import optuna +import lib +import argparse +from eval_catboost import train_catboost +from eval_mlp import train_mlp +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('model', type=str) +parser.add_argument('tune_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +data_path = Path(f"data/{args.ds_name}") +best_params = None + +assert args.tune_type in ("cv", "val") + +def _suggest(trial: optuna.trial.Trial, distribution: str, label: str, *args): + return getattr(trial, f'suggest_{distribution}')(label, *args) + +def _suggest_optional(trial: optuna.trial.Trial, distribution: str, label: str, *args): + if trial.suggest_categorical(f"optional_{label}", [True, False]): + return _suggest(trial, distribution, label, *args) + else: + return 0.0 + +def _suggest_mlp_layers(trial: optuna.trial.Trial, mlp_d_layers: list[int]): + + min_n_layers, max_n_layers = mlp_d_layers[0], mlp_d_layers[1] + d_min, d_max = mlp_d_layers[2], mlp_d_layers[3] + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + + return d_layers + +def suggest_mlp_params(trial): + params = {} + params["lr"] = trial.suggest_loguniform("lr", 5e-5, 0.005) + params["dropout"] = _suggest_optional(trial, "uniform", "dropout", 0.0, 0.5) + params["weight_decay"] = _suggest_optional(trial, "loguniform", "weight_decay", 1e-6, 1e-2) + params["d_layers"] = _suggest_mlp_layers(trial, [1, 8, 6, 10]) + + return params + +def suggest_catboost_params(trial): + params = {} + params["learning_rate"] = trial.suggest_loguniform("learning_rate", 0.001, 1.0) + params["depth"] = trial.suggest_int("depth", 3, 10) + params["l2_leaf_reg"] = trial.suggest_uniform("l2_leaf_reg", 0.1, 10.0) + params["bagging_temperature"] = trial.suggest_uniform("bagging_temperature", 0.0, 1.0) + params["leaf_estimation_iterations"] = trial.suggest_int("leaf_estimation_iterations", 1, 10) + + params = params | { + "iterations": 2000, + "early_stopping_rounds": 50, + "od_pval": 0.001, + "task_type": "CPU", # "GPU", may affect performance + "thread_count": 4, + # "devices": "0", # for GPU + } + + return params + +def objective(trial): + if args.model == "mlp": + params = suggest_mlp_params(trial) + train_func = train_mlp + T_dict = { + "seed": 0, + "normalization": "quantile", + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": "one-hot", + "y_policy": "default" + } + else: + params = suggest_catboost_params(trial) + train_func = train_catboost + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + trial.set_user_attr("params", params) + if args.tune_type == "cv": + score = 0.0 + for fold in range(5): + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path / f"kfolds/{fold}", + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score += metrics_report.get_val_score() + score /= 5 + + elif args.tune_type == "val": + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path, + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score = metrics_report.get_val_score() + + return score + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=100, show_progress_bar=True) + +bets_params = study.best_trial.user_attrs['params'] + +best_params_path = f"tuned_models/{args.model}/{args.ds_name}_{args.tune_type}.json" + +lib.dump_json(bets_params, best_params_path) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/utils_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/utils_train.py new file mode 100644 index 0000000000000000000000000000000000000000..4132ca56fb8e063111f916f903ef4e99206486e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/scripts/utils_train.py @@ -0,0 +1,89 @@ +import numpy as np +import os +import lib +from tab_ddpm.modules import MLPDiffusion, ResNetDiffusion + +def get_model( + model_name, + model_params, + n_num_features, + category_sizes +): + print(model_name) + if model_name == 'mlp': + model = MLPDiffusion(**model_params) + elif model_name == 'resnet': + model = ResNetDiffusion(**model_params) + else: + raise "Unknown model!" + return model + +def update_ema(target_params, source_params, rate=0.999): + """ + Update target parameters to be closer to those of source parameters using + an exponential moving average. + :param target_params: the target parameter sequence. + :param source_params: the source parameter sequence. + :param rate: the EMA rate (closer to 1 means slower). + """ + for targ, src in zip(target_params, source_params): + targ.detach().mul_(rate).add_(src.detach(), alpha=1 - rate) + +def concat_y_to_X(X, y): + if X is None: + return y.reshape(-1, 1) + return np.concatenate([y.reshape(-1, 1), X], axis=1) + +def make_dataset( + data_path: str, + T: lib.Transformations, + num_classes: int, + is_y_cond: bool, + change_val: bool +): + # classification + if num_classes > 0: + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) or not is_y_cond else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if X_num is not None: + X_num[split] = X_num_t + if not is_y_cond: + X_cat_t = concat_y_to_X(X_cat_t, y_t) + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + else: + # regression + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) or not is_y_cond else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if not is_y_cond: + X_num_t = concat_y_to_X(X_num_t, y_t) + if X_num is not None: + X_num[split] = X_num_t + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + + info = lib.load_json(os.path.join(data_path, 'info.json')) + + D = lib.Dataset( + X_num, + X_cat, + y, + y_info={}, + task_type=lib.TaskType(info['task_type']), + n_classes=info.get('n_classes') + ) + + if change_val: + D = lib.change_val(D) + + return lib.transform_dataset(D, T, None) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/pipeline_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/pipeline_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..4a6775493e975104c268a2cd177f953ea9589d0a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/pipeline_smote.py @@ -0,0 +1,68 @@ +import tomli +import shutil +import os +import argparse +from sample_smote import sample_smote +from scripts.eval_catboost import train_catboost +# from scripts.eval_mlp import train_mlp +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + if args.sample: + sample_smote( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + **raw_config['smote_params'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/sample_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/sample_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..63674186c3f1524d57bb4882f0c3dd432147230f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/sample_smote.py @@ -0,0 +1,210 @@ +import os +import lib +import argparse +import numpy as np +from pathlib import Path +from typing import Union, Any +from imblearn.over_sampling import SMOTE, SMOTENC +from sklearn.model_selection import train_test_split +from sklearn.preprocessing import MinMaxScaler +from sklearn.utils import check_random_state + +class MySMOTE(SMOTE): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None, + ): + super().__init__( + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=lam1 + self.lam2=lam2 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +class MySMOTENC(SMOTENC): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + categorical_features, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None + ): + super().__init__( + categorical_features=categorical_features, + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=0.0 + self.lam2=1.0 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0, lam1=0.0, lam2=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +def save_data(X, y, path, n_cat_features=0): + if n_cat_features > 0: + X_num = X[:, :-n_cat_features] + X_cat = X[:, -n_cat_features:] + else: + X_num = X + X_cat = None + + + np.save(path / "X_num_train", X_num.astype(float), allow_pickle=True) + np.save(path / "y_train", y, allow_pickle=True) + if X_cat is not None: + np.save(path / "X_cat_train", X_cat, allow_pickle=True) + +def sample_smote( + parent_dir, + real_data_path, + eval_type = "synthetic", + k_neighbours = 5, + frac_samples = 1.0, + frac_lam_del = 0.0, + change_val = False, + save = True, + seed = 0 +): + lam1 = 0.0 + frac_lam_del / 2 + lam2 = 1.0 - frac_lam_del / 2 + + real_data_path = Path(real_data_path) + info = lib.load_json(real_data_path / 'info.json') + is_regression = info['task_type'] == 'regression' + + X_num = {} + X_cat = {} + y = {} + + if change_val: + X_num['train'], X_cat['train'], y['train'], X_num['val'], X_cat['val'], y['val'] = lib.read_changed_val(real_data_path) + else: + X_num['train'], X_cat['train'], y['train'] = lib.read_pure_data(real_data_path, 'train') + X_num['val'], X_cat['val'], y['val'] = lib.read_pure_data(real_data_path, 'val') + X_num['test'], X_cat['test'], y['test'] = lib.read_pure_data(real_data_path, 'test') + + + X = {k: X_num[k] for k in X_num.keys()} + + if is_regression: + X['train'] = np.concatenate([X["train"], y["train"].reshape(-1, 1)], axis=1, dtype=object) + y['train'] = np.where(y["train"] > np.median(y["train"]), 1, 0) + + n_num_features = X['train'].shape[1] + n_cat_features = X_cat['train'].shape[1] if X_cat['train'] is not None else 0 + cat_features = list(range(n_num_features, n_num_features+n_cat_features)) + print(cat_features) + + scaler = MinMaxScaler().fit(X["train"]) + X["train"] = scaler.transform(X["train"]).astype(object) + + if X_cat['train'] is not None: + for k in X_num.keys(): + X[k] = np.concatenate([X[k], X_cat[k]], axis=1, dtype=object) + + print("Before:", X['train'].shape) + + if eval_type != 'real': + strat = {k: int((1 + frac_samples) * np.sum(y['train'] == k)) for k in np.unique(y['train'])} + print(strat) + if n_cat_features > 0: + sm = MySMOTENC( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + categorical_features=cat_features, + sampling_strategy=strat + ) + else: + sm = MySMOTE( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + sampling_strategy=strat + ) + + X_res, y_res = sm.fit_resample(X['train'], y['train']) + if is_regression: + X_res[:, :X_num["train"].shape[1]+1] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]+1]) + y_res = X_res[:, X_num["train"].shape[1]] + X_res = np.delete(X_res, [X_num["train"].shape[1]], axis=1) + else: + X_res[:, :X_num["train"].shape[1]] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]]) + y_res = y_res.astype(int) + + if eval_type == "synthetic": + X_res = X_res[X['train'].shape[0]:] + y_res = y_res[X['train'].shape[0]:] + + disc_cols = [] + for col in range(X_num["train"].shape[1]): + uniq_vals = np.unique(X_num["train"][:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + if len(disc_cols): + X_res[:, :X_num["train"].shape[1]] = lib.round_columns(X_num["train"], X_res[:, :X_num["train"].shape[1]], disc_cols) + + if save: + save_data(X_res, y_res, Path(parent_dir), n_cat_features) + + X['train'] = X_res + y['train'] = y_res + + return X, y + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('data_path', type=str) + parser.add_argument('method', type=str) + + args = parser.parse_args() + + sample_smote(args.data_path, args.method, save=False) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/tune_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/tune_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..9c98e205150bd02fee9ce399280714101bd427c3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/smote/tune_smote.py @@ -0,0 +1,98 @@ +import optuna +import lib +from copy import deepcopy +import argparse +import tempfile +from pathlib import Path +import os +from scripts.eval_catboost import train_catboost +from sample_smote import sample_smote +import subprocess + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('eval_type', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type + +def objective(trial): + + k_neighbours = trial.suggest_int("k_neighbours", 5, 20) + frac_samples = 2 ** trial.suggest_int('frac_samples', -2, 3) + + # z = \lam*x + (1 - \lam)*y, \lam ~ U[frac_lam_del/2, 1-frac_lam_del/2] + frac_lam_del = trial.suggest_float("frac_lam_del", 0.0, 0.95, step=0.05) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + for seed in range(5): + sample_smote( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + frac_samples=frac_samples, + frac_lam_del=frac_lam_del, + k_neighbours=k_neighbours, + change_val=True, + seed=seed + ) + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + + return score / 5 + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=5, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/smote/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/smote/", + "real_data_path": real_data_path, + "seed": 0, + "smote_params": {}, + "sample": {"seed": 0}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +config["smote_params"] = study.best_params +config["smote_params"]["frac_samples"] = 2 ** config["smote_params"]["frac_samples"] + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "smote", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8ad340c806b61da5a372186d04f2e7ab88a74daa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/__init__.py @@ -0,0 +1,2 @@ +from .gaussian_multinomial_diffsuion import * # noqa +from .modules import * # noqa \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py new file mode 100644 index 0000000000000000000000000000000000000000..5e3cb1c3086b2fa5862552e91e648677bb673dd9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py @@ -0,0 +1,993 @@ +""" +Based on https://github.com/openai/guided-diffusion/blob/main/guided_diffusion +and https://github.com/ehoogeboom/multinomial_diffusion +""" + +import torch.nn.functional as F +import torch +import math + +import numpy as np +from .utils import * + +""" +Based in part on: https://github.com/lucidrains/denoising-diffusion-pytorch/blob/5989f4c77eafcdc6be0fb4739f0f277a6dd7f7d8/denoising_diffusion_pytorch/denoising_diffusion_pytorch.py#L281 +""" +eps = 1e-8 + +def get_named_beta_schedule(schedule_name, num_diffusion_timesteps): + """ + Get a pre-defined beta schedule for the given name. + The beta schedule library consists of beta schedules which remain similar + in the limit of num_diffusion_timesteps. + Beta schedules may be added, but should not be removed or changed once + they are committed to maintain backwards compatibility. + """ + if schedule_name == "linear": + # Linear schedule from Ho et al, extended to work for any number of + # diffusion steps. + scale = 1000 / num_diffusion_timesteps + beta_start = scale * 0.0001 + beta_end = scale * 0.02 + return np.linspace( + beta_start, beta_end, num_diffusion_timesteps, dtype=np.float64 + ) + elif schedule_name == "cosine": + return betas_for_alpha_bar( + num_diffusion_timesteps, + lambda t: math.cos((t + 0.008) / 1.008 * math.pi / 2) ** 2, + ) + else: + raise NotImplementedError(f"unknown beta schedule: {schedule_name}") + + +def betas_for_alpha_bar(num_diffusion_timesteps, alpha_bar, max_beta=0.999): + """ + Create a beta schedule that discretizes the given alpha_t_bar function, + which defines the cumulative product of (1-beta) over time from t = [0,1]. + :param num_diffusion_timesteps: the number of betas to produce. + :param alpha_bar: a lambda that takes an argument t from 0 to 1 and + produces the cumulative product of (1-beta) up to that + part of the diffusion process. + :param max_beta: the maximum beta to use; use values lower than 1 to + prevent singularities. + """ + betas = [] + for i in range(num_diffusion_timesteps): + t1 = i / num_diffusion_timesteps + t2 = (i + 1) / num_diffusion_timesteps + betas.append(min(1 - alpha_bar(t2) / alpha_bar(t1), max_beta)) + return np.array(betas) + +class GaussianMultinomialDiffusion(torch.nn.Module): + def __init__( + self, + num_classes: np.array, + num_numerical_features: int, + denoise_fn, + num_timesteps=1000, + gaussian_loss_type='mse', + gaussian_parametrization='eps', + multinomial_loss_type='vb_stochastic', + parametrization='x0', + scheduler='cosine', + device=torch.device('cpu') + ): + + super(GaussianMultinomialDiffusion, self).__init__() + assert multinomial_loss_type in ('vb_stochastic', 'vb_all') + assert parametrization in ('x0', 'direct') + + if multinomial_loss_type == 'vb_all': + print('Computing the loss using the bound on _all_ timesteps.' + ' This is expensive both in terms of memory and computation.') + + self.num_numerical_features = num_numerical_features + self.num_classes = num_classes # it as a vector [K1, K2, ..., Km] + self.num_classes_expanded = torch.from_numpy( + np.concatenate([num_classes[i].repeat(num_classes[i]) for i in range(len(num_classes))]) + ).to(device) + + self.slices_for_classes = [np.arange(self.num_classes[0])] + offsets = np.cumsum(self.num_classes) + for i in range(1, len(offsets)): + self.slices_for_classes.append(np.arange(offsets[i - 1], offsets[i])) + self.offsets = torch.from_numpy(np.append([0], offsets)).to(device) + + self._denoise_fn = denoise_fn + self.gaussian_loss_type = gaussian_loss_type + self.gaussian_parametrization = gaussian_parametrization + self.multinomial_loss_type = multinomial_loss_type + self.num_timesteps = num_timesteps + self.parametrization = parametrization + self.scheduler = scheduler + + alphas = 1. - get_named_beta_schedule(scheduler, num_timesteps) + alphas = torch.tensor(alphas.astype('float64')) + betas = 1. - alphas + + log_alpha = np.log(alphas) + log_cumprod_alpha = np.cumsum(log_alpha) + + log_1_min_alpha = log_1_min_a(log_alpha) + log_1_min_cumprod_alpha = log_1_min_a(log_cumprod_alpha) + + alphas_cumprod = np.cumprod(alphas, axis=0) + alphas_cumprod_prev = torch.tensor(np.append(1.0, alphas_cumprod[:-1])) + alphas_cumprod_next = torch.tensor(np.append(alphas_cumprod[1:], 0.0)) + sqrt_alphas_cumprod = np.sqrt(alphas_cumprod) + sqrt_one_minus_alphas_cumprod = np.sqrt(1.0 - alphas_cumprod) + sqrt_recip_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod) + sqrt_recipm1_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod - 1) + + # Gaussian diffusion + + self.posterior_variance = ( + betas * (1.0 - alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ) + self.posterior_log_variance_clipped = torch.from_numpy( + np.log(np.append(self.posterior_variance[1], self.posterior_variance[1:])) + ).float().to(device) + self.posterior_mean_coef1 = ( + betas * np.sqrt(alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ).float().to(device) + self.posterior_mean_coef2 = ( + (1.0 - alphas_cumprod_prev) + * np.sqrt(alphas.numpy()) + / (1.0 - alphas_cumprod) + ).float().to(device) + + assert log_add_exp(log_alpha, log_1_min_alpha).abs().sum().item() < 1.e-5 + assert log_add_exp(log_cumprod_alpha, log_1_min_cumprod_alpha).abs().sum().item() < 1e-5 + assert (np.cumsum(log_alpha) - log_cumprod_alpha).abs().sum().item() < 1.e-5 + + # Convert to float32 and register buffers. + self.register_buffer('alphas', alphas.float().to(device)) + self.register_buffer('log_alpha', log_alpha.float().to(device)) + self.register_buffer('log_1_min_alpha', log_1_min_alpha.float().to(device)) + self.register_buffer('log_1_min_cumprod_alpha', log_1_min_cumprod_alpha.float().to(device)) + self.register_buffer('log_cumprod_alpha', log_cumprod_alpha.float().to(device)) + self.register_buffer('alphas_cumprod', alphas_cumprod.float().to(device)) + self.register_buffer('alphas_cumprod_prev', alphas_cumprod_prev.float().to(device)) + self.register_buffer('alphas_cumprod_next', alphas_cumprod_next.float().to(device)) + self.register_buffer('sqrt_alphas_cumprod', sqrt_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_one_minus_alphas_cumprod', sqrt_one_minus_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recip_alphas_cumprod', sqrt_recip_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recipm1_alphas_cumprod', sqrt_recipm1_alphas_cumprod.float().to(device)) + + self.register_buffer('Lt_history', torch.zeros(num_timesteps)) + self.register_buffer('Lt_count', torch.zeros(num_timesteps)) + + # Gaussian part + def gaussian_q_mean_variance(self, x_start, t): + mean = ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + ) + variance = extract(1.0 - self.alphas_cumprod, t, x_start.shape) + log_variance = extract( + self.log_1_min_cumprod_alpha, t, x_start.shape + ) + return mean, variance, log_variance + + def gaussian_q_sample(self, x_start, t, noise=None): + if noise is None: + noise = torch.randn_like(x_start) + assert noise.shape == x_start.shape + return ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + + extract(self.sqrt_one_minus_alphas_cumprod, t, x_start.shape) + * noise + ) + + def gaussian_q_posterior_mean_variance(self, x_start, x_t, t): + assert x_start.shape == x_t.shape + posterior_mean = ( + extract(self.posterior_mean_coef1, t, x_t.shape) * x_start + + extract(self.posterior_mean_coef2, t, x_t.shape) * x_t + ) + posterior_variance = extract(self.posterior_variance, t, x_t.shape) + posterior_log_variance_clipped = extract( + self.posterior_log_variance_clipped, t, x_t.shape + ) + assert ( + posterior_mean.shape[0] + == posterior_variance.shape[0] + == posterior_log_variance_clipped.shape[0] + == x_start.shape[0] + ) + return posterior_mean, posterior_variance, posterior_log_variance_clipped + + def gaussian_p_mean_variance( + self, model_output, x, t, clip_denoised=False, denoised_fn=None, model_kwargs=None + ): + if model_kwargs is None: + model_kwargs = {} + + B, C = x.shape[:2] + assert t.shape == (B,) + + model_variance = torch.cat([self.posterior_variance[1].unsqueeze(0).to(x.device), (1. - self.alphas)[1:]], dim=0) + # model_variance = self.posterior_variance.to(x.device) + model_log_variance = torch.log(model_variance) + + model_variance = extract(model_variance, t, x.shape) + model_log_variance = extract(model_log_variance, t, x.shape) + + + if self.gaussian_parametrization == 'eps': + pred_xstart = self._predict_xstart_from_eps(x_t=x, t=t, eps=model_output) + elif self.gaussian_parametrization == 'x0': + pred_xstart = model_output + else: + raise NotImplementedError + + model_mean, _, _ = self.gaussian_q_posterior_mean_variance( + x_start=pred_xstart, x_t=x, t=t + ) + + assert ( + model_mean.shape == model_log_variance.shape == pred_xstart.shape == x.shape + ), f'{model_mean.shape}, {model_log_variance.shape}, {pred_xstart.shape}, {x.shape}' + + return { + "mean": model_mean, + "variance": model_variance, + "log_variance": model_log_variance, + "pred_xstart": pred_xstart, + } + + def _vb_terms_bpd( + self, model_output, x_start, x_t, t, clip_denoised=False, model_kwargs=None + ): + true_mean, _, true_log_variance_clipped = self.gaussian_q_posterior_mean_variance( + x_start=x_start, x_t=x_t, t=t + ) + out = self.gaussian_p_mean_variance( + model_output, x_t, t, clip_denoised=clip_denoised, model_kwargs=model_kwargs + ) + kl = normal_kl( + true_mean, true_log_variance_clipped, out["mean"], out["log_variance"] + ) + kl = mean_flat(kl) / np.log(2.0) + + decoder_nll = -discretized_gaussian_log_likelihood( + x_start, means=out["mean"], log_scales=0.5 * out["log_variance"] + ) + assert decoder_nll.shape == x_start.shape + decoder_nll = mean_flat(decoder_nll) / np.log(2.0) + + # At the first timestep return the decoder NLL, + # otherwise return KL(q(x_{t-1}|x_t,x_0) || p(x_{t-1}|x_t)) + output = torch.where((t == 0), decoder_nll, kl) + return {"output": output, "pred_xstart": out["pred_xstart"], "out_mean": out["mean"], "true_mean": true_mean} + + def _prior_gaussian(self, x_start): + """ + Get the prior KL term for the variational lower-bound, measured in + bits-per-dim. + + This term can't be optimized, as it only depends on the encoder. + + :param x_start: the [N x C x ...] tensor of inputs. + :return: a batch of [N] KL values (in bits), one per batch element. + """ + batch_size = x_start.shape[0] + t = torch.tensor([self.num_timesteps - 1] * batch_size, device=x_start.device) + qt_mean, _, qt_log_variance = self.gaussian_q_mean_variance(x_start, t) + kl_prior = normal_kl( + mean1=qt_mean, logvar1=qt_log_variance, mean2=0.0, logvar2=0.0 + ) + return mean_flat(kl_prior) / np.log(2.0) + + def _gaussian_loss(self, model_out, x_start, x_t, t, noise, model_kwargs=None): + if model_kwargs is None: + model_kwargs = {} + + terms = {} + if self.gaussian_loss_type == 'mse': + terms["loss"] = mean_flat((noise - model_out) ** 2) + elif self.gaussian_loss_type == 'kl': + terms["loss"] = self._vb_terms_bpd( + model_output=model_out, + x_start=x_start, + x_t=x_t, + t=t, + clip_denoised=False, + model_kwargs=model_kwargs, + )["output"] + + + return terms['loss'] + + def _predict_xstart_from_eps(self, x_t, t, eps): + assert x_t.shape == eps.shape + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) * eps + ) + + def _predict_eps_from_xstart(self, x_t, t, pred_xstart): + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - pred_xstart + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) + + def gaussian_p_sample( + self, + model_out, + x, + t, + clip_denoised=False, + denoised_fn=None, + model_kwargs=None, + ): + out = self.gaussian_p_mean_variance( + model_out, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=model_kwargs, + ) + noise = torch.randn_like(x) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + + sample = out["mean"] + nonzero_mask * torch.exp(0.5 * out["log_variance"]) * noise + return {"sample": sample, "pred_xstart": out["pred_xstart"]} + + # Multinomial part + + def multinomial_kl(self, log_prob1, log_prob2): + kl = (log_prob1.exp() * (log_prob1 - log_prob2)).sum(dim=1) + return kl + + def q_pred_one_timestep(self, log_x_t, t): + log_alpha_t = extract(self.log_alpha, t, log_x_t.shape) + log_1_min_alpha_t = extract(self.log_1_min_alpha, t, log_x_t.shape) + + # alpha_t * E[xt] + (1 - alpha_t) 1 / K + log_probs = log_add_exp( + log_x_t + log_alpha_t, + log_1_min_alpha_t - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def q_pred(self, log_x_start, t): + log_cumprod_alpha_t = extract(self.log_cumprod_alpha, t, log_x_start.shape) + log_1_min_cumprod_alpha = extract(self.log_1_min_cumprod_alpha, t, log_x_start.shape) + + log_probs = log_add_exp( + log_x_start + log_cumprod_alpha_t, + log_1_min_cumprod_alpha - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def predict_start(self, model_out, log_x_t, t, out_dict): + + # model_out = self._denoise_fn(x_t, t.to(x_t.device), **out_dict) + + assert model_out.size(0) == log_x_t.size(0) + assert model_out.size(1) == self.num_classes.sum(), f'{model_out.size()}' + + log_pred = torch.empty_like(model_out) + for ix in self.slices_for_classes: + log_pred[:, ix] = F.log_softmax(model_out[:, ix], dim=1) + return log_pred + + def q_posterior(self, log_x_start, log_x_t, t): + # q(xt-1 | xt, x0) = q(xt | xt-1, x0) * q(xt-1 | x0) / q(xt | x0) + # where q(xt | xt-1, x0) = q(xt | xt-1). + + # EV_log_qxt_x0 = self.q_pred(log_x_start, t) + + # print('sum exp', EV_log_qxt_x0.exp().sum(1).mean()) + # assert False + + # log_qxt_x0 = (log_x_t.exp() * EV_log_qxt_x0).sum(dim=1) + t_minus_1 = t - 1 + # Remove negative values, will not be used anyway for final decoder + t_minus_1 = torch.where(t_minus_1 < 0, torch.zeros_like(t_minus_1), t_minus_1) + log_EV_qxtmin_x0 = self.q_pred(log_x_start, t_minus_1) + + num_axes = (1,) * (len(log_x_start.size()) - 1) + t_broadcast = t.to(log_x_start.device).view(-1, *num_axes) * torch.ones_like(log_x_start) + log_EV_qxtmin_x0 = torch.where(t_broadcast == 0, log_x_start, log_EV_qxtmin_x0.to(torch.float32)) + + # unnormed_logprobs = log_EV_qxtmin_x0 + + # log q_pred_one_timestep(x_t, t) + # Note: _NOT_ x_tmin1, which is how the formula is typically used!!! + # Not very easy to see why this is true. But it is :) + unnormed_logprobs = log_EV_qxtmin_x0 + self.q_pred_one_timestep(log_x_t, t) + + log_EV_xtmin_given_xt_given_xstart = \ + unnormed_logprobs \ + - sliced_logsumexp(unnormed_logprobs, self.offsets) + + return log_EV_xtmin_given_xt_given_xstart + + def p_pred(self, model_out, log_x, t, out_dict): + if self.parametrization == 'x0': + log_x_recon = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + log_model_pred = self.q_posterior( + log_x_start=log_x_recon, log_x_t=log_x, t=t) + elif self.parametrization == 'direct': + log_model_pred = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + else: + raise ValueError + return log_model_pred + + @torch.no_grad() + def p_sample(self, model_out, log_x, t, out_dict): + model_log_prob = self.p_pred(model_out, log_x=log_x, t=t, out_dict=out_dict) + out = self.log_sample_categorical(model_log_prob) + return out + + @torch.no_grad() + def p_sample_loop(self, shape, out_dict): + device = self.log_alpha.device + + b = shape[0] + # start with random normal image. + img = torch.randn(shape, device=device) + + for i in reversed(range(1, self.num_timesteps)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long), out_dict) + return img + + @torch.no_grad() + def _sample(self, image_size, out_dict, batch_size = 16): + return self.p_sample_loop((batch_size, 3, image_size, image_size), out_dict) + + @torch.no_grad() + def interpolate(self, x1, x2, t = None, lam = 0.5): + b, *_, device = *x1.shape, x1.device + t = default(t, self.num_timesteps - 1) + + assert x1.shape == x2.shape + + t_batched = torch.stack([torch.tensor(t, device=device)] * b) + xt1, xt2 = map(lambda x: self.q_sample(x, t=t_batched), (x1, x2)) + + img = (1 - lam) * xt1 + lam * xt2 + for i in reversed(range(0, t)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long)) + + return img + + def log_sample_categorical(self, logits): + full_sample = [] + for i in range(len(self.num_classes)): + one_class_logits = logits[:, self.slices_for_classes[i]] + uniform = torch.rand_like(one_class_logits) + gumbel_noise = -torch.log(-torch.log(uniform + 1e-30) + 1e-30) + sample = (gumbel_noise + one_class_logits).argmax(dim=1) + full_sample.append(sample.unsqueeze(1)) + full_sample = torch.cat(full_sample, dim=1) + log_sample = index_to_log_onehot(full_sample, self.num_classes) + return log_sample + + def q_sample(self, log_x_start, t): + log_EV_qxt_x0 = self.q_pred(log_x_start, t) + + log_sample = self.log_sample_categorical(log_EV_qxt_x0) + + return log_sample + + def nll(self, log_x_start, out_dict): + b = log_x_start.size(0) + device = log_x_start.device + loss = 0 + for t in range(0, self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + + kl = self.compute_Lt( + log_x_start=log_x_start, + log_x_t=self.q_sample(log_x_start=log_x_start, t=t_array), + t=t_array, + out_dict=out_dict) + + loss += kl + + loss += self.kl_prior(log_x_start) + + return loss + + def kl_prior(self, log_x_start): + b = log_x_start.size(0) + device = log_x_start.device + ones = torch.ones(b, device=device).long() + + log_qxT_prob = self.q_pred(log_x_start, t=(self.num_timesteps - 1) * ones) + log_half_prob = -torch.log(self.num_classes_expanded * torch.ones_like(log_qxT_prob)) + + kl_prior = self.multinomial_kl(log_qxT_prob, log_half_prob) + return sum_except_batch(kl_prior) + + def compute_Lt(self, model_out, log_x_start, log_x_t, t, out_dict, detach_mean=False): + log_true_prob = self.q_posterior( + log_x_start=log_x_start, log_x_t=log_x_t, t=t) + log_model_prob = self.p_pred(model_out, log_x=log_x_t, t=t, out_dict=out_dict) + + if detach_mean: + log_model_prob = log_model_prob.detach() + + kl = self.multinomial_kl(log_true_prob, log_model_prob) + kl = sum_except_batch(kl) + + decoder_nll = -log_categorical(log_x_start, log_model_prob) + decoder_nll = sum_except_batch(decoder_nll) + + mask = (t == torch.zeros_like(t)).float() + loss = mask * decoder_nll + (1. - mask) * kl + + return loss + + def sample_time(self, b, device, method='uniform'): + if method == 'importance': + if not (self.Lt_count > 10).all(): + return self.sample_time(b, device, method='uniform') + + Lt_sqrt = torch.sqrt(self.Lt_history + 1e-10) + 0.0001 + Lt_sqrt[0] = Lt_sqrt[1] # Overwrite decoder term with L1. + pt_all = (Lt_sqrt / Lt_sqrt.sum()).to(device) + + t = torch.multinomial(pt_all, num_samples=b, replacement=True).to(device) + + pt = pt_all.gather(dim=0, index=t) + + return t, pt + + elif method == 'uniform': + t = torch.randint(0, self.num_timesteps, (b,), device=device).long() + + pt = torch.ones_like(t).float() / self.num_timesteps + return t, pt + else: + raise ValueError + + def _multinomial_loss(self, model_out, log_x_start, log_x_t, t, pt, out_dict): + + if self.multinomial_loss_type == 'vb_stochastic': + kl = self.compute_Lt( + model_out, log_x_start, log_x_t, t, out_dict + ) + kl_prior = self.kl_prior(log_x_start) + # Upweigh loss term of the kl + vb_loss = kl / pt + kl_prior + + return vb_loss + + elif self.multinomial_loss_type == 'vb_all': + # Expensive, dont do it ;). + # DEPRECATED + return -self.nll(log_x_start) + else: + raise ValueError() + + def log_prob(self, x, out_dict): + b, device = x.size(0), x.device + if self.training: + return self._multinomial_loss(x, out_dict) + + else: + log_x_start = index_to_log_onehot(x, self.num_classes) + + t, pt = self.sample_time(b, device, 'importance') + + kl = self.compute_Lt( + log_x_start, self.q_sample(log_x_start=log_x_start, t=t), t, out_dict) + + kl_prior = self.kl_prior(log_x_start) + + # Upweigh loss term of the kl + loss = kl / pt + kl_prior + + return -loss + + def mixed_loss(self, x, out_dict): + b = x.shape[0] + device = x.device + t, pt = self.sample_time(b, device, 'uniform') + + x_num = x[:, :self.num_numerical_features] + x_cat = x[:, self.num_numerical_features:] + + x_num_t = x_num + log_x_cat_t = x_cat + if x_num.shape[1] > 0: + noise = torch.randn_like(x_num) + x_num_t = self.gaussian_q_sample(x_num, t, noise=noise) + if x_cat.shape[1] > 0: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes) + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t) + + x_in = torch.cat([x_num_t, log_x_cat_t], dim=1) + + model_out = self._denoise_fn( + x_in, + t, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + loss_multi = torch.zeros((1,)).float() + loss_gauss = torch.zeros((1,)).float() + if x_cat.shape[1] > 0: + loss_multi = self._multinomial_loss(model_out_cat, log_x_cat, log_x_cat_t, t, pt, out_dict) / len(self.num_classes) + + if x_num.shape[1] > 0: + loss_gauss = self._gaussian_loss(model_out_num, x_num, x_num_t, t, noise) + + # loss_multi = torch.where(out_dict['y'] == 1, loss_multi, 2 * loss_multi) + # loss_gauss = torch.where(out_dict['y'] == 1, loss_gauss, 2 * loss_gauss) + + return loss_multi.mean(), loss_gauss.mean() + + @torch.no_grad() + def mixed_elbo(self, x0, out_dict): + b = x0.size(0) + device = x0.device + + x_num = x0[:, :self.num_numerical_features] + x_cat = x0[:, self.num_numerical_features:] + has_cat = x_cat.shape[1] > 0 + if has_cat: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes).to(device) + + gaussian_loss = [] + xstart_mse = [] + mse = [] + mu_mse = [] + out_mean = [] + true_mean = [] + multinomial_loss = [] + for t in range(self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + noise = torch.randn_like(x_num) + + x_num_t = self.gaussian_q_sample(x_start=x_num, t=t_array, noise=noise) + if has_cat: + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t_array) + else: + log_x_cat_t = x_cat + + model_out = self._denoise_fn( + torch.cat([x_num_t, log_x_cat_t], dim=1), + t_array, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + kl = torch.tensor([0.0]) + if has_cat: + kl = self.compute_Lt( + model_out=model_out_cat, + log_x_start=log_x_cat, + log_x_t=log_x_cat_t, + t=t_array, + out_dict=out_dict + ) + + out = self._vb_terms_bpd( + model_out_num, + x_start=x_num, + x_t=x_num_t, + t=t_array, + clip_denoised=False + ) + + multinomial_loss.append(kl) + gaussian_loss.append(out["output"]) + xstart_mse.append(mean_flat((out["pred_xstart"] - x_num) ** 2)) + # mu_mse.append(mean_flat(out["mean_mse"])) + out_mean.append(mean_flat(out["out_mean"])) + true_mean.append(mean_flat(out["true_mean"])) + + eps = self._predict_eps_from_xstart(x_num_t, t_array, out["pred_xstart"]) + mse.append(mean_flat((eps - noise) ** 2)) + + gaussian_loss = torch.stack(gaussian_loss, dim=1) + multinomial_loss = torch.stack(multinomial_loss, dim=1) + xstart_mse = torch.stack(xstart_mse, dim=1) + mse = torch.stack(mse, dim=1) + # mu_mse = torch.stack(mu_mse, dim=1) + out_mean = torch.stack(out_mean, dim=1) + true_mean = torch.stack(true_mean, dim=1) + + + + prior_gauss = self._prior_gaussian(x_num) + + prior_multin = torch.tensor([0.0]) + if has_cat: + prior_multin = self.kl_prior(log_x_cat) + + total_gauss = gaussian_loss.sum(dim=1) + prior_gauss + total_multin = multinomial_loss.sum(dim=1) + prior_multin + return { + "total_gaussian": total_gauss, + "total_multinomial": total_multin, + "losses_gaussian": gaussian_loss, + "losses_multinimial": multinomial_loss, + "xstart_mse": xstart_mse, + "mse": mse, + # "mu_mse": mu_mse + "out_mean": out_mean, + "true_mean": true_mean + } + + @torch.no_grad() + def gaussian_ddim_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + denoised_fn=None, + eta=0.0 + ): + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=None, + ) + + eps = self._predict_eps_from_xstart(x, t, out["pred_xstart"]) + + alpha_bar = extract(self.alphas_cumprod, t, x.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, x.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + noise = torch.randn_like(x) + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_prev) + + torch.sqrt(1 - alpha_bar_prev - sigma ** 2) * eps + ) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + sample = mean_pred + nonzero_mask * sigma * noise + + return sample + + @torch.no_grad() + def gaussian_ddim_sample( + self, + noise, + T, + out_dict, + eta=0.0 + ): + x = noise + b = x.shape[0] + device = x.device + for t in reversed(range(T)): + print(f'Sample timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_step( + out_num, + x, + t_array + ) + print() + return x + + + @torch.no_grad() + def gaussian_ddim_reverse_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + eta=0.0 + ): + assert eta == 0.0, "Eta must be zero." + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=None, + model_kwargs=None, + ) + + eps = ( + extract(self.sqrt_recip_alphas_cumprod, t, x.shape) * x + - out["pred_xstart"] + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x.shape) + alpha_bar_next = extract(self.alphas_cumprod_next, t, x.shape) + + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_next) + + torch.sqrt(1 - alpha_bar_next) * eps + ) + + return mean_pred + + @torch.no_grad() + def gaussian_ddim_reverse_sample( + self, + x, + T, + out_dict, + ): + b = x.shape[0] + device = x.device + for t in range(T): + print(f'Reverse timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_reverse_step( + out_num, + x, + t_array, + eta=0.0 + ) + print() + + return x + + + @torch.no_grad() + def multinomial_ddim_step( + self, + model_out_cat, + log_x_t, + t, + out_dict, + eta=0.0 + ): + # not ddim, essentially + log_x0 = self.predict_start(model_out_cat, log_x_t=log_x_t, t=t, out_dict=out_dict) + + alpha_bar = extract(self.alphas_cumprod, t, log_x_t.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, log_x_t.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + coef1 = sigma + coef2 = alpha_bar_prev - sigma * alpha_bar + coef3 = 1 - coef1 - coef2 + + + log_ps = torch.stack([ + torch.log(coef1) + log_x_t, + torch.log(coef2) + log_x0, + torch.log(coef3) - torch.log(self.num_classes_expanded) + ], dim=2) + + log_prob = torch.logsumexp(log_ps, dim=2) + + out = self.log_sample_categorical(log_prob) + + return out + + @torch.no_grad() + def sample_ddim(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_ddim_step(model_out_num, z_norm, t, clip_denoised=False) + if has_cat: + log_z = self.multinomial_ddim_step(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + + @torch.no_grad() + def sample(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_p_sample(model_out_num, z_norm, t, clip_denoised=False)['sample'] + if has_cat: + log_z = self.p_sample(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + def sample_all(self, num_samples, batch_size, y_dist, ddim=False): + if ddim: + print('Sample using DDIM.') + sample_fn = self.sample_ddim + else: + sample_fn = self.sample + + b = batch_size + + all_y = [] + all_samples = [] + num_generated = 0 + while num_generated < num_samples: + sample, out_dict = sample_fn(b, y_dist) + mask_nan = torch.any(sample.isnan(), dim=1) + sample = sample[~mask_nan] + out_dict['y'] = out_dict['y'][~mask_nan] + + all_samples.append(sample) + all_y.append(out_dict['y'].cpu()) + if sample.shape[0] != b: + raise FoundNANsError + num_generated += sample.shape[0] + + x_gen = torch.cat(all_samples, dim=0)[:num_samples] + y_gen = torch.cat(all_y, dim=0)[:num_samples] + + return x_gen, y_gen \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/modules.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/modules.py new file mode 100644 index 0000000000000000000000000000000000000000..472ba5b5f44b646e83d429f0d6272a8fe6d7130d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/modules.py @@ -0,0 +1,486 @@ +""" +Code was adapted from https://github.com/Yura52/rtdl +""" + +import math +from typing import Any, Callable, Dict, List, Optional, Tuple, Type, Union, cast + +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim +from torch import Tensor + +ModuleType = Union[str, Callable[..., nn.Module]] + +class SiLU(nn.Module): + def forward(self, x): + return x * torch.sigmoid(x) + +def timestep_embedding(timesteps, dim, max_period=10000): + """ + Create sinusoidal timestep embeddings. + + :param timesteps: a 1-D Tensor of N indices, one per batch element. + These may be fractional. + :param dim: the dimension of the output. + :param max_period: controls the minimum frequency of the embeddings. + :return: an [N x dim] Tensor of positional embeddings. + """ + half = dim // 2 + freqs = torch.exp( + -math.log(max_period) * torch.arange(start=0, end=half, dtype=torch.float32) / half + ).to(device=timesteps.device) + args = timesteps[:, None].float() * freqs[None] + embedding = torch.cat([torch.cos(args), torch.sin(args)], dim=-1) + if dim % 2: + embedding = torch.cat([embedding, torch.zeros_like(embedding[:, :1])], dim=-1) + return embedding + +def _is_glu_activation(activation: ModuleType): + return ( + isinstance(activation, str) + and activation.endswith('GLU') + or activation in [ReGLU, GEGLU] + ) + + +def _all_or_none(values): + assert all(x is None for x in values) or all(x is not None for x in values) + +def reglu(x: Tensor) -> Tensor: + """The ReGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.relu(b) + + +def geglu(x: Tensor) -> Tensor: + """The GEGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.gelu(b) + +class ReGLU(nn.Module): + """The ReGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = ReGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return reglu(x) + + +class GEGLU(nn.Module): + """The GEGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = GEGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return geglu(x) + +def _make_nn_module(module_type: ModuleType, *args) -> nn.Module: + return ( + ( + ReGLU() + if module_type == 'ReGLU' + else GEGLU() + if module_type == 'GEGLU' + else getattr(nn, module_type)(*args) + ) + if isinstance(module_type, str) + else module_type(*args) + ) + + +class MLP(nn.Module): + """The MLP model used in [gorishniy2021revisiting]. + + The following scheme describes the architecture: + + .. code-block:: text + + MLP: (in) -> Block -> ... -> Block -> Linear -> (out) + Block: (in) -> Linear -> Activation -> Dropout -> (out) + + Examples: + .. testcode:: + + x = torch.randn(4, 2) + module = MLP.make_baseline(x.shape[1], [3, 5], 0.1, 1) + assert module(x).shape == (len(x), 1) + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `MLP`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + activation: ModuleType, + dropout: float, + ) -> None: + super().__init__() + self.linear = nn.Linear(d_in, d_out, bias) + self.activation = _make_nn_module(activation) + self.dropout = nn.Dropout(dropout) + + def forward(self, x: Tensor) -> Tensor: + return self.dropout(self.activation(self.linear(x))) + + def __init__( + self, + *, + d_in: int, + d_layers: List[int], + dropouts: Union[float, List[float]], + activation: Union[str, Callable[[], nn.Module]], + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + if isinstance(dropouts, float): + dropouts = [dropouts] * len(d_layers) + assert len(d_layers) == len(dropouts) + assert activation not in ['ReGLU', 'GEGLU'] + + self.blocks = nn.ModuleList( + [ + MLP.Block( + d_in=d_layers[i - 1] if i else d_in, + d_out=d, + bias=True, + activation=activation, + dropout=dropout, + ) + for i, (d, dropout) in enumerate(zip(d_layers, dropouts)) + ] + ) + self.head = nn.Linear(d_layers[-1] if d_layers else d_in, d_out) + + @classmethod + def make_baseline( + cls: Type['MLP'], + d_in: int, + d_layers: List[int], + dropout: float, + d_out: int, + ) -> 'MLP': + """Create a "baseline" `MLP`. + + This variation of MLP was used in [gorishniy2021revisiting]. Features: + + * :code:`Activation` = :code:`ReLU` + * all linear layers except for the first one and the last one are of the same dimension + * the dropout rate is the same for all dropout layers + + Args: + d_in: the input size + d_layers: the dimensions of the linear layers. If there are more than two + layers, then all of them except for the first and the last ones must + have the same dimension. Valid examples: :code:`[]`, :code:`[8]`, + :code:`[8, 16]`, :code:`[2, 2, 2, 2]`, :code:`[1, 2, 2, 4]`. Invalid + example: :code:`[1, 2, 3, 4]`. + dropout: the dropout rate for all hidden layers + d_out: the output size + Returns: + MLP + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + assert isinstance(dropout, float) + if len(d_layers) > 2: + assert len(set(d_layers[1:-1])) == 1, ( + 'if d_layers contains more than two elements, then' + ' all elements except for the first and the last ones must be equal.' + ) + return MLP( + d_in=d_in, + d_layers=d_layers, # type: ignore + dropouts=dropout, + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + for block in self.blocks: + x = block(x) + x = self.head(x) + return x + + +class ResNet(nn.Module): + """The ResNet model used in [gorishniy2021revisiting]. + The following scheme describes the architecture: + .. code-block:: text + ResNet: (in) -> Linear -> Block -> ... -> Block -> Head -> (out) + |-> Norm -> Linear -> Activation -> Dropout -> Linear -> Dropout ->| + | | + Block: (in) ------------------------------------------------------------> Add -> (out) + Head: (in) -> Norm -> Activation -> Linear -> (out) + Examples: + .. testcode:: + x = torch.randn(4, 2) + module = ResNet.make_baseline( + d_in=x.shape[1], + n_blocks=2, + d_main=3, + d_hidden=4, + dropout_first=0.25, + dropout_second=0.0, + d_out=1 + ) + assert module(x).shape == (len(x), 1) + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `ResNet`.""" + + def __init__( + self, + *, + d_main: int, + d_hidden: int, + bias_first: bool, + bias_second: bool, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + skip_connection: bool, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_main) + self.linear_first = nn.Linear(d_main, d_hidden, bias_first) + self.activation = _make_nn_module(activation) + self.dropout_first = nn.Dropout(dropout_first) + self.linear_second = nn.Linear(d_hidden, d_main, bias_second) + self.dropout_second = nn.Dropout(dropout_second) + self.skip_connection = skip_connection + + def forward(self, x: Tensor) -> Tensor: + x_input = x + x = self.normalization(x) + x = self.linear_first(x) + x = self.activation(x) + x = self.dropout_first(x) + x = self.linear_second(x) + x = self.dropout_second(x) + if self.skip_connection: + x = x_input + x + return x + + class Head(nn.Module): + """The final module of `ResNet`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + normalization: ModuleType, + activation: ModuleType, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_in) + self.activation = _make_nn_module(activation) + self.linear = nn.Linear(d_in, d_out, bias) + + def forward(self, x: Tensor) -> Tensor: + if self.normalization is not None: + x = self.normalization(x) + x = self.activation(x) + x = self.linear(x) + return x + + def __init__( + self, + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + + self.first_layer = nn.Linear(d_in, d_main) + if d_main is None: + d_main = d_in + self.blocks = nn.Sequential( + *[ + ResNet.Block( + d_main=d_main, + d_hidden=d_hidden, + bias_first=True, + bias_second=True, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization=normalization, + activation=activation, + skip_connection=True, + ) + for _ in range(n_blocks) + ] + ) + self.head = ResNet.Head( + d_in=d_main, + d_out=d_out, + bias=True, + normalization=normalization, + activation=activation, + ) + + @classmethod + def make_baseline( + cls: Type['ResNet'], + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + d_out: int, + ) -> 'ResNet': + """Create a "baseline" `ResNet`. + This variation of ResNet was used in [gorishniy2021revisiting]. Features: + * :code:`Activation` = :code:`ReLU` + * :code:`Norm` = :code:`BatchNorm1d` + Args: + d_in: the input size + n_blocks: the number of Blocks + d_main: the input size (or, equivalently, the output size) of each Block + d_hidden: the output size of the first linear layer in each Block + dropout_first: the dropout rate of the first dropout layer in each Block. + dropout_second: the dropout rate of the second dropout layer in each Block. + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + return cls( + d_in=d_in, + n_blocks=n_blocks, + d_main=d_main, + d_hidden=d_hidden, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization='BatchNorm1d', + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + x = self.first_layer(x) + x = self.blocks(x) + x = self.head(x) + return x +#### For diffusion + +class MLPDiffusion(nn.Module): + def __init__(self, d_in, num_classes, is_y_cond, rtdl_params, dim_t = 128): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + self.is_y_cond = is_y_cond + + # d0 = rtdl_params['d_layers'][0] + + rtdl_params['d_in'] = dim_t + rtdl_params['d_out'] = d_in + + self.mlp = MLP.make_baseline(**rtdl_params) + + if self.num_classes > 0 and is_y_cond: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + elif self.num_classes == 0 and is_y_cond: + self.label_emb = nn.Linear(1, dim_t) + + self.proj = nn.Linear(d_in, dim_t) + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if self.is_y_cond and y is not None: + if self.num_classes > 0: + y = y.squeeze() + else: + y = y.resize(y.size(0), 1).float() + emb += F.silu(self.label_emb(y)) + x = self.proj(x) + emb + return self.mlp(x) + +class ResNetDiffusion(nn.Module): + def __init__(self, d_in, num_classes, rtdl_params, dim_t = 256): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + + rtdl_params['d_in'] = d_in + rtdl_params['d_out'] = d_in + rtdl_params['emb_d'] = dim_t + self.resnet = ResNet.make_baseline(**rtdl_params) + + if self.num_classes > 0: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if y is not None and self.num_classes > 0: + emb += self.label_emb(y.squeeze()) + return self.resnet(x, emb) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/utils.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/utils.py new file mode 100644 index 0000000000000000000000000000000000000000..6376bfbfb6971c3e465fafe9d56320d92a5f508a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tab_ddpm/utils.py @@ -0,0 +1,174 @@ +import torch +import numpy as np +import torch.nn.functional as F +from torch.profiler import record_function +from inspect import isfunction + +def normal_kl(mean1, logvar1, mean2, logvar2): + """ + Compute the KL divergence between two gaussians. + + Shapes are automatically broadcasted, so batches can be compared to + scalars, among other use cases. + """ + tensor = None + for obj in (mean1, logvar1, mean2, logvar2): + if isinstance(obj, torch.Tensor): + tensor = obj + break + assert tensor is not None, "at least one argument must be a Tensor" + + # Force variances to be Tensors. Broadcasting helps convert scalars to + # Tensors, but it does not work for torch.exp(). + logvar1, logvar2 = [ + x if isinstance(x, torch.Tensor) else torch.tensor(x).to(tensor) + for x in (logvar1, logvar2) + ] + + return 0.5 * ( + -1.0 + + logvar2 + - logvar1 + + torch.exp(logvar1 - logvar2) + + ((mean1 - mean2) ** 2) * torch.exp(-logvar2) + ) + +def approx_standard_normal_cdf(x): + """ + A fast approximation of the cumulative distribution function of the + standard normal. + """ + return 0.5 * (1.0 + torch.tanh(np.sqrt(2.0 / np.pi) * (x + 0.044715 * torch.pow(x, 3)))) + + +def discretized_gaussian_log_likelihood(x, *, means, log_scales): + """ + Compute the log-likelihood of a Gaussian distribution discretizing to a + given image. + + :param x: the target images. It is assumed that this was uint8 values, + rescaled to the range [-1, 1]. + :param means: the Gaussian mean Tensor. + :param log_scales: the Gaussian log stddev Tensor. + :return: a tensor like x of log probabilities (in nats). + """ + assert x.shape == means.shape == log_scales.shape + centered_x = x - means + inv_stdv = torch.exp(-log_scales) + plus_in = inv_stdv * (centered_x + 1.0 / 255.0) + cdf_plus = approx_standard_normal_cdf(plus_in) + min_in = inv_stdv * (centered_x - 1.0 / 255.0) + cdf_min = approx_standard_normal_cdf(min_in) + log_cdf_plus = torch.log(cdf_plus.clamp(min=1e-12)) + log_one_minus_cdf_min = torch.log((1.0 - cdf_min).clamp(min=1e-12)) + cdf_delta = cdf_plus - cdf_min + log_probs = torch.where( + x < -0.999, + log_cdf_plus, + torch.where(x > 0.999, log_one_minus_cdf_min, torch.log(cdf_delta.clamp(min=1e-12))), + ) + assert log_probs.shape == x.shape + return log_probs + +def sum_except_batch(x, num_dims=1): + ''' + Sums all dimensions except the first. + + Args: + x: Tensor, shape (batch_size, ...) + num_dims: int, number of batch dims (default=1) + + Returns: + x_sum: Tensor, shape (batch_size,) + ''' + return x.reshape(*x.shape[:num_dims], -1).sum(-1) + +def mean_flat(tensor): + """ + Take the mean over all non-batch dimensions. + """ + return tensor.mean(dim=list(range(1, len(tensor.shape)))) + +def ohe_to_categories(ohe, K): + K = torch.from_numpy(K) + indices = torch.cat([torch.zeros((1,)), K.cumsum(dim=0)], dim=0).int().tolist() + res = [] + for i in range(len(indices) - 1): + res.append(ohe[:, indices[i]:indices[i+1]].argmax(dim=1)) + return torch.stack(res, dim=1) + +def log_1_min_a(a): + return torch.log(1 - a.exp() + 1e-40) + + +def log_add_exp(a, b): + maximum = torch.max(a, b) + return maximum + torch.log(torch.exp(a - maximum) + torch.exp(b - maximum)) + +def exists(x): + return x is not None + +def extract(a, t, x_shape): + b, *_ = t.shape + t = t.to(a.device) + out = a.gather(-1, t) + while len(out.shape) < len(x_shape): + out = out[..., None] + return out.expand(x_shape) + +def default(val, d): + if exists(val): + return val + return d() if isfunction(d) else d + +def log_categorical(log_x_start, log_prob): + return (log_x_start.exp() * log_prob).sum(dim=1) + +def index_to_log_onehot(x, num_classes): + onehots = [] + for i in range(len(num_classes)): + onehots.append(F.one_hot(x[:, i], num_classes[i])) + + x_onehot = torch.cat(onehots, dim=1) + log_onehot = torch.log(x_onehot.float().clamp(min=1e-30)) + return log_onehot + +def log_sum_exp_by_classes(x, slices): + device = x.device + res = torch.zeros_like(x) + for ixs in slices: + res[:, ixs] = torch.logsumexp(x[:, ixs], dim=1, keepdim=True) + + assert x.size() == res.size() + + return res + +@torch.jit.script +def log_sub_exp(a: torch.Tensor, b: torch.Tensor) -> torch.Tensor: + m = torch.maximum(a, b) + return torch.log(torch.exp(a - m) - torch.exp(b - m)) + m + +@torch.jit.script +def sliced_logsumexp(x, slices): + lse = torch.logcumsumexp( + torch.nn.functional.pad(x, [1, 0, 0, 0], value=-float('inf')), + dim=-1) + + slice_starts = slices[:-1] + slice_ends = slices[1:] + + slice_lse = log_sub_exp(lse[:, slice_ends], lse[:, slice_starts]) + slice_lse_repeated = torch.repeat_interleave( + slice_lse, + slice_ends - slice_starts, + dim=-1 + ) + return slice_lse_repeated + +def log_onehot_to_index(log_x): + return log_x.argmax(1) + +class FoundNANsError(BaseException): + """Found NANs during sampling""" + def __init__(self, message='Found NANs during sampling.'): + super(FoundNANsError, self).__init__(message) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/convert_synth_to_csv.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/convert_synth_to_csv.py new file mode 100644 index 0000000000000000000000000000000000000000..be1bb6180758714a938e9c5c73a51029523e20f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/convert_synth_to_csv.py @@ -0,0 +1,89 @@ +#!/usr/bin/env python3 +""" +Convert generated synthetic data from npy files to CSV format. +""" +import os +import sys +import numpy as np +import pandas as pd +import argparse + +def convert_to_csv(parent_dir, output_path=None): + """ + Convert generated synthetic data to CSV. + + Args: + parent_dir: Directory containing X_num_train.npy, X_cat_train.npy, y_train.npy + output_path: Output CSV file path (default: parent_dir/synth_train.csv) + """ + parent_dir = os.path.abspath(parent_dir) + + # Load npy files + x_num_path = os.path.join(parent_dir, 'X_num_train.npy') + x_cat_path = os.path.join(parent_dir, 'X_cat_train.npy') + y_path = os.path.join(parent_dir, 'y_train.npy') + + data_parts = [] + column_names = [] + + # Load numerical features + if os.path.exists(x_num_path): + X_num = np.load(x_num_path, allow_pickle=True) + print(f"Loaded X_num: shape {X_num.shape}") + data_parts.append(X_num) + # Create column names for numerical features + for i in range(X_num.shape[1]): + column_names.append(f'num_{i}') + + # Load categorical features + if os.path.exists(x_cat_path): + X_cat = np.load(x_cat_path, allow_pickle=True) + print(f"Loaded X_cat: shape {X_cat.shape}") + data_parts.append(X_cat) + # Create column names for categorical features + for i in range(X_cat.shape[1]): + column_names.append(f'cat_{i}') + + # Load target + if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + print(f"Loaded y: shape {y.shape}") + # Reshape if needed + if y.ndim == 1: + y = y.reshape(-1, 1) + data_parts.append(y) + column_names.append('y') + + if not data_parts: + raise ValueError(f"No data files found in {parent_dir}") + + # Concatenate all parts + data = np.hstack(data_parts) + print(f"Combined data shape: {data.shape}") + print(f"Number of columns: {len(column_names)}") + + # Create DataFrame + df = pd.DataFrame(data, columns=column_names) + + # Determine output path + if output_path is None: + output_path = os.path.join(parent_dir, 'synth_train.csv') + + # Save to CSV + df.to_csv(output_path, index=False) + print(f"[OK] Saved synthetic data to: {output_path}") + print(f"[OK] Total samples: {len(df)}, Total columns: {len(df.columns)}") + + # Print summary statistics + print("\n=== Data Summary ===") + print(df.describe()) + + return output_path + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description='Convert synthetic npy files to CSV') + parser.add_argument('parent_dir', type=str, help='Directory containing generated npy files') + parser.add_argument('--output', '-o', type=str, default=None, help='Output CSV file path (default: parent_dir/synth_train.csv)') + + args = parser.parse_args() + convert_to_csv(args.parent_dir, args.output) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/make_tabddpm_info.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/make_tabddpm_info.py new file mode 100644 index 0000000000000000000000000000000000000000..30acf64d04521bfa8fc1810c893395eed5bd57a4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tools/make_tabddpm_info.py @@ -0,0 +1,97 @@ +import os, json +import numpy as np + +def load(path): + return np.load(path, allow_pickle=True) + +def main(data_dir: str): + # required files + req = [ + "X_num_train.npy","X_num_val.npy","X_num_test.npy", + "X_cat_train.npy","X_cat_val.npy","X_cat_test.npy", + "y_train.npy","y_val.npy","y_test.npy" + ] + for f in req: + p = os.path.join(data_dir, f) + if not os.path.exists(p): + raise FileNotFoundError(p) + + Xn_tr = load(os.path.join(data_dir,"X_num_train.npy")) + Xc_tr = load(os.path.join(data_dir,"X_cat_train.npy")) + y_tr = load(os.path.join(data_dir,"y_train.npy")) + + # basic dims + n_num = 0 if Xn_tr.ndim < 2 else int(Xn_tr.shape[1]) + n_cat = 0 if Xc_tr.ndim < 2 else int(Xc_tr.shape[1]) + + # infer task / y info + y_flat = y_tr.reshape(-1) + uniq = np.unique(y_flat) + # if y is integer and has few unique values, could be classification + is_int = np.issubdtype(y_flat.dtype, np.integer) + num_classes = int(len(uniq)) if is_int else 0 + + # determine task_type + if is_int and num_classes == 2: + task_type = "binclass" + elif is_int and num_classes > 2 and num_classes <= 100: + task_type = "multiclass" + else: + task_type = "regression" + + # cat sizes (per categorical column) + cat_sizes = [] + if n_cat > 0: + # compute max+1 per column (assume categories encoded 0..K-1) + for j in range(n_cat): + col = Xc_tr[:, j].reshape(-1) + if col.size == 0: + cat_sizes.append(0) + else: + mx = int(np.max(col)) + cat_sizes.append(mx + 1) + + # numeric stats (optional but useful) + num_stats = {} + if n_num > 0: + # mean/std/min/max over train numeric + num_stats = { + "mean": np.mean(Xn_tr, axis=0).tolist(), + "std": (np.std(Xn_tr, axis=0) + 1e-12).tolist(), + "min": np.min(Xn_tr, axis=0).tolist(), + "max": np.max(Xn_tr, axis=0).tolist(), + } + + # This repo expects info.json. Keep fields simple & robust. + info = { + "task_type": task_type, + "n_num_features": n_num, + "n_cat_features": n_cat, + "cat_sizes": cat_sizes, + "y_dtype": str(y_flat.dtype), + "y_unique_count": int(len(uniq)), + "y_unique_head": uniq[:20].tolist(), + # heuristics: user can override in config.toml + "is_classification_like": bool(is_int and len(uniq) <= 100), + "num_classes_like": num_classes, + } + + # write files + with open(os.path.join(data_dir, "info.json"), "w", encoding="utf-8") as f: + json.dump(info, f, ensure_ascii=False, indent=2) + + # some codepaths may look for these (harmless if unused) + with open(os.path.join(data_dir, "cat_sizes.json"), "w", encoding="utf-8") as f: + json.dump({"cat_sizes": cat_sizes}, f, ensure_ascii=False, indent=2) + + with open(os.path.join(data_dir, "num_stats.json"), "w", encoding="utf-8") as f: + json.dump(num_stats, f, ensure_ascii=False, indent=2) + + print("[OK] wrote:", os.path.join(data_dir,"info.json")) + print("[OK] n_num =", n_num, "n_cat =", n_cat, "cat_sizes =", cat_sizes) + print("[OK] y unique count =", len(uniq), "head =", uniq[:20]) + +if __name__ == "__main__": + data_dir = "data/Tab-Cate-1" + main(data_dir) + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7641bbf14b10338ac870e2a999866a64a3e119fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aad08aabbf726ab65389e42c3a524f407e6bc791edcb5af304c31ba9037f6c10 +size 351 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..51f7cdde4deeb5adf383c063ca60fe69af2092a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:956a488f34e502db9975d86ef25b75cf5c01c08a3e5a47c7ade4f72cbf11374c +size 432 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bc1fcb92e6fb025976224ef2fbf1335d1b1518a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4577f6d2af34360bff6faf7a01af5501463e8b13ff0fc0c18bf2bfa67c6c63b +size 393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19e1861532e4b5e50495f5444496fb558f45e875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0508cdc40c02386321976c9537fbe54a5f2b0fa0e8e7dde72a6d4d289ced862c +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7fc8cd71e630bcadef6c582f458d3e328dfc7024 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a411285e39c4cb685233ec73375cfd023fb834897dd6b5a8f99cf7a7ec1c6656 +size 403 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d646aac53ef0d8ad9f508fb14f561739d52441a9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4dea09bdea9006ce44f71eef0e1740f639eceff44dd021c351ece84a428a00a +size 380 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..53328b6729355daaba91f378caca2944b08dfb82 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb7ad47bb5b1c9fbe54cf14cc854581b22ed72f9dbc47f0a022e48fa572b5ffc +size 372 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..91aa99b5999ba8561744b73f036584956aa27735 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1265117a3d8688b7878c62656b6d85bb543e723b1f5f01a2ed5bd4b12878dc +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..8b118aadedc57bcea9ed8af0ac0318b17bd3850d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:18ccbc230cd0959834d3155e67c29d259af90720d29bc4284b3209df5374886e +size 519 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..39add46e4bb47ed0bb1e451e680788465aefa231 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:efa67605a7699adf3cd46bb7d7d5512516ab3e5da3e01451004aadf9ee4f9d62 +size 333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6d0379ccd1631f30b7983ee0ed809a88c422aed2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4c67d2f9937dc5548b3c3a1ae71846e5fccc66853b8067670b979ff2a4f0201 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..9d636369299b13991976af26b6337be2c6c88494 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852eea0c2f88f7032cebc5dc7c9422be385d231f1ce8b5c9364a534d64fdf4f3 +size 332 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..0951c97fd762261760bf64abeee35635ac8b3277 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2201078a643eb78c649a3d4a9e897ecf39c2d7f35c5a9fdb055c91251694b808 +size 369 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..b95d7e8aecc468014085b8c0959aa9e7be64812c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a94473811e28035ef4781122c3da6e4f81b232b68a0042b64c30a1df648e02d3 +size 374 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19ec2cc100638b21b99c87f453a4d6d356803ecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14dcf192aa15f491f147b30e2312b55889a146c546d72d89ee2d07ff26cc2103 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..ea8143610c6a60053cbac687cb32b2c7b203ebc7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f6989397bf0029ee07b2ca9ab9335645ea3402bd6b782f2cec4cb40ad70b2ed +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..f497e044f1e3a1ffd35f852d285ab43b841e7fc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f99f28009311b8bb5413fbdbf72af25d1d384eec3c079c156e6a6eafa93e46bb +size 157 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..db818565ea71189907985b9a9424a41dec1b5261 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d4d4e1b062e420ce1838117b872e1794a632ea7f1dd8220eb640b71f793cd3a +size 229 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d12f3fe28d7b352a4bb737f24abf65feb094b39a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfe610df17eb46233b0dbba7fb71ea6117e9992763ae8ccd789159c296f3cc43 +size 165 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cb7256f2b264df6ee73bb260e84d4cafd983c2ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9970d5c42859dce6fded5b3fb285bba98181076d8db75b8ef78e5e0167c7b0c +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cfa75fad250058c3798cb53873aaef3e60289b3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc9642d070f056675cd4d004c0b446576eb162e2819dec052325fe7da59ce85d +size 148 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..3e15732f32083afa27c5290d88430aab1fadf294 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebea18b44a2d33a6643f283adf68961099d44d7e4f11e29148b501ddabb5894a +size 152 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..45eb9feca3f3f48f560a1c136037e0e83e9acda7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2d6082a82af0fb59906d778c57e4229eeff861066c1e24bea9c5e721f804214c +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..69cfdc546559ac76088c0ce9e2abea88323bcd09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:243a914fe90215cab4867d415cb82078366b5d2472264c91ea46d3e0e3291534 +size 147 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..27781e4df360af0c233babc28485990447ee59e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3a819ad5093581e1b94eeddb0655b99cccce3bb121f405b0b7e3b230c3c1a11 +size 190 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..826c0e4d0b890d21ac21a2b6b9015d2e80b88b1f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3520fe130d4570aa07a79031b6016f31a4f36cd5fdc9ff7167f0c7e1768a6697 +size 230 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..5f13b453f1c8978346138fbfae950bc48f8f419a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22f1903d9a59e6cc1df1a643b9bc216392fbb3549cb6555482898d4a7ac936aa +size 164 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..00d8f78622f81428c7c94021982ae59c8890fa84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:381e76611b072a0fb5fa41a7c640740453293a6d0cda8210697d4b9833d715e4 +size 171 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7c7fcaf8ef05cdad5022fb1430047318c48d2107 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:afbbb1a2be60833c9468ded47ba78228e5a00c42bed93681e4e2aa0c6b68278d +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6a2fa20fe823c8adf1023a889e918326997a7b8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:896a60d6ce4628cacdf5a3ec5a4c70b9fcff7944e373082ca34a6b55d7c6871a +size 175 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bfd0c2cc0dc2b572be260a3ec20b74139efd885c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1489c33a341492905b3145370808bd2201a18fe8a1ae604df8917408821f57de +size 144 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r0.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r0.py new file mode 100644 index 0000000000000000000000000000000000000000..e877b60ebc2b30cf98d0f9b6299a635a6339e3ef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r0.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r0.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r1.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r1.py new file mode 100644 index 0000000000000000000000000000000000000000..4d53e11fc6fc57d87333e07fa361cf584f720741 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r1.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r1.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r2.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r2.py new file mode 100644 index 0000000000000000000000000000000000000000..f35694dac5e5da72705fb89832c831ec5d0feb80 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r2.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r2.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r3.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r3.py new file mode 100644 index 0000000000000000000000000000000000000000..3d41088d020576d65c1e228bf3d6f2deedcd1dc1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r3.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r3.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r4.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r4.py new file mode 100644 index 0000000000000000000000000000000000000000..e23cbbcd0812a7b331c2df176e98ad41ac668cac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r4.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r4.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r5.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r5.py new file mode 100644 index 0000000000000000000000000000000000000000..dd9b3d5861f25f08ab3f6380e8e35e995e845237 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r5.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r5.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r6.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r6.py new file mode 100644 index 0000000000000000000000000000000000000000..c6530080294d147385021f448180aa88d07c0d51 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r6.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r6.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r7.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r7.py new file mode 100644 index 0000000000000000000000000000000000000000..ac878984f5237ec2d4adf2ad4a8a588d78bdfbac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r7.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r7.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r8.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r8.py new file mode 100644 index 0000000000000000000000000000000000000000..635e518b212397ed4150bcacce0b39f59d9cd57f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_sample_r8.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r8.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/tabddpm-c12-2623-20260510_234840.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_train.py new file mode 100644 index 0000000000000000000000000000000000000000..a9e7031fe97f00dc031db6cf9743538f68898ad0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_train.py @@ -0,0 +1,42 @@ +import os, sys, subprocess + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + +import shutil +shutil.rmtree(runtime_root, ignore_errors=True) +shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Write a wrapper that patches collections.Sequence (removed in Python 3.10+) +# before running pipeline.py - needed because skorch uses old API +wrapper = os.path.join(runtime_root, "_compat_run.py") +with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Training, config=/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config.toml") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260510_225413/config.toml", + "--train"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) +print("[TabDDPM] Training complete") diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9cf431c316af49dbc22fedfbde317d1e31100d1f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:73e342b944bc024abe5a57c98ae9e6902e63e82a378dec751ed3a184ffc5be5e +size 773 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r0.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r0.toml new file mode 100644 index 0000000000000000000000000000000000000000..8bf9f8ea76602cf39ac7b6dba5c7a328dea8e95b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r0.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1aeb90d5f40f66ee94312c09c7a75bc658fb14b742bf8403211789f4e398ca9a +size 773 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r1.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r1.toml new file mode 100644 index 0000000000000000000000000000000000000000..cd04739338c0e660c1e06ffdb9a786c5c290ca78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r1.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7ff8fee3839d48cf31532fa942a5873b0eb757da3423b5d33abb0a31f110ce04 +size 773 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r2.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r2.toml new file mode 100644 index 0000000000000000000000000000000000000000..c853ae88c3d310268b08072fdbb14dd7bfdfcb07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r2.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a75bb9eaa53a4506b3cbe8a99f36e3c62a8a4c02e1e8263adba791bc2d6c53f0 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r3.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r3.toml new file mode 100644 index 0000000000000000000000000000000000000000..238dbc23e3fb8212e4ab31751f4f4d9217e59a87 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r3.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:362023589e497dc49bea721780a630bc071304ad7220ca47c6b7c402c35d2219 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r4.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r4.toml new file mode 100644 index 0000000000000000000000000000000000000000..d382341d1cdbfa21b98f0124df9d420d88ab03b4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r4.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:594522fe296c08f7d7251ef4e97014e63418b423005d0e79061e7f427240ce37 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r5.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r5.toml new file mode 100644 index 0000000000000000000000000000000000000000..9b25a0ac99cce9b88c0402a14c32b3c01442c8f9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r5.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:970357c27528cbb721ddde279a474478a238f23395f526ba6acb42eb7fc413aa +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r6.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r6.toml new file mode 100644 index 0000000000000000000000000000000000000000..16f9bede6492dca98f9d678bc9fdc318a15e048a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r6.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6cfbf669929897fc9e25621d8cef76370db08eb1bb9854b11efe2a2389db83fc +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r7.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r7.toml new file mode 100644 index 0000000000000000000000000000000000000000..a3b41c476e05b0e34902cf53ffe013343948a205 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r7.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:094c73b9e3d9e1ead42be7835fbadb762cad53ac2511bb4d3172c571b39b669a +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r8.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r8.toml new file mode 100644 index 0000000000000000000000000000000000000000..46b463fc9d983c0b0b85ce2517781eb72ef66e1e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/config_sample_20260510_234840_r8.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:324e998bf511dc2638dd3b4bf86b23f44198ee861786b13ca031cb8b25c82f14 +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_cat_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_num_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d81ab6d13ff8932c1b47822a5508c046d9fd6f6b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce0d1648e7f4633f3c9aa6e2f8c5460ec86f01d4bfa155e977a71e9640744427 +size 51619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/y_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/data/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r0.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r0.log new file mode 100644 index 0000000000000000000000000000000000000000..ab85eea496c3b13dfc4053c89bfad3e10ced74bc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r0.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04c45e3672976cde034bb801692c3a0fc0ed7ef0bf15b4c3b14ed749a35c372a +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r1.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r1.log new file mode 100644 index 0000000000000000000000000000000000000000..d816931b5654bfff89f4d63a624a41f452436959 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r1.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1fb8fa047cc8b5b0eb7f0bd91836bc40359d2e76e262c5b53e6c16309f421ccd +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r2.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r2.log new file mode 100644 index 0000000000000000000000000000000000000000..8a1f5c4d51031bf6d7d5823ec4fe1a0ea9789c9d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r2.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fcbb0fa7d62d4c7ba825b9d5522e72a15aa05f650f3c4e262cc14f78ad8721d +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r3.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r3.log new file mode 100644 index 0000000000000000000000000000000000000000..8b1ac8c415340bffab595d9996d0c638415b91e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r3.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7a61348a6c6f858471c376b572b330df8e24a451265586ed6ce37bfbf262a65e +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r4.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r4.log new file mode 100644 index 0000000000000000000000000000000000000000..483d4390a4c6d3c3f9301d3c99f1467ff4501bd0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r4.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:861c3c9fca6c9bdf96eaad1498b71fe0e8f090c4d02cda00f5a1cd6eed0872bc +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r5.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r5.log new file mode 100644 index 0000000000000000000000000000000000000000..264046be3632ab02d4fb94f4390d2f28de2a2a87 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r5.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:876586842a4892d1455c5ee68081239944974358af789f9f54fe2ac960727beb +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r6.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r6.log new file mode 100644 index 0000000000000000000000000000000000000000..ca5fd894aeab00495e6fdef918b047c2870350cc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r6.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:59081abc7a2c5752bf6446ab7db5c2cd99382686c4880a22234fe5a33fcdd7cf +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r7.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r7.log new file mode 100644 index 0000000000000000000000000000000000000000..fd781296994ddf68bcece5bd24070625a81e93d4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r7.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:845e885ddd9020be1d5a8f429882f339b87513480558b07a054a19b438be24e3 +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r8.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r8.log new file mode 100644 index 0000000000000000000000000000000000000000..5aef2bcb9ee51a75a4687558e1f0a33e8cb928c0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/gen_20260510_234840_r8.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:443226e4a0cabddac6675d150dfcd0a79f9bbfa2fbe3c1b0a1174b821123069e +size 5607 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/input_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..ea0c7955c35965e09281e7ad72e7f9722a3d793b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:754197615fcbb84d31c0a54a0fd62ded7a78578807874b50d4c73f62b7e80ef5 +size 1367 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..46b463fc9d983c0b0b85ce2517781eb72ef66e1e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:324e998bf511dc2638dd3b4bf86b23f44198ee861786b13ca031cb8b25c82f14 +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d81ab6d13ff8932c1b47822a5508c046d9fd6f6b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce0d1648e7f4633f3c9aa6e2f8c5460ec86f01d4bfa155e977a71e9640744427 +size 51619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/loss.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/loss.csv new file mode 100644 index 0000000000000000000000000000000000000000..f3bc35ce4024279afaeb095ae2b75afa220ef540 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/loss.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3de5c47b1796eae0be9c9bb39b49a5e3bf5ace14d1b4ee5236592277c4d11620 +size 213 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model.pt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model.pt new file mode 100644 index 0000000000000000000000000000000000000000..51a3dadbd6c6fe885bcc176bc9be6398c0c5dcb8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c756ff1a56a0fa1273eb8fa05957de2f68bbebe1a13ac8741e9023303ac0487 +size 5327574 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model_ema.pt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model_ema.pt new file mode 100644 index 0000000000000000000000000000000000000000..7b836985e03a33c39574e2c304d273c1cee2990d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/output/model_ema.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a155d4d44c0a19c8fce10f4137fd98ddd2689b5d2f3c29e2971f3348dc8bd4c +size 5328418 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/public_gate_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..17ae2bcce316e44c44cc61fcc0cffe663fac7342 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e052f74864f7a80f78c4f163298f53a1e7f9aeefca5de0d97f51093aaee31462 +size 658435 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/run_config.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..2f4c633f3ef04d25abdaed9996d174a45ff1f7cc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ea26e112bac7f03f96cafc0c8e8577e7566c4343070d5bfe6913c8547d88c6b +size 2164 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/runtime_result.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..921cafd8f08c44b92de86dd5ce548fd045e051b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f71d888f347fb3e0e8e36bc31e9addffbc6d64407175362baa9fcb308a28c4b1 +size 1102 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/staged_features.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/test.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/train.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/val.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..6147991e75653ccd188d0fe0eaa2e4d919ae67cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d8576ccd985db377cbe7413eb3a7c368b5c8a989ad221e01787c39246bccc2f +size 323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_transforms_applied.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/model_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..d551a3485ef24d9251874c6f0ed13aa2bb57397a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/staged/tabddpm/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:404988481e27c760a8747d869476fe38ab7ed7001e7103051fa87b0fcb049bf2 +size 658634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/train_20260510_225420.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/train_20260510_225420.log new file mode 100644 index 0000000000000000000000000000000000000000..41c6f03c5a3a99f303b0112df5c86faa3a9f8c4b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260510_225413/train_20260510_225420.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e1d83ed187b2be1f1c39d72563a0358b6e024b48be1b71977841789d277f40b +size 753 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/._data b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/._data new file mode 100755 index 0000000000000000000000000000000000000000..89e52d9d55eea94a37ca2bfdd186b4b892b24643 Binary files /dev/null and b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/._data differ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..9b148cde6e315b01b30652b19f39a11f211dff1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitignore @@ -0,0 +1,22 @@ +.DS_Store +__pycache__/ +catboost_info/ +**/**.pt +**/**.ipynb +!agg_results.ipynb +**/**.npy +**/**.gz +**/**.sh +**/**.obj +**/**.png +**/**.tar +**/**.code-workspace +**/**.csv +exp/**/**/results_catboost.json +exp/**/**/results_mlp.json + +configs/ +data/ +junk/ +RF/ +exps/ \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitmodules b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitmodules new file mode 100644 index 0000000000000000000000000000000000000000..8c677ab737cbbdbc5c806cf58d27960efefcb11a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/.gitmodules @@ -0,0 +1,9 @@ +[submodule "ctgan"] + # path = CTGAN/CTGAN + url = https://github.com/sdv-dev/CTGAN +[submodule "ctabgan"] + # path = CTAB-GAN + url = https://github.com/Team-TUD/CTAB-GAN +[submodule "ctabgan+"] + # path = CTAB-GAN-Plus + url = https://github.com/Team-TUD/CTAB-GAN-Plus \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CONFIG_DESCRIPTION.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CONFIG_DESCRIPTION.md new file mode 100644 index 0000000000000000000000000000000000000000..646a0c00f329b55bc736d5cdbd1e797d1143cd1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CONFIG_DESCRIPTION.md @@ -0,0 +1,78 @@ +# Description of .toml config for TabDDPM +First of all, `train.T` and `eval.T` denote preprocessing for training and for evaluation, respectively. + +Here we list non-obvious parameters. + +Main part: +- `seed = 0` -- evaluation seed (and training, but for training it is fixed to 0) +- `parent_dir = "exp/abalone/check"` -- exp folder +- `real_data_path = "data/abalone/"` +- `model_type = "mlp"` -- model type that approximates the reverse process +- `num_numerical_features ` -- a number of numerical features in dataset +- `device = "cuda:0"` + +Model params: +- `is_y_cond` -- false for regression, true for classification +- `d_in` -- input dimension (not necessary, since scripts calculate it automatically) +- `num_calsses` -- zero for regression, a number of classes for classification +- `rtdl_params` -- MLP parameters + +```toml +seed = 0 +parent_dir = "exp/abalone/check" +real_data_path = "data/abalone/" +model_type = "mlp" +num_numerical_features = 7 +device = "cuda:0" + +[model_params] +is_y_cond = false +d_in = 11 +num_classes = 0 + +[model_params.rtdl_params] +d_layers = [ + 256, + 256, +] +dropout = 0.0 + +[diffusion_params] +num_timesteps = 1000 +gaussian_loss_type = "mse" +scheduler = "cosine" + +[train.main] +steps = 1000 +lr = 0.001 +weight_decay = 1e-05 +batch_size = 4096 + +[train.T] +seed = 0 +normalization = "quantile" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +[sample] +num_samples = 20800 +batch_size = 10000 +seed = 0 + +[eval.type] +eval_model = "catboost" +eval_type = "synthetic" + +[eval.T] +seed = 0 +normalization = "__none__" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/README.md new file mode 100644 index 0000000000000000000000000000000000000000..e873924cc56b6603669d17e6ab3badd4aba0657a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/README.md @@ -0,0 +1,49 @@ +# CTAB-GAN+ +This is the official git paper [CTAB-GAN+: Enhancing Tabular Data Synthesis](https://arxiv.org/abs/2204.00401). Current code is without differential privacy part. +If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` +The sklean package in newer version has updated its function for `sklearn.mixture.BayesianGaussianMixture`. Therefore, user should use this proposed sklearn version to successfully run the code! + +## Example +`Experiment_Script_Adult.ipynb` `Experiment_Script_king.ipynb` are two example notebooks for training CTAB-GAN+ with Adult (classification) and king (regression) datasets. The datasets are alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## Problem type + +You can either indicate your dataset problem type as Classification, Regression. If there is no problem type, you can leave the problem type as None as follows: +``` +problem_type= {None: None} +``` + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN+ will wrap the encoded data into an image-like format. What you can do is changing the line 378 and 385 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@article{zhao2022ctab, + title={CTAB-GAN+: Enhancing Tabular Data Synthesis}, + author={Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y}, + journal={arXiv preprint arXiv:2204.00401}, + year={2022} +} +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..ac695958cb0fb057fa024d712d065588e43e5279 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0d9e05a1c251995561cb1f4b2688be2c332a4971a0513d15645089efc0e236a +size 4355 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..81782dcde9f07f3d8178c29ba08ceb129c40f58f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py @@ -0,0 +1,70 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + general_columns = ["age"], + non_categorical_columns = [], + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": "income"}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, seed=0): + + sample = self.synthesizer.sample(len(self.raw_df), seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..abe1f725f7d09f7284abef0dd9c1187f0e3c96bf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py @@ -0,0 +1,130 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..9fd6845ffaf8f3a991acceba92af143941e5c11f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,601 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 64] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 64] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=2e-4, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + while len(result) < n: + data_resample = [] + steps_left = resample// self.batch_size + 1 + + for i in range(steps_left): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a99b5d587da5f3e49b3923e43975e02e9c11e6e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py @@ -0,0 +1,72 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [], + log_columns = [], + mixed_columns= {}, + general_columns = [], + non_categorical_columns = [], + integer_columns = [], + problem_type= {}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + lr=lr, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..3f4b7293d63db51bc7c9da6c38b84c6c033d779b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py @@ -0,0 +1,131 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..521a29aff4e8db1d45c7c3be98d593892c65c8d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,605 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm, trange +import time + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + print(n) + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + t0 = time.time() + while len(result) < n and (time.time() - t0) <= 600: + data_resample = [] + steps_left = resample// sample_batch_size + 1 + # print(f"Sampling: {len(result)}/{n}") + for i in range(steps_left): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..a584f91844e866d04f3c59297ca66017f1e7dd6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py @@ -0,0 +1,81 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib +from model.ctabgan import CTABGAN + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..c1f668fe5b5d3d5255a3587982e968276e60273d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py @@ -0,0 +1,110 @@ +import lib +import os +import numpy as np +import argparse +from model.ctabgan import CTABGAN +from pathlib import Path +import torch +import pickle + + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..ed19426b03246e546e234a2501a7c06f173d9f03 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +from random import random +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + # steps = trial.suggest_categorical('steps', [1000]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan-plus/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan-plus/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan-plus/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan-plus", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..261eeb9e9f8b2b4b0d119366dda99c6fd7d35c64 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/License.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/License.txt new file mode 100644 index 0000000000000000000000000000000000000000..5404b6f9e08e11c3a28a214518830c963060c885 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/License.txt @@ -0,0 +1,15 @@ +Distributed learning systems Lab at TU Delft & Generatrix, hereby disclaims all copyright interest in the program "CTAB-GAN" (which synthesizes tabular data) + +Copyright 2020-2022 Distributed learning systems Lab at TU Delft & Generatrix. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + https://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..7fd4f2ac92abf9b244313a9ecf7d8328932cfc8c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/README.md @@ -0,0 +1,50 @@ +# CTAB-GAN +This is the official git paper [CTAB-GAN: Effective Table Data Synthesizing](https://proceedings.mlr.press/v157/zhao21a.html). The paper is published on Asian Conference on Machine Learning (ACML 2021), please check our pdf on PMLR website for our newest version of [paper](https://proceedings.mlr.press/v157/zhao21a.html), it adds more content on time consumption analysis of training CTAB-GAN. If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` + +## Example +`Experiment_Script_Adult.ipynb` is an example notebook for training CTAB-GAN with Adult dataset. The dataset is alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN will wrap the encoded data into an image-like format. What you can do is changing the line 341 and 348 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@InProceedings{zhao21, + title = {CTAB-GAN: Effective Table Data Synthesizing}, + author = {Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y.}, + booktitle = {Proceedings of The 13th Asian Conference on Machine Learning}, + pages = {97--112}, + year = {2021}, + editor = {Balasubramanian, Vineeth N. and Tsang, Ivor}, + volume = {157}, + series = {Proceedings of Machine Learning Research}, + month = {17--19 Nov}, + publisher = {PMLR}, + pdf = {https://proceedings.mlr.press/v157/zhao21a/zhao21a.pdf}, + url = {https://proceedings.mlr.press/v157/zhao21a.html} +} + + +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..5acd6bbcc72f8df4869e43a9e55e4dca4b32c616 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c59fb02cb7f4a153aecb9e18dd81bbbb6946e55c3e6928c748811fcf5a85ad79 +size 3179 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..d12c1a3c05d486c698bca7012d45bf31bc50ffbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py @@ -0,0 +1,58 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": 'income'}, + batch_size = 512, + class_dim = (256, 256, 256, 256), + lr = 2e-4, + epochs = 10, + device=None): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer(lr = lr, epochs = epochs, batch_size = batch_size, class_dim = class_dim, device = device) + self.raw_df = df + print(self.raw_df.shape) + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self, no_train=False): + print("-"*100) + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], + mixed = self.data_prep.column_types["mixed"],type=self.problem_type, no_train=no_train) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + print("-"*100) + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..2cc965efb802eac7263640e94ffba0cbdfff8c7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py @@ -0,0 +1,191 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(X_train_real) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..dec2dc9715af03ecabf6efb3cff333588e5aa25c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py @@ -0,0 +1,114 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.lower_bounds = {} + self.label_encoder_list = [] + + + target_col = list(type.values())[0] + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + X_train_real[target_col]= y_train_real + + self.df = X_train_real + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..7e4dd5cc2ecfb7c730b8cdab498c3cba332a318f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,526 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, BatchNorm2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + ed= st+output_info[tc][0] + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_D = [] + for prev, curr in zip(layer_dims, layer_dims[1:]): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + BatchNorm2d(curr[0]), + LeakyReLU(0.2, inplace=True) + ] + print() + layers_D += [ + + Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), + Sigmoid() + ] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_G = [ + ConvTranspose2d( + random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False) + ] + + for prev, curr in zip(reversed(layer_dims), reversed(layer_dims[:-1])): + layers_G += [ + BatchNorm2d(prev[0]), + ReLU(True), + ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True) + ] + return layers_G + + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + lr=2e-4, + class_dim=(256, 256, 256, 256), + random_dim=128, + num_channels=64, + l2scale=1e-5, + batch_size=1024, + epochs=1, + device=torch.device("cpu")): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = device + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, type={}, no_train=False): + print("Fit started.") + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed) + self.transformer.fit() + + train_data = self.transformer.transform(train_data.values) + + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + + if no_train: return + + print("Training started.") + for i in range(self.epochs): + # for _ in range(steps_per_epoch): + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + y_real,_ = discriminator(real_cat_d) + y_fake,_ = discriminator(fake_cat_d) + loss_d = (-(torch.log(y_real + 1e-4).mean()) - (torch.log(1. - y_fake + 1e-4).mean())) + loss_d.backward() + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + g = -(torch.log(y_fake + 1e-4).mean()) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + if (i + 1) % 500 == 0: + print(f"Step: {i}/{self.epochs} Loss: {loss_mean:.4f}") + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + # print(len(data)) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result = self.transformer.inverse_transform(data) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..18fc3c492a99c7f2455ebf2c2cddf09525333b92 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py @@ -0,0 +1,363 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + gm = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh'), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + data_t[:, id_] = tmp + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + return data_t + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..9ed3e80f4a226ec8e973f5f15db87540e4fa01a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..1144dbbc7b9c35690b609f5717d766abd4ba9567 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/requirements.txt @@ -0,0 +1,6 @@ +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..be74a48ec44624d341dda0f684780ac698ec3851 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py @@ -0,0 +1,108 @@ +import lib +import os +import numpy as np +import argparse +from pathlib import Path +from model.ctabgan import CTABGAN +import torch +import pickle + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1).values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..71e73f1edc23821ea1ea099a10095a6b1de032ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py @@ -0,0 +1,150 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig new file mode 100644 index 0000000000000000000000000000000000000000..8558c49851ee32e7577c83758bf92941054d2c5c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig @@ -0,0 +1,24 @@ +# http://editorconfig.org + +root = true + +[*] +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true +insert_final_newline = true +charset = utf-8 +end_of_line = lf + +[*.py] +max_line_length = 99 + +[*.bat] +indent_style = tab +end_of_line = crlf + +[LICENSE] +insert_final_newline = false + +[Makefile] +indent_style = tab diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS new file mode 100644 index 0000000000000000000000000000000000000000..e4db0356f3f62a8480ae07791b86c28adff16739 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS @@ -0,0 +1,2 @@ +# Global rule: +* @sdv-dev/core-contributors diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000000000000000000000000000000000000..16e0decde54dd915131ba85aa981029946dc53aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,33 @@ +--- +name: Bug report +about: Report an error that you found when using CTGAN +title: '' +labels: bug, pending review +assignees: '' + +--- + +### Environment Details + +Please indicate the following details about the environment in which you found the bug: + +* CTGAN version: +* Python version: +* Operating System: + +### Error Description + + + +### Steps to reproduce + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000000000000000000000000000000000000..54d7b6a17c3456c79fd59efaa5819d071e0101b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,24 @@ +--- +name: Feature request +about: Request a new feature that you would like to see implemented in CTGAN +title: '' +labels: new feature, pending review +assignees: '' + +--- + +### Problem Description + + + +### Expected behavior + + + +### Additional context + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md new file mode 100644 index 0000000000000000000000000000000000000000..20aca671d77560c3c52bd7d00ae129ca2f160f8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md @@ -0,0 +1,33 @@ +--- +name: Question +about: Doubts about CTGAN usage +title: '' +labels: question, pending review +assignees: '' + +--- + +### Environment details + +If you are already running CTGAN, please indicate the following details about the environment in +which you are running it: + +* CTGAN version: +* Python version: +* Operating System: + +### Problem description + + + +### What I already tried + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml new file mode 100644 index 0000000000000000000000000000000000000000..fdc744eeec5f5a1a18ce12ab91a8796f1c25d9fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml @@ -0,0 +1,31 @@ +name: Integration Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run integration tests + run: invoke integration diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml new file mode 100644 index 0000000000000000000000000000000000000000..07dde39e9f898c598379e9bd39dac1304be9456e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml @@ -0,0 +1,21 @@ +name: Style Checks + +on: + - push + - pull_request + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - name: Set up Python 3.8 + uses: actions/setup-python@v2 + with: + python-version: 3.8 + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[dev] + - name: Run lint checks + run: invoke lint diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml new file mode 100644 index 0000000000000000000000000000000000000000..1989c957943adecaf4e9fb851971e961c9188b3d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml @@ -0,0 +1,31 @@ +name: Unit Tests Minimum Versions + +on: + - push + - pull_request + +jobs: + minimum: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch==1.8' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision==0.9.0' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Test with minimum versions + run: invoke minimum diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml new file mode 100644 index 0000000000000000000000000000000000000000..5a623b543050f215dce8a6ba0d9aeecf2875b779 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml @@ -0,0 +1,25 @@ +name: Test README + +on: + - push + - pull_request + +jobs: + readme: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15] # skip windows bc rundoc fails + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke rundoc . + - name: Run the README.md + run: invoke readme diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml new file mode 100644 index 0000000000000000000000000000000000000000..6a63f0e006e1c8d3b635c441661c5ceb0282066b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml @@ -0,0 +1,34 @@ +name: Unit Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run unit tests + run: invoke unit + - if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.8 + name: Upload codecov report + uses: codecov/codecov-action@v2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..1609a70e22920b86a4a717e9c9aae645184b0831 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.gitignore @@ -0,0 +1,107 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +.hypothesis/ +.pytest_cache/ +tests/readme_test/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ +docs/api/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# SageMath parsed files +*.sage.py + +# dotenv +.env + +# virtualenv +.venv +venv/ +ENV/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ + +# Vim +.*.swp diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml new file mode 100644 index 0000000000000000000000000000000000000000..ecfa96045b11d59a33951d94e2358ea6b30646b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml @@ -0,0 +1,15 @@ +# Config file for automatic testing at travis-ci.org +dist: bionic +language: python +python: + - 3.8 + - 3.7 + - 3.6 + +# Command to install dependencies +install: pip install -U tox-travis codecov + +after_success: codecov + +# Command to run tests +script: tox diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst new file mode 100644 index 0000000000000000000000000000000000000000..1ea30d0908426597369b5193f52f1ec2b6ff4826 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst @@ -0,0 +1,13 @@ +Credits +======= + +Research and Development Lead +----------------------------- + +* Lei Xu + +Contributors +------------ + +* Carles Sala +* Kevin Kuo diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst new file mode 100644 index 0000000000000000000000000000000000000000..a21b70abaec7c75cf14208a5438d0af3dfac03b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst @@ -0,0 +1,237 @@ +.. highlight:: shell + +============ +Contributing +============ + +Contributions are welcome, and they are greatly appreciated! Every little bit +helps, and credit will always be given. + +You can contribute in many ways: + +Types of Contributions +---------------------- + +Report Bugs +~~~~~~~~~~~ + +Report bugs at the `GitHub Issues page`_. + +If you are reporting a bug, please include: + +* Your operating system name and version. +* Any details about your local setup that might be helpful in troubleshooting. +* Detailed steps to reproduce the bug. + +Fix Bugs +~~~~~~~~ + +Look through the GitHub issues for bugs. Anything tagged with "bug" and "help +wanted" is open to whoever wants to implement it. + +Implement Features +~~~~~~~~~~~~~~~~~~ + +Look through the GitHub issues for features. Anything tagged with "enhancement" +and "help wanted" is open to whoever wants to implement it. + +Write Documentation +~~~~~~~~~~~~~~~~~~~ + +CTGAN could always use more documentation, whether as part of the +official CTGAN docs, in docstrings, or even on the web in blog posts, +articles, and such. + +Submit Feedback +~~~~~~~~~~~~~~~ + +The best way to send feedback is to file an issue at the `GitHub Issues page`_. + +If you are proposing a feature: + +* Explain in detail how it would work. +* Keep the scope as narrow as possible, to make it easier to implement. +* Remember that this is a volunteer-driven project, and that contributions + are welcome :) + +Get Started! +------------ + +Ready to contribute? Here's how to set up `CTGAN` for local development. + +1. Fork the `CTGAN` repo on GitHub. +2. Clone your fork locally:: + + $ git clone git@github.com:your_name_here/CTGAN.git + +3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, + this is how you set up your fork for local development:: + + $ mkvirtualenv CTGAN + $ cd CTGAN/ + $ make install-develop + +4. Create a branch for local development:: + + $ git checkout -b name-of-your-bugfix-or-feature + + Try to use the naming scheme of prefixing your branch with ``gh-X`` where X is + the associated issue, such as ``gh-3-fix-foo-bug``. And if you are not + developing on your own fork, further prefix the branch with your GitHub + username, like ``githubusername/gh-3-fix-foo-bug``. + + Now you can make your changes locally. + +5. While hacking your changes, make sure to cover all your developments with the required + unit tests, and that none of the old tests fail as a consequence of your changes. + For this, make sure to run the tests suite and check the code coverage:: + + $ make lint # Check code styling + $ make test # Run the tests + $ make coverage # Get the coverage report + +6. When you're done making changes, check that your changes pass all the styling checks and + tests, including other Python supported versions, using:: + + $ make test-all + +7. Make also sure to include the necessary documentation in the code as docstrings following + the `Google docstrings style`_. + If you want to view how your documentation will look like when it is published, you can + generate and view the docs with this command:: + + $ make view-docs + +8. Commit your changes and push your branch to GitHub:: + + $ git add . + $ git commit -m "Your detailed description of your changes." + $ git push origin name-of-your-bugfix-or-feature + +9. Submit a pull request through the GitHub website. + +Pull Request Guidelines +----------------------- + +Before you submit a pull request, check that it meets these guidelines: + +1. It resolves an open GitHub Issue and contains its reference in the title or + the comment. If there is no associated issue, feel free to create one. +2. Whenever possible, it resolves only **one** issue. If your PR resolves more than + one issue, try to split it in more than one pull request. +3. The pull request should include unit tests that cover all the changed code +4. If the pull request adds functionality, the docs should be updated. Put + your new functionality into a function with a docstring, and add the + feature to the documentation in an appropriate place. +5. The pull request should work for all the supported Python versions. Check the `Travis Build + Status page`_ and make sure that all the checks pass. + +Unit Testing Guidelines +----------------------- + +All the Unit Tests should comply with the following requirements: + +1. Unit Tests should be based only in unittest and pytest modules. + +2. The tests that cover a module called ``ctgan/path/to/a_module.py`` + should be implemented in a separated module called + ``tests/ctgan/path/to/test_a_module.py``. + Note that the module name has the ``test_`` prefix and is located in a path similar + to the one of the tested module, just inside the ``tests`` folder. + +3. Each method of the tested module should have at least one associated test method, and + each test method should cover only **one** use case or scenario. + +4. Test case methods should start with the ``test_`` prefix and have descriptive names + that indicate which scenario they cover. + Names such as ``test_some_methed_input_none``, ``test_some_method_value_error`` or + ``test_some_method_timeout`` are right, but names like ``test_some_method_1``, + ``some_method`` or ``test_error`` are not. + +5. Each test should validate only what the code of the method being tested does, and not + cover the behavior of any third party package or tool being used, which is assumed to + work properly as far as it is being passed the right values. + +6. Any third party tool that may have any kind of random behavior, such as some Machine + Learning models, databases or Web APIs, will be mocked using the ``mock`` library, and + the only thing that will be tested is that our code passes the right values to them. + +7. Unit tests should not use anything from outside the test and the code being tested. This + includes not reading or writing to any file system or database, which will be properly + mocked. + +Tips +---- + +To run a subset of tests:: + + $ python -m pytest tests.test_ctgan + $ python -m pytest -k 'foo' + +Release Workflow +---------------- + +The process of releasing a new version involves several steps combining both ``git`` and +``bumpversion`` which, briefly: + +1. Merge what is in ``master`` branch into ``stable`` branch. +2. Update the version in ``setup.cfg``, ``ctgan/__init__.py`` and + ``HISTORY.md`` files. +3. Create a new git tag pointing at the corresponding commit in ``stable`` branch. +4. Merge the new commit from ``stable`` into ``master``. +5. Update the version in ``setup.cfg`` and ``ctgan/__init__.py`` + to open the next development iteration. + +.. note:: Before starting the process, make sure that ``HISTORY.md`` has been updated with a new + entry that explains the changes that will be included in the new version. + Normally this is just a list of the Pull Requests that have been merged to master + since the last release. + +Once this is done, run of the following commands: + +1. If you are releasing a patch version:: + + make release + +2. If you are releasing a minor version:: + + make release-minor + +3. If you are releasing a major version:: + + make release-major + +Release Candidates +~~~~~~~~~~~~~~~~~~ + +Sometimes it is necessary or convenient to upload a release candidate to PyPi as a pre-release, +in order to make some of the new features available for testing on other projects before they +are included in an actual full-blown release. + +In order to perform such an action, you can execute:: + + make release-candidate + +This will perform the following actions: + +1. Build and upload the current version to PyPi as a pre-release, with the format ``X.Y.Z.devN`` + +2. Bump the current version to the next release candidate, ``X.Y.Z.dev(N+1)`` + +After this is done, the new pre-release can be installed by including the ``dev`` section in the +dependency specification, either in ``setup.py``:: + + install_requires = [ + ... + 'ctgan>=X.Y.Z.dev', + ... + ] + +or in command line:: + + pip install 'ctgan>=X.Y.Z.dev' + + +.. _GitHub issues page: https://github.com/sdv-dev/CTGAN/issues +.. _Travis Build Status page: https://travis-ci.org/sdv-dev/CTGAN/pull_requests +.. _Google docstrings style: https://google.github.io/styleguide/pyguide.html?showone=Comments#Comments diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md new file mode 100644 index 0000000000000000000000000000000000000000..df2595e5dbbc2a9c44d571d9ae63bf86670e6cf2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md @@ -0,0 +1,147 @@ +# History + +## v0.5.1 - 2022-02-25 + +This release fixes a bug with the decoder instantiation, and also allows users to set a random state for the model +fitting and sampling. + +### Issues closed + +* Update self.decoder with correct variable name - Issue [#203](https://github.com/sdv-dev/CTGAN/issues/203) by @tejuafonja +* Add random state - Issue [#204](https://github.com/sdv-dev/CTGAN/issues/204) by @katxiao + +## v0.5.0 - 2021-11-18 + +This release adds support for Python 3.9 and updates dependencies to ensure compatibility with the +rest of the SDV ecosystem, and upgrades to the latests [RDT](https://github.com/sdv-dev/RDT/releases/tag/v0.6.1) +release. + +### Issues closed + +* Add support for Python 3.9 - Issue [#177](https://github.com/sdv-dev/CTGAN/issues/177) by @pvk-developer +* Add pip check to CI workflows - Issue [#174](https://github.com/sdv-dev/CTGAN/issues/174) by @pvk-developer +* Typo in `CTGAN` code - Issue [#158](https://github.com/sdv-dev/CTGAN/issues/158) by @ori-katz100 and @fealho + +## v0.4.3 - 2021-07-12 + +Dependency upgrades to ensure compatibility with the rest of the SDV ecosystem. + +## v0.4.2 - 2021-04-27 + +In this release, the way in which the loss function of the TVAE model was computed has been fixed. +In addition, the default value of the `discriminator_decay` has been changed to a more optimal +value. Also some improvements to the tests were added. + +### Issues closed + +* `TVAE`: loss function - Issue [#143](https://github.com/sdv-dev/CTGAN/issues/143) by @fealho and @DingfanChen +* Set `discriminator_decay` to `1e-6` - Pull request [#145](https://github.com/sdv-dev/CTGAN/pull/145/) by @fealho +* Adds unit tests - Pull requests [#140](https://github.com/sdv-dev/CTGAN/pull/140) by @fealho + +## v0.4.1 - 2021-03-30 + +This release exposes all the hyperparameters which the user may find useful for both `CTGAN` +and `TVAE`. Also `TVAE` can now be fitted on datasets that are shorter than the batch +size and drops the last batch only if the data size is not divisible by the batch size. + +### Issues closed + +* `TVAE`: Adapt `batch_size` to data size - Issue [#135](https://github.com/sdv-dev/CTGAN/issues/135) by @fealho and @csala +* `ValueError` from `validate_discre_columns` with `uniqueCombinationConstraint` - Issue [133](https://github.com/sdv-dev/CTGAN/issues/133) by @fealho and @MLjungg + +## v0.4.0 - 2021-02-24 + +Maintenance relese to upgrade dependencies to ensure compatibility with the rest +of the SDV libraries. + +Also add a validation on the CTGAN `condition_column` and `condition_value` inputs. + +### Improvements + +* Validate condition_column and condition_value - Issue [#124](https://github.com/sdv-dev/CTGAN/issues/124) by @fealho + +## v0.3.1 - 2021-01-27 + +### Improvements + +* Check discrete_columns valid before fitting - [Issue #35](https://github.com/sdv-dev/CTGAN/issues/35) by @fealho + +## Bugs fixed + +* ValueError: max() arg is an empty sequence - [Issue #115](https://github.com/sdv-dev/CTGAN/issues/115) by @fealho + +## v0.3.0 - 2020-12-18 + +In this release we add a new TVAE model which was presented in the original CTGAN paper. +It also exposes more hyperparameters and moves epochs and log_frequency from fit to the constructor. + +A new verbose argument has been added to optionally disable unnecessary printing, and a new hyperparameter +called `discriminator_steps` has been added to CTGAN to control the number of optimization steps performed +in the discriminator for each generator epoch. + +The code has also been reorganized and cleaned up for better readability and interpretability. + +Special thanks to @Baukebrenninkmeijer @fealho @leix28 @csala for the contributions! + +### Improvements + +* Add TVAE - [Issue #111](https://github.com/sdv-dev/CTGAN/issues/111) by @fealho +* Move `log_frequency` to `__init__` - [Issue #102](https://github.com/sdv-dev/CTGAN/issues/102) by @fealho +* Add discriminator steps hyperparameter - [Issue #101](https://github.com/sdv-dev/CTGAN/issues/101) by @Baukebrenninkmeijer +* Code cleanup / Expose hyperparameters - [Issue #59](https://github.com/sdv-dev/CTGAN/issues/59) by @fealho and @leix28 +* Publish to conda repo - [Issue #54](https://github.com/sdv-dev/CTGAN/issues/54) by @fealho + +### Bugs fixed + +* Fixed NaN != NaN counting bug. - [Issue #100](https://github.com/sdv-dev/CTGAN/issues/100) by @fealho +* Update dependencies and testing - [Issue #90](https://github.com/sdv-dev/CTGAN/issues/90) by @csala + +## v0.2.2 - 2020-11-13 + +In this release we introduce several minor improvements to make CTGAN more versatile and +propertly support new types of data, such as categorical NaN values, as well as conditional +sampling and features to save and load models. + +Additionally, the dependency ranges and python versions have been updated to support up +to date runtimes. + +Many thanks @fealho @leix28 @csala @oregonpillow and @lurosenb for working on making this release possible! + +### Improvements + +* Drop Python 3.5 support - [Issue #79](https://github.com/sdv-dev/CTGAN/issues/79) by @fealho +* Support NaN values in categorical variables - [Issue #78](https://github.com/sdv-dev/CTGAN/issues/78) by @fealho +* Sample synthetic data conditioning on a discrete column - [Issue #69](https://github.com/sdv-dev/CTGAN/issues/69) by @leix28 +* Support recent versions of pandas - [Issue #57](https://github.com/sdv-dev/CTGAN/issues/57) by @csala +* Easy solution for restoring original dtypes - [Issue #26](https://github.com/sdv-dev/CTGAN/issues/26) by @oregonpillow + +### Bugs fixed + +* Loss to nan - [Issue #73](https://github.com/sdv-dev/CTGAN/issues/73) by @fealho +* Swapped the sklearn utils testing import statement - [Issue #53](https://github.com/sdv-dev/CTGAN/issues/53) by @lurosenb + +## v0.2.1 - 2020-01-27 + +Minor version including changes to ensure the logs are properly printed and +the option to disable the log transformation to the discrete column frequencies. + +Special thanks to @kevinykuo for the contributions! + +### Issues Resolved: + +* Option to sample from true data frequency instead of logged frequency - [Issue #16](https://github.com/sdv-dev/CTGAN/issues/16) by @kevinykuo +* Flush stdout buffer for epoch updates - [Issue #14](https://github.com/sdv-dev/CTGAN/issues/14) by @kevinykuo + +## v0.2.0 - 2019-12-18 + +Reorganization of the project structure with a new Python API, new Command Line Interface +and increased data format support. + +### Issues Resolved: + +* Reorganize the project structure - [Issue #10](https://github.com/sdv-dev/CTGAN/issues/10) by @csala +* Move epochs to the fit method - [Issue #5](https://github.com/sdv-dev/CTGAN/issues/5) by @csala + +## v0.1.0 - 2019-11-07 + +First Release - NeurIPS 2019 Version. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f6f8213bcfc525df1b533a0dd4b06f05f9a14ea8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/LICENSE @@ -0,0 +1,22 @@ +MIT License + +Copyright (c) 2019, MIT Data To AI Lab + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in new file mode 100644 index 0000000000000000000000000000000000000000..469520f584a4ffc098d13e23c0d273f89e01a06e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in @@ -0,0 +1,11 @@ +include AUTHORS.rst +include CONTRIBUTING.rst +include HISTORY.md +include LICENSE +include README.md + +recursive-include tests * +recursive-exclude * __pycache__ +recursive-exclude * *.py[co] + +recursive-include docs *.md *.rst conf.py Makefile make.bat *.jpg *.png *.gif diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/Makefile b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..bb667a145994b12c34f88661ec6a566f06a4518d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/Makefile @@ -0,0 +1,240 @@ +.DEFAULT_GOAL := help + +define BROWSER_PYSCRIPT +import os, webbrowser, sys + +try: + from urllib import pathname2url +except: + from urllib.request import pathname2url + +webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1]))) +endef +export BROWSER_PYSCRIPT + +define PRINT_HELP_PYSCRIPT +import re, sys + +for line in sys.stdin: + match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line) + if match: + target, help = match.groups() + print("%-20s %s" % (target, help)) +endef +export PRINT_HELP_PYSCRIPT + +BROWSER := python -c "$$BROWSER_PYSCRIPT" + +.PHONY: help +help: + @python -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST) + + +# CLEAN TARGETS + +.PHONY: clean-build +clean-build: ## remove build artifacts + rm -fr build/ + rm -fr dist/ + rm -fr .eggs/ + find . -name '*.egg-info' -exec rm -fr {} + + find . -name '*.egg' -exec rm -f {} + + +.PHONY: clean-pyc +clean-pyc: ## remove Python file artifacts + find . -name '*.pyc' -exec rm -f {} + + find . -name '*.pyo' -exec rm -f {} + + find . -name '*~' -exec rm -f {} + + find . -name '__pycache__' -exec rm -fr {} + + +.PHONY: clean-coverage +clean-coverage: ## remove coverage artifacts + rm -f .coverage + rm -f .coverage.* + rm -fr htmlcov/ + +.PHONY: clean-test +clean-test: ## remove test artifacts + rm -fr .tox/ + rm -fr .pytest_cache + +.PHONY: clean +clean: clean-build clean-pyc clean-test clean-coverage ## remove all build, test, coverage and Python artifacts + + +# INSTALL TARGETS + +.PHONY: install +install: clean-build clean-pyc ## install the package to the active Python's site-packages + pip install . + +.PHONY: install-test +install-test: clean-build clean-pyc ## install the package and test dependencies + pip install .[test] + +.PHONY: install-develop +install-develop: clean-build clean-pyc ## install the package in editable mode and dependencies for development + pip install -e .[dev] + +MINIMUM := $(shell sed -n '/install_requires = \[/,/]/p' setup.py | head -n-1 | tail -n+2 | sed 's/ *\(.*\),$?$$/\1/g' | tr '>' '=') + +.PHONY: install-minimum +install-minimum: ## install the minimum supported versions of the package dependencies + pip install $(MINIMUM) + + +# LINT TARGETS + + +.PHONY: lint +lint: ## check style with flake8 and isort + invoke lint + +.PHONY: fix-lint +fix-lint: ## fix lint issues using autoflake, autopep8, and isort + find ctgan tests -name '*.py' | xargs autoflake --in-place --remove-all-unused-imports --remove-unused-variables + autopep8 --in-place --recursive --aggressive ctgan tests + isort --apply --atomic --recursive ctgan tests + + +# TEST TARGETS + +.PHONY: test-unit +test-unit: ## run unit tests using pytest + invoke unit + +.PHONY: test-integration +test-integration: ## run integration tests using pytest + invoke integration + +.PHONY: test-readme +test-readme: ## run the readme snippets + invoke readme + +.PHONY: check-dependencies +check-dependencies: ## test if there are any broken dependencies + pip check + +.PHONY: test +test: test-unit test-integration test-readme ## test everything that needs test dependencies + +.PHONY: test-devel +test-devel: lint ## test everything that needs development dependencies + +.PHONY: test-all +test-all: ## run tests on every Python version with tox + tox -r + + +.PHONY: coverage +coverage: ## check code coverage quickly with the default Python + coverage run --source ctgan -m pytest + coverage report -m + coverage html + $(BROWSER) htmlcov/index.html + + +# RELEASE TARGETS + +.PHONY: dist +dist: clean ## builds source and wheel package + python setup.py sdist + python setup.py bdist_wheel + ls -l dist + +.PHONY: publish-confirm +publish-confirm: + @echo "WARNING: This will irreversibly upload a new version to PyPI!" + @echo -n "Please type 'confirm' to proceed: " \ + && read answer \ + && [ "$${answer}" = "confirm" ] + +.PHONY: publish-test +publish-test: dist publish-confirm ## package and upload a release on TestPyPI + twine upload --repository-url https://test.pypi.org/legacy/ dist/* + +.PHONY: publish +publish: dist publish-confirm ## package and upload a release + twine upload dist/* + +.PHONY: bumpversion-release +bumpversion-release: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release + git push --tags origin stable + +.PHONY: bumpversion-release-test +bumpversion-release-test: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release --no-tag + @echo git push --tags origin stable + +.PHONY: bumpversion-patch +bumpversion-patch: ## Merge stable to master and bumpversion patch + git checkout master + git merge stable + bumpversion --no-tag patch + git push + +.PHONY: bumpversion-candidate +bumpversion-candidate: ## Bump the version to the next candidate + bumpversion candidate --no-tag + +.PHONY: bumpversion-minor +bumpversion-minor: ## Bump the version the next minor skipping the release + bumpversion --no-tag minor + +.PHONY: bumpversion-major +bumpversion-major: ## Bump the version the next major skipping the release + bumpversion --no-tag major + +.PHONY: bumpversion-revert +bumpversion-revert: ## Undo a previous bumpversion-release + git checkout master + git branch -D stable + +CLEAN_DIR := $(shell git status --short | grep -v ??) +CURRENT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD 2>/dev/null) +CHANGELOG_LINES := $(shell git diff HEAD..origin/stable HISTORY.md 2>&1 | wc -l) + +.PHONY: check-clean +check-clean: ## Check if the directory has uncommitted changes +ifneq ($(CLEAN_DIR),) + $(error There are uncommitted changes) +endif + +.PHONY: check-master +check-master: ## Check if we are in master branch +ifneq ($(CURRENT_BRANCH),master) + $(error Please make the release from master branch\n) +endif + +.PHONY: check-history +check-history: ## Check if HISTORY.md has been modified +ifeq ($(CHANGELOG_LINES),0) + $(error Please insert the release notes in HISTORY.md before releasing) +endif + +.PHONY: check-release +check-release: check-clean check-master check-history ## Check if the release can be made + @echo "A new release can be made" + +.PHONY: release +release: check-release bumpversion-release publish bumpversion-patch + +.PHONY: release-test +release-test: check-release bumpversion-release-test publish-test bumpversion-revert + +.PHONY: release-candidate +release-candidate: check-master publish bumpversion-candidate + +.PHONY: release-candidate-test +release-candidate-test: check-clean check-master publish-test + +.PHONY: release-minor +release-minor: check-release bumpversion-minor release + +.PHONY: release-major +release-major: check-release bumpversion-major release diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..6c8ab04c4ff5f505eaf5f1bf68c55f0161593f07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/README.md @@ -0,0 +1,182 @@ +
+
+

+ This repository is part of The Synthetic Data Vault Project, a project from DataCebo. +

+ +[![Development Status](https://img.shields.io/badge/Development%20Status-2%20--%20Pre--Alpha-yellow)](https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha) +[![PyPI Shield](https://img.shields.io/pypi/v/ctgan.svg)](https://pypi.python.org/pypi/ctgan) +[![Unit Tests](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml/badge.svg)](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml) +[![Downloads](https://pepy.tech/badge/ctgan)](https://pepy.tech/project/ctgan) +[![Coverage Status](https://codecov.io/gh/sdv-dev/CTGAN/branch/master/graph/badge.svg)](https://codecov.io/gh/sdv-dev/CTGAN) + +
+
+

+ + + +

+
+ +
+ +# Overview + +CTGAN is a collection of Deep Learning based Synthetic Data Generators for single table data, which are able to learn from real data and generate synthetic clones with high fidelity. + +| Important Links | | +| --------------------------------------------- | -------------------------------------------------------------------- | +| :computer: **[Website]** | Check out the SDV Website for more information about the project. | +| :orange_book: **[SDV Blog]** | Regular publshing of useful content about Synthetic Data Generation. | +| :book: **[Documentation]** | Quickstarts, User and Development Guides, and API Reference. | +| :octocat: **[Repository]** | The link to the Github Repository of this library. | +| :scroll: **[License]** | The entire ecosystem is published under the MIT License. | +| :keyboard: **[Development Status]** | This software is in its Pre-Alpha stage. | +| [![][Slack Logo] **Community**][Community] | Join our Slack Workspace for announcements and discussions. | +| [![][MyBinder Logo] **Tutorials**][Tutorials] | Run the SDV Tutorials in a Binder environment. | + +[Website]: https://sdv.dev +[SDV Blog]: https://sdv.dev/blog +[Documentation]: https://sdv.dev/SDV +[Repository]: https://github.com/sdv-dev/CTGAN +[License]: https://github.com/sdv-dev/CTGAN/blob/master/LICENSE +[Development Status]: https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha +[Slack Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/slack.png +[Community]: https://join.slack.com/t/sdv-space/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw +[MyBinder Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/mybinder.png +[Tutorials]: https://mybinder.org/v2/gh/sdv-dev/SDV/master?filepath=tutorials + +## Implemented Models + +Currently, this library implements the **CTGAN** and **TVAE** models proposed in the [Modeling Tabular data using Conditional GAN](https://arxiv.org/abs/1907.00503) paper. For more information about these models, please check out the respective user guides: +* [CTGAN User Guide](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). +* [TVAE User Guide](https://sdv.dev/SDV/user_guides/single_table/tvae.html). + +# Install + +**CTGAN** is part of the **SDV** project and is automatically installed alongside it. For +details about this process please visit the [SDV Installation Guide]( +https://sdv.dev/SDV/getting_started/install.html) + +Optionally, **CTGAN** can also be installed as a standalone library using the following commands: + +**Using `pip`:** + +```bash +pip install ctgan +``` + +**Using `conda`:** + +```bash +conda install -c pytorch -c conda-forge ctgan +``` + +For more installation options please visit the [CTGAN installation Guide](INSTALL.md) + +# Usage Example + +> :warning: **WARNING**: If you're just getting started with synthetic data, we recommend using the SDV library which provides user-friendly APIs for interacting with CTGAN. To learn more about using CTGAN through SDV, check out the user guide [here](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). + +To get started with CTGAN, you should prepare your data as either a `numpy.ndarray` or a `pandas.DataFrame` object with two types of columns: + +* **Continuous Columns**: can contain any numerical value. +* **Discrete Columns**: contain a finite number values, whether these are string values or not. + +In this example we load the [Adult Census Dataset](https://archive.ics.uci.edu/ml/datasets/adult) which is a built-in demo dataset. We then model it using the **CTGANSynthesizer** and generate a synthetic copy of it. + + +```python3 +from ctgan import CTGANSynthesizer +from ctgan import load_demo + +data = load_demo() + +# Names of the columns that are discrete +discrete_columns = [ + 'workclass', + 'education', + 'marital-status', + 'occupation', + 'relationship', + 'race', + 'sex', + 'native-country', + 'income' +] + +ctgan = CTGANSynthesizer(epochs=10) +ctgan.fit(data, discrete_columns) + +# Synthetic copy +samples = ctgan.sample(1000) +``` + + + +# Join our community + + +1. Please have a look at the [Contributing Guide](https://sdv.dev/SDV/developer_guides/contributing.html) to see how you can contribute to the project. +2. If you have any doubts, feature requests or detect an error, please [open an issue on github](https://github.com/sdv-dev/CTGAN/issues) or [join our Slack Workspace](https://sdv-space.slack.com/join/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw#/). +3. Also, do not forget to check the [project documentation site](https://sdv.dev/SDV/)! + + +# Citing TGAN + +If you use CTGAN, please cite the following work: + +- *Lei Xu, Maria Skoularidou, Alfredo Cuesta-Infante, Kalyan Veeramachaneni.* **Modeling Tabular data using Conditional GAN**. NeurIPS, 2019. + +```LaTeX +@inproceedings{xu2019modeling, + title={Modeling Tabular data using Conditional GAN}, + author={Xu, Lei and Skoularidou, Maria and Cuesta-Infante, Alfredo and Veeramachaneni, Kalyan}, + booktitle={Advances in Neural Information Processing Systems}, + year={2019} +} +``` + +# Related Projects +Please note that these libraries are external contributions and are not maintained nor supervised by +the MIT DAI-Lab team. + +## R interface for CTGAN + +A wrapper around **CTGAN** has been implemented by Kevin Kuo @kevinykuo, bringing the functionalities +of **CTGAN** to **R** users. + +More details can be found in the corresponding repository: https://github.com/kasaai/ctgan + +## CTGAN Server CLI + +A package to easily deploy **CTGAN** onto a remote server. This package is developed by Timothy Pillow @oregonpillow. + +More details can be found in the corresponding repository: https://github.com/oregonpillow/ctgan-server-cli + +--- + + +
+ +
+
+
+ +[The Synthetic Data Vault Project](https://sdv.dev) was first created at MIT's [Data to AI Lab]( +https://dai.lids.mit.edu/) in 2016. After 4 years of research and traction with enterprise, we +created [DataCebo](https://datacebo.com) in 2020 with the goal of growing the project. +Today, DataCebo is the proud developer of SDV, the largest ecosystem for +synthetic data generation & evaluation. It is home to multiple libraries that support synthetic +data, including: + +* 🔄 Data discovery & transformation. Reverse the transforms to reproduce realistic data. +* 🧠 Multiple machine learning models -- ranging from Copulas to Deep Learning -- to create tabular, + multi table and time series data. +* 📊 Measuring quality and privacy of synthetic data, and comparing different synthetic data + generation models. + +[Get started using the SDV package](https://sdv.dev/SDV/getting_started/install.html) -- a fully +integrated solution and your one-stop shop for synthetic data. Or, use the standalone libraries +for specific needs. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md new file mode 100644 index 0000000000000000000000000000000000000000..92e2ec5aa40b081c940ac1e918efaeeed8623584 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md @@ -0,0 +1,29 @@ +## Instructions + +These are instructions to deploy the latest version of **CTGAN** to [conda](https://docs.conda.io/en/latest/). +It should be done after every new release. + +## Update the recipe +Prior to making the release on PyPI, you should update the meta.yaml to reflect any changes in the dependencies. +Note that you do not need to edit the version number as that is managed by bumpversion. + +## Make the PyPI release +Follow the standard release instructions to make a PyPI release. Then, return here to make the conda release. + +## Build a package +As part of the PyPI release, you will have updated the stable branch. You should now check out the stable +branch and build the conda package. + +```bash +git checkout stable +cd conda +conda build -c sdv-dev -c pytorch -c conda-forge . +``` + +## Upload to Anaconda +Finally, you can upload the resulting package to Anaconda. + +```bash +anaconda login +anaconda upload -u sdv-dev +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9d26c28c6ada4f4977d517986a05ceca138c7090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml @@ -0,0 +1,51 @@ +{% set name = 'ctgan' %} +{% set version = '0.5.2.dev0' %} + +package: + name: "{{ name|lower }}" + version: "{{ version }}" + +source: + url: "https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz" + +build: + number: 0 + noarch: python + entry_points: + - ctgan=ctgan.__main__:main + script: "{{ PYTHON }} -m pip install . -vv" + +requirements: + host: + - pip + - pytest-runner + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + run: + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + +about: + home: "https://github.com/sdv-dev/CTGAN" + license: MIT + license_family: MIT + license_file: + summary: "Conditional GAN for Tabular Data" + doc_url: + dev_url: + +extra: + recipe-maintainers: + - sdv-dev diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e3abb1c03b685802c21428ba050b1620e1a435fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py @@ -0,0 +1,17 @@ +# -*- coding: utf-8 -*- + +"""Top-level package for ctgan.""" + +__author__ = 'MIT Data To AI Lab' +__email__ = 'dailabmit@gmail.com' +__version__ = '0.5.2.dev0' + +from .demo import load_demo +from .synthesizers.ctgan import CTGANSynthesizer +from .synthesizers.tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer', + 'load_demo' +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..8291c1879b60d0de49db79fb6ca60d33f09c8763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py @@ -0,0 +1,102 @@ +"""CLI.""" + +import argparse + +from ctgan.data import read_csv, read_tsv, write_tsv +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def _parse_args(): + parser = argparse.ArgumentParser(description='CTGAN Command Line Interface') + parser.add_argument('-e', '--epochs', default=300, type=int, + help='Number of training epochs') + parser.add_argument('-t', '--tsv', action='store_true', + help='Load data in TSV format instead of CSV') + parser.add_argument('--no-header', dest='header', action='store_false', + help='The CSV file has no header. Discrete columns will be indices.') + + parser.add_argument('-m', '--metadata', help='Path to the metadata') + parser.add_argument('-d', '--discrete', + help='Comma separated list of discrete columns without whitespaces.') + parser.add_argument('-n', '--num-samples', type=int, + help='Number of rows to sample. Defaults to the training data size') + + parser.add_argument('--generator_lr', type=float, default=2e-4, + help='Learning rate for the generator.') + parser.add_argument('--discriminator_lr', type=float, default=2e-4, + help='Learning rate for the discriminator.') + + parser.add_argument('--generator_decay', type=float, default=1e-6, + help='Weight decay for the generator.') + parser.add_argument('--discriminator_decay', type=float, default=0, + help='Weight decay for the discriminator.') + + parser.add_argument('--embedding_dim', type=int, default=128, + help='Dimension of input z to the generator.') + parser.add_argument('--generator_dim', type=str, default='256,256', + help='Dimension of each generator layer. ' + 'Comma separated integers with no whitespaces.') + parser.add_argument('--discriminator_dim', type=str, default='256,256', + help='Dimension of each discriminator layer. ' + 'Comma separated integers with no whitespaces.') + + parser.add_argument('--batch_size', type=int, default=500, + help='Batch size. Must be an even number.') + parser.add_argument('--save', default=None, type=str, + help='A filename to save the trained synthesizer.') + parser.add_argument('--load', default=None, type=str, + help='A filename to load a trained synthesizer.') + + parser.add_argument('--sample_condition_column', default=None, type=str, + help='Select a discrete column name.') + parser.add_argument('--sample_condition_column_value', default=None, type=str, + help='Specify the value of the selected discrete column.') + + parser.add_argument('data', help='Path to training data') + parser.add_argument('output', help='Path of the output file') + + return parser.parse_args() + + +def main(): + """CLI.""" + args = _parse_args() + if args.tsv: + data, discrete_columns = read_tsv(args.data, args.metadata) + else: + data, discrete_columns = read_csv(args.data, args.metadata, args.header, args.discrete) + + if args.load: + model = CTGANSynthesizer.load(args.load) + else: + generator_dim = [int(x) for x in args.generator_dim.split(',')] + discriminator_dim = [int(x) for x in args.discriminator_dim.split(',')] + model = CTGANSynthesizer( + embedding_dim=args.embedding_dim, generator_dim=generator_dim, + discriminator_dim=discriminator_dim, generator_lr=args.generator_lr, + generator_decay=args.generator_decay, discriminator_lr=args.discriminator_lr, + discriminator_decay=args.discriminator_decay, batch_size=args.batch_size, + epochs=args.epochs) + model.fit(data, discrete_columns) + + if args.save is not None: + model.save(args.save) + + num_samples = args.num_samples or len(data) + + if args.sample_condition_column is not None: + assert args.sample_condition_column_value is not None + + sampled = model.sample( + num_samples, + args.sample_condition_column, + args.sample_condition_column_value) + + if args.tsv: + write_tsv(sampled, args.metadata, args.output) + else: + sampled.to_csv(args.output, index=False) + + +if __name__ == '__main__': + main() diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py new file mode 100644 index 0000000000000000000000000000000000000000..1c3ec72e9ec972f9c7d148b66f212bf3e366a340 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py @@ -0,0 +1,94 @@ +"""Data loading.""" + +import json + +import numpy as np +import pandas as pd + + +def read_csv(csv_filename, meta_filename=None, header=True, discrete=None): + """Read a csv file.""" + data = pd.read_csv(csv_filename, header='infer' if header else None) + + if meta_filename: + with open(meta_filename) as meta_file: + metadata = json.load(meta_file) + + discrete_columns = [ + column['name'] + for column in metadata['columns'] + if column['type'] != 'continuous' + ] + + elif discrete: + discrete_columns = discrete.split(',') + if not header: + discrete_columns = [int(i) for i in discrete_columns] + + else: + discrete_columns = [] + + return data, discrete_columns + + +def read_tsv(data_filename, meta_filename): + """Read a tsv file.""" + with open(meta_filename) as f: + column_info = f.readlines() + + column_info_raw = [ + x.replace('{', ' ').replace('}', ' ').split() + for x in column_info + ] + + discrete = [] + continuous = [] + column_info = [] + + for idx, item in enumerate(column_info_raw): + if item[0] == 'C': + continuous.append(idx) + column_info.append((float(item[1]), float(item[2]))) + else: + assert item[0] == 'D' + discrete.append(idx) + column_info.append(item[1:]) + + meta = { + 'continuous_columns': continuous, + 'discrete_columns': discrete, + 'column_info': column_info + } + + with open(data_filename) as f: + lines = f.readlines() + + data = [] + for row in lines: + row_raw = row.split() + row = [] + for idx, col in enumerate(row_raw): + if idx in continuous: + row.append(col) + else: + assert idx in discrete + row.append(column_info[idx].index(col)) + + data.append(row) + + return np.asarray(data, dtype='float32'), meta['discrete_columns'] + + +def write_tsv(data, meta, output_filename): + """Write to a tsv file.""" + with open(output_filename, 'w') as f: + + for row in data: + for idx, col in enumerate(row): + if idx in meta['continuous_columns']: + print(col, end=' ', file=f) + else: + assert idx in meta['discrete_columns'] + print(meta['column_info'][idx][int(col)], end=' ', file=f) + + print(file=f) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py new file mode 100644 index 0000000000000000000000000000000000000000..5cbf339dac0980c5368d2d11e2934a268fb9d43a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py @@ -0,0 +1,156 @@ +"""DataSampler module.""" + +import numpy as np + + +class DataSampler(object): + """DataSampler samples the conditional vector and corresponding data for CTGAN.""" + + def __init__(self, data, output_info, log_frequency): + self._data = data + + def is_discrete_column(column_info): + return (len(column_info) == 1 + and column_info[0].activation_fn == 'softmax') + + n_discrete_columns = sum( + [1 for column_info in output_info if is_discrete_column(column_info)]) + + self._discrete_column_matrix_st = np.zeros( + n_discrete_columns, dtype='int32') + + # Store the row id for each category in each discrete column. + # For example _rid_by_cat_cols[a][b] is a list of all rows with the + # a-th discrete column equal value b. + self._rid_by_cat_cols = [] + + # Compute _rid_by_cat_cols + st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + + rid_by_cat = [] + for j in range(span_info.dim): + rid_by_cat.append(np.nonzero(data[:, st + j])[0]) + self._rid_by_cat_cols.append(rid_by_cat) + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + assert st == data.shape[1] + + # Prepare an interval matrix for efficiently sample conditional vector + max_category = max([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ], default=0) + + self._discrete_column_cond_st = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_n_category = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_category_prob = np.zeros((n_discrete_columns, max_category)) + self._n_discrete_columns = n_discrete_columns + self._n_categories = sum([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ]) + + st = 0 + current_id = 0 + current_cond_st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + category_freq = np.sum(data[:, st:ed], axis=0) + if log_frequency: + category_freq = np.log(category_freq + 1) + category_prob = category_freq / np.sum(category_freq) + self._discrete_column_category_prob[current_id, :span_info.dim] = category_prob + self._discrete_column_cond_st[current_id] = current_cond_st + self._discrete_column_n_category[current_id] = span_info.dim + current_cond_st += span_info.dim + current_id += 1 + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + + def _random_choice_prob_index(self, discrete_column_id): + probs = self._discrete_column_category_prob[discrete_column_id] + r = np.expand_dims(np.random.rand(probs.shape[0]), axis=1) + return (probs.cumsum(axis=1) > r).argmax(axis=1) + + def sample_condvec(self, batch): + """Generate the conditional vector for training. + + Returns: + cond (batch x #categories): + The conditional vector. + mask (batch x #discrete columns): + A one-hot vector indicating the selected discrete column. + discrete column id (batch): + Integer representation of mask. + category_id_in_col (batch): + Selected category in the selected discrete column. + """ + if self._n_discrete_columns == 0: + return None + + discrete_column_id = np.random.choice( + np.arange(self._n_discrete_columns), batch) + + cond = np.zeros((batch, self._n_categories), dtype='float32') + mask = np.zeros((batch, self._n_discrete_columns), dtype='float32') + mask[np.arange(batch), discrete_column_id] = 1 + category_id_in_col = self._random_choice_prob_index(discrete_column_id) + category_id = (self._discrete_column_cond_st[discrete_column_id] + category_id_in_col) + cond[np.arange(batch), category_id] = 1 + + return cond, mask, discrete_column_id, category_id_in_col + + def sample_original_condvec(self, batch): + """Generate the conditional vector for generation use original frequency.""" + if self._n_discrete_columns == 0: + return None + + cond = np.zeros((batch, self._n_categories), dtype='float32') + + for i in range(batch): + row_idx = np.random.randint(0, len(self._data)) + col_idx = np.random.randint(0, self._n_discrete_columns) + matrix_st = self._discrete_column_matrix_st[col_idx] + matrix_ed = matrix_st + self._discrete_column_n_category[col_idx] + pick = np.argmax(self._data[row_idx, matrix_st:matrix_ed]) + cond[i, pick + self._discrete_column_cond_st[col_idx]] = 1 + + return cond + + def sample_data(self, n, col, opt): + """Sample data from original training data satisfying the sampled conditional vector. + + Returns: + n rows of matrix data. + """ + if col is None: + idx = np.random.randint(len(self._data), size=n) + return self._data[idx] + + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self._rid_by_cat_cols[c][o])) + + return self._data[idx] + + def dim_cond_vec(self): + """Return the total number of categories.""" + return self._n_categories + + def generate_cond_from_condition_column_info(self, condition_info, batch): + """Generate the condition vector.""" + vec = np.zeros((batch, self._n_categories), dtype='float32') + id_ = self._discrete_column_matrix_st[condition_info['discrete_column_id']] + id_ += condition_info['value_id'] + vec[:, id_] = 1 + return vec diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..06cfd128247f187be963c4b8c26067b06a02cbce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py @@ -0,0 +1,217 @@ +"""DataTransformer module.""" + +from collections import namedtuple + +import numpy as np +import pandas as pd +from rdt.transformers import BayesGMMTransformer, OneHotEncodingTransformer + +SpanInfo = namedtuple('SpanInfo', ['dim', 'activation_fn']) +ColumnTransformInfo = namedtuple( + 'ColumnTransformInfo', [ + 'column_name', 'column_type', 'transform', 'output_info', 'output_dimensions' + ] +) + + +class DataTransformer(object): + """Data Transformer. + + Model continuous columns with a BayesianGMM and normalized to a scalar [0, 1] and a vector. + Discrete columns are encoded using a scikit-learn OneHotEncoder. + """ + + def __init__(self, max_clusters=10, weight_threshold=0.005): + """Create a data transformer. + + Args: + max_clusters (int): + Maximum number of Gaussian distributions in Bayesian GMM. + weight_threshold (float): + Weight threshold for a Gaussian distribution to be kept. + """ + self._max_clusters = max_clusters + self._weight_threshold = weight_threshold + + def _fit_continuous(self, data): + """Train Bayesian GMM for continuous columns. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + gm = BayesGMMTransformer(max_clusters=min(len(data), 10)) + gm.fit(data, [column_name]) + num_components = sum(gm.valid_component_indicator) + + return ColumnTransformInfo( + column_name=column_name, column_type='continuous', transform=gm, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(num_components, 'softmax')], + output_dimensions=1 + num_components) + + def _fit_discrete(self, data): + """Fit one hot encoder for discrete column. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + ohe = OneHotEncodingTransformer() + ohe.fit(data, [column_name]) + num_categories = len(ohe.dummies) + + return ColumnTransformInfo( + column_name=column_name, column_type='discrete', transform=ohe, + output_info=[SpanInfo(num_categories, 'softmax')], + output_dimensions=num_categories) + + def fit(self, raw_data, discrete_columns=()): + """Fit the ``DataTransformer``. + + Fits a ``BayesGMMTransformer`` for continuous columns and a + ``OneHotEncodingTransformer`` for discrete columns. + + This step also counts the #columns in matrix data and span information. + """ + self.output_info_list = [] + self.output_dimensions = 0 + self.dataframe = True + + if not isinstance(raw_data, pd.DataFrame): + self.dataframe = False + # work around for RDT issue #328 Fitting with numerical column names fails + discrete_columns = [str(column) for column in discrete_columns] + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + self._column_raw_dtypes = raw_data.infer_objects().dtypes + self._column_transform_info_list = [] + for column_name in raw_data.columns: + if column_name in discrete_columns: + column_transform_info = self._fit_discrete(raw_data[[column_name]]) + else: + column_transform_info = self._fit_continuous(raw_data[[column_name]]) + + self.output_info_list.append(column_transform_info.output_info) + self.output_dimensions += column_transform_info.output_dimensions + self._column_transform_info_list.append(column_transform_info) + + def _transform_continuous(self, column_transform_info, data): + column_name = data.columns[0] + data.loc[:, column_name] = data[column_name].to_numpy().flatten() + gm = column_transform_info.transform + transformed = gm.transform(data, [column_name]) + + # Converts the transformed data to the appropriate output format. + # The first column (ending in '.normalized') stays the same, + # but the lable encoded column (ending in '.component') is one hot encoded. + output = np.zeros((len(transformed), column_transform_info.output_dimensions)) + output[:, 0] = transformed[f'{column_name}.normalized'].to_numpy() + index = transformed[f'{column_name}.component'].to_numpy().astype(int) + output[np.arange(index.size), index + 1] = 1.0 + + return output + + def _transform_discrete(self, column_transform_info, data): + ohe = column_transform_info.transform + return ohe.transform(data).to_numpy() + + def transform(self, raw_data): + """Take raw data and output a matrix data.""" + if not isinstance(raw_data, pd.DataFrame): + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + column_data_list = [] + for column_transform_info in self._column_transform_info_list: + column_name = column_transform_info.column_name + data = raw_data[[column_name]] + if column_transform_info.column_type == 'continuous': + column_data_list.append(self._transform_continuous(column_transform_info, data)) + else: + column_data_list.append(self._transform_discrete(column_transform_info, data)) + + return np.concatenate(column_data_list, axis=1).astype(float) + + def _inverse_transform_continuous(self, column_transform_info, column_data, sigmas, st): + gm = column_transform_info.transform + data = pd.DataFrame(column_data[:, :2], columns=list(gm.get_output_types())) + data.iloc[:, 1] = np.argmax(column_data[:, 1:], axis=1) + if sigmas is not None: + selected_normalized_value = np.random.normal(data.iloc[:, 0], sigmas[st]) + data.iloc[:, 0] = selected_normalized_value + + return gm.reverse_transform(data, [column_transform_info.column_name]) + + def _inverse_transform_discrete(self, column_transform_info, column_data): + ohe = column_transform_info.transform + data = pd.DataFrame(column_data, columns=list(ohe.get_output_types())) + return ohe.reverse_transform(data)[column_transform_info.column_name] + + def inverse_transform(self, data, sigmas=None): + """Take matrix data and output raw data. + + Output uses the same type as input to the transform function. + Either np array or pd dataframe. + """ + st = 0 + recovered_column_data_list = [] + column_names = [] + for column_transform_info in self._column_transform_info_list: + dim = column_transform_info.output_dimensions + column_data = data[:, st:st + dim] + if column_transform_info.column_type == 'continuous': + recovered_column_data = self._inverse_transform_continuous( + column_transform_info, column_data, sigmas, st) + else: + recovered_column_data = self._inverse_transform_discrete( + column_transform_info, column_data) + + recovered_column_data_list.append(recovered_column_data) + column_names.append(column_transform_info.column_name) + st += dim + + recovered_data = np.column_stack(recovered_column_data_list) + recovered_data = (pd.DataFrame(recovered_data, columns=column_names) + .astype(self._column_raw_dtypes)) + if not self.dataframe: + recovered_data = recovered_data.to_numpy() + + return recovered_data + + def convert_column_name_value_to_id(self, column_name, value): + """Get the ids of the given `column_name`.""" + discrete_counter = 0 + column_id = 0 + for column_transform_info in self._column_transform_info_list: + if column_transform_info.column_name == column_name: + break + if column_transform_info.column_type == 'discrete': + discrete_counter += 1 + + column_id += 1 + + else: + raise ValueError(f"The column_name `{column_name}` doesn't exist in the data.") + + ohe = column_transform_info.transform + data = pd.DataFrame([value], columns=[column_transform_info.column_name]) + one_hot = ohe.transform(data).to_numpy()[0] + if sum(one_hot) == 0: + raise ValueError(f"The value `{value}` doesn't exist in the column `{column_name}`.") + + return { + 'discrete_column_id': discrete_counter, + 'column_id': column_id, + 'value_id': np.argmax(one_hot) + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py new file mode 100644 index 0000000000000000000000000000000000000000..a99f90aa576a31f07ebfa7081ee6e4e7817ed02f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py @@ -0,0 +1,10 @@ +"""Demo module.""" + +import pandas as pd + +DEMO_URL = 'http://ctgan-data.s3.amazonaws.com/census.csv.gz' + + +def load_demo(): + """Load the demo.""" + return pd.read_csv(DEMO_URL, compression='gzip') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..2f67c77a7892dad39ae429b80b46e8672a3c69df --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py @@ -0,0 +1,16 @@ +"""Synthesizers module.""" + +from .ctgan import CTGANSynthesizer +from .tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer' +) + + +def get_all_synthesizers(): + return { + name: globals()[name] + for name in __all__ + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py new file mode 100644 index 0000000000000000000000000000000000000000..5afb66d4a6d2700c27516d8a322ab7b30a9356eb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py @@ -0,0 +1,105 @@ +"""BaseSynthesizer module.""" + +import contextlib + +import numpy as np +import torch + + +@contextlib.contextmanager +def set_random_states(random_state, set_model_random_state): + """Context manager for managing the random state. + + Args: + random_state (int or tuple): + The random seed or a tuple of (numpy.random.RandomState, torch.Generator). + set_model_random_state (function): + Function to set the random state on the model. + """ + original_np_state = np.random.get_state() + original_torch_state = torch.get_rng_state() + + random_np_state, random_torch_state = random_state + + np.random.set_state(random_np_state.get_state()) + torch.set_rng_state(random_torch_state.get_state()) + + try: + yield + finally: + current_np_state = np.random.RandomState() + current_np_state.set_state(np.random.get_state()) + current_torch_state = torch.Generator() + current_torch_state.set_state(torch.get_rng_state()) + set_model_random_state((current_np_state, current_torch_state)) + + np.random.set_state(original_np_state) + torch.set_rng_state(original_torch_state) + + +def random_state(function): + """Set the random state before calling the function. + + Args: + function (Callable): + The function to wrap around. + """ + def wrapper(self, *args, **kwargs): + if self.random_states is None: + return function(self, *args, **kwargs) + + else: + with set_random_states(self.random_states, self.set_random_state): + return function(self, *args, **kwargs) + + return wrapper + + +class BaseSynthesizer: + """Base class for all default synthesizers of ``CTGAN``. + + This should contain the save/load methods. + """ + + random_states = None + + def save(self, path): + """Save the model in the passed `path`.""" + device_backup = self._device + self.set_device(torch.device('cpu')) + torch.save(self, path) + self.set_device(device_backup) + + @classmethod + def load(cls, path): + """Load the model stored in the passed `path`.""" + device = torch.device('cuda:0' if torch.cuda.is_available() else 'cpu') + model = torch.load(path) + model.set_device(device) + return model + + def set_random_state(self, random_state): + """Set the random state. + + Args: + random_state (int, tuple, or None): + Either a tuple containing the (numpy.random.RandomState, torch.Generator) + or an int representing the random seed to use for both random states. + """ + if random_state is None: + self.random_states = random_state + elif isinstance(random_state, int): + self.random_states = ( + np.random.RandomState(seed=random_state), + torch.Generator().manual_seed(random_state), + ) + elif ( + isinstance(random_state, tuple) and + isinstance(random_state[0], np.random.RandomState) and + isinstance(random_state[1], torch.Generator) + ): + self.random_states = random_state + else: + raise TypeError( + f'`random_state` {random_state} expected to be an int or a tuple of ' + '(`np.random.RandomState`, `torch.Generator`)') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..e4253e87d6349cd2bccb669f46146edfd61e23a8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py @@ -0,0 +1,482 @@ +"""CTGANSynthesizer module.""" + +import warnings + +import numpy as np +import pandas as pd +import torch +from packaging import version +from torch import optim +from torch.nn import BatchNorm1d, Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, functional + +from ..data_sampler import DataSampler +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Discriminator(Module): + """Discriminator for the CTGANSynthesizer.""" + + def __init__(self, input_dim, discriminator_dim, pac=10): + super(Discriminator, self).__init__() + dim = input_dim * pac + self.pac = pac + self.pacdim = dim + seq = [] + for item in list(discriminator_dim): + seq += [Linear(dim, item), LeakyReLU(0.2), Dropout(0.5)] + dim = item + + seq += [Linear(dim, 1)] + self.seq = Sequential(*seq) + + def calc_gradient_penalty(self, real_data, fake_data, device='cpu', pac=10, lambda_=10): + """Compute the gradient penalty.""" + alpha = torch.rand(real_data.size(0) // pac, 1, 1, device=device) + alpha = alpha.repeat(1, pac, real_data.size(1)) + alpha = alpha.view(-1, real_data.size(1)) + + interpolates = alpha * real_data + ((1 - alpha) * fake_data) + + disc_interpolates = self(interpolates) + + gradients = torch.autograd.grad( + outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size(), device=device), + create_graph=True, retain_graph=True, only_inputs=True + )[0] + + gradients_view = gradients.view(-1, pac * real_data.size(1)).norm(2, dim=1) - 1 + gradient_penalty = ((gradients_view) ** 2).mean() * lambda_ + + return gradient_penalty + + def forward(self, input_): + """Apply the Discriminator to the `input_`.""" + assert input_.size()[0] % self.pac == 0 + return self.seq(input_.view(-1, self.pacdim)) + + +class Residual(Module): + """Residual layer for the CTGANSynthesizer.""" + + def __init__(self, i, o): + super(Residual, self).__init__() + self.fc = Linear(i, o) + self.bn = BatchNorm1d(o) + self.relu = ReLU() + + def forward(self, input_): + """Apply the Residual layer to the `input_`.""" + out = self.fc(input_) + out = self.bn(out) + out = self.relu(out) + return torch.cat([out, input_], dim=1) + + +class Generator(Module): + """Generator for the CTGANSynthesizer.""" + + def __init__(self, embedding_dim, generator_dim, data_dim): + super(Generator, self).__init__() + dim = embedding_dim + seq = [] + for item in list(generator_dim): + seq += [Residual(dim, item)] + dim += item + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + + def forward(self, input_): + """Apply the Generator to the `input_`.""" + data = self.seq(input_) + return data + + +class CTGANSynthesizer(BaseSynthesizer): + """Conditional Table GAN Synthesizer. + + This is the core class of the CTGAN project, where the different components + are orchestrated together. + For more details about the process, please check the [Modeling Tabular data using + Conditional GAN](https://arxiv.org/abs/1907.00503) paper. + + Args: + embedding_dim (int): + Size of the random sample passed to the Generator. Defaults to 128. + generator_dim (tuple or list of ints): + Size of the output samples for each one of the Residuals. A Residual Layer + will be created for each one of the values provided. Defaults to (256, 256). + discriminator_dim (tuple or list of ints): + Size of the output samples for each one of the Discriminator Layers. A Linear Layer + will be created for each one of the values provided. Defaults to (256, 256). + generator_lr (float): + Learning rate for the generator. Defaults to 2e-4. + generator_decay (float): + Generator weight decay for the Adam Optimizer. Defaults to 1e-6. + discriminator_lr (float): + Learning rate for the discriminator. Defaults to 2e-4. + discriminator_decay (float): + Discriminator weight decay for the Adam Optimizer. Defaults to 1e-6. + batch_size (int): + Number of data samples to process in each step. + discriminator_steps (int): + Number of discriminator updates to do for each generator update. + From the WGAN paper: https://arxiv.org/abs/1701.07875. WGAN paper + default is 5. Default used is 1 to match original CTGAN implementation. + log_frequency (boolean): + Whether to use log frequency of categorical levels in conditional + sampling. Defaults to ``True``. + verbose (boolean): + Whether to have print statements for progress results. Defaults to ``False``. + epochs (int): + Number of training epochs. Defaults to 300. + pac (int): + Number of samples to group together when applying the discriminator. + Defaults to 10. + cuda (bool): + Whether to attempt to use cuda for GPU computation. + If this is False or CUDA is not available, CPU will be used. + Defaults to ``True``. + """ + + def __init__(self, embedding_dim=128, generator_dim=(256, 256), discriminator_dim=(256, 256), + generator_lr=2e-4, generator_decay=1e-6, discriminator_lr=2e-4, + discriminator_decay=1e-6, batch_size=500, discriminator_steps=1, + log_frequency=True, verbose=False, epochs=300, pac=10, cuda=True): + + assert batch_size % 2 == 0 + + self._embedding_dim = embedding_dim + self._generator_dim = generator_dim + self._discriminator_dim = discriminator_dim + + self._generator_lr = generator_lr + self._generator_decay = generator_decay + self._discriminator_lr = discriminator_lr + self._discriminator_decay = discriminator_decay + + self._batch_size = batch_size + self._discriminator_steps = discriminator_steps + self._log_frequency = log_frequency + self._verbose = verbose + self._epochs = epochs + self.pac = pac + + if not cuda or not torch.cuda.is_available(): + device = 'cpu' + elif isinstance(cuda, str): + device = cuda + else: + device = 'cuda' + + self._device = torch.device(device) + + self._transformer = None + self._data_sampler = None + self._generator = None + + @staticmethod + def _gumbel_softmax(logits, tau=1, hard=False, eps=1e-10, dim=-1): + """Deals with the instability of the gumbel_softmax for older versions of torch. + + For more details about the issue: + https://drive.google.com/file/d/1AA5wPfZ1kquaRtVruCd6BiYZGcDeNxyP/view?usp=sharing + + Args: + logits […, num_features]: + Unnormalized log probabilities + tau: + Non-negative scalar temperature + hard (bool): + If True, the returned samples will be discretized as one-hot vectors, + but will be differentiated as if it is the soft sample in autograd + dim (int): + A dimension along which softmax will be computed. Default: -1. + + Returns: + Sampled tensor of same shape as logits from the Gumbel-Softmax distribution. + """ + if version.parse(torch.__version__) < version.parse('1.2.0'): + for i in range(10): + transformed = functional.gumbel_softmax(logits, tau=tau, hard=hard, + eps=eps, dim=dim) + if not torch.isnan(transformed).any(): + return transformed + raise ValueError('gumbel_softmax returning NaN.') + + return functional.gumbel_softmax(logits, tau=tau, hard=hard, eps=eps, dim=dim) + + def _apply_activate(self, data): + """Apply proper activation function to the output of the generator.""" + data_t = [] + st = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if span_info.activation_fn == 'tanh': + ed = st + span_info.dim + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif span_info.activation_fn == 'softmax': + ed = st + span_info.dim + transformed = self._gumbel_softmax(data[:, st:ed], tau=0.2) + data_t.append(transformed) + st = ed + else: + raise ValueError(f'Unexpected activation function {span_info.activation_fn}.') + + return torch.cat(data_t, dim=1) + + def _cond_loss(self, data, c, m): + """Compute the cross entropy loss on the fixed discrete column.""" + loss = [] + st = 0 + st_c = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if len(column_info) != 1 or span_info.activation_fn != 'softmax': + # not discrete column + st += span_info.dim + else: + ed = st + span_info.dim + ed_c = st_c + span_info.dim + tmp = functional.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none' + ) + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) # noqa: PD013 + + return (loss * m).sum() / data.size()[0] + + def _validate_discrete_columns(self, train_data, discrete_columns): + """Check whether ``discrete_columns`` exists in ``train_data``. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + if isinstance(train_data, pd.DataFrame): + invalid_columns = set(discrete_columns) - set(train_data.columns) + elif isinstance(train_data, np.ndarray): + invalid_columns = [] + for column in discrete_columns: + if column < 0 or column >= train_data.shape[1]: + invalid_columns.append(column) + else: + raise TypeError('``train_data`` should be either pd.DataFrame or np.array.') + + if invalid_columns: + raise ValueError(f'Invalid columns found: {invalid_columns}') + + @random_state + def fit(self, train_data, discrete_columns=(), epochs=None): + """Fit the CTGAN Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self._validate_discrete_columns(train_data, discrete_columns) + + if epochs is None: + epochs = self._epochs + else: + warnings.warn( + ('`epochs` argument in `fit` method has been deprecated and will be removed ' + 'in a future version. Please pass `epochs` to the constructor instead'), + DeprecationWarning + ) + + self._transformer = DataTransformer() + self._transformer.fit(train_data, discrete_columns) + + train_data = self._transformer.transform(train_data) + + self._data_sampler = DataSampler( + train_data, + self._transformer.output_info_list, + self._log_frequency) + + data_dim = self._transformer.output_dimensions + + self._generator = Generator( + self._embedding_dim + self._data_sampler.dim_cond_vec(), + self._generator_dim, + data_dim + ).to(self._device) + + discriminator = Discriminator( + data_dim + self._data_sampler.dim_cond_vec(), + self._discriminator_dim, + pac=self.pac + ).to(self._device) + + optimizerG = optim.Adam( + self._generator.parameters(), lr=self._generator_lr, betas=(0.5, 0.9), + weight_decay=self._generator_decay + ) + + optimizerD = optim.Adam( + discriminator.parameters(), lr=self._discriminator_lr, + betas=(0.5, 0.9), weight_decay=self._discriminator_decay + ) + + mean = torch.zeros(self._batch_size, self._embedding_dim, device=self._device) + std = mean + 1 + + print('CTGAN training') + steps_per_epoch = max(len(train_data) // self._batch_size, 1) + for i in range(epochs): + for n in range(self._discriminator_steps): + fakez = torch.normal(mean=mean, std=std) + + condvec = self._data_sampler.sample_condvec(self._batch_size) + if condvec is None: + c1, m1, col, opt = None, None, None, None + real = self._data_sampler.sample_data(self._batch_size, col, opt) + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + perm = np.arange(self._batch_size) + np.random.shuffle(perm) + real = self._data_sampler.sample_data( + self._batch_size, col[perm], opt[perm]) + c2 = c1[perm] + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + real = torch.from_numpy(real.astype('float32')).to(self._device) + + if c1 is not None: + fake_cat = torch.cat([fakeact, c1], dim=1) + real_cat = torch.cat([real, c2], dim=1) + else: + real_cat = real + fake_cat = fakeact + + y_fake = discriminator(fake_cat) + y_real = discriminator(real_cat) + + pen = discriminator.calc_gradient_penalty( + real_cat, fake_cat, self._device, self.pac) + loss_d = -(torch.mean(y_real) - torch.mean(y_fake)) + + optimizerD.zero_grad() + pen.backward(retain_graph=True) + loss_d.backward() + optimizerD.step() + + fakez = torch.normal(mean=mean, std=std) + condvec = self._data_sampler.sample_condvec(self._batch_size) + + if condvec is None: + c1, m1, col, opt = None, None, None, None + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + if c1 is not None: + y_fake = discriminator(torch.cat([fakeact, c1], dim=1)) + else: + y_fake = discriminator(fakeact) + + if condvec is None: + cross_entropy = 0 + else: + cross_entropy = self._cond_loss(fake, c1, m1) + + loss_g = -torch.mean(y_fake) + cross_entropy + + optimizerG.zero_grad() + loss_g.backward() + optimizerG.step() + + if self._verbose and (i + 1) % 1000 == 0: + print(f'Epoch {i+1}, Loss G: {loss_g.detach().cpu(): .4f},' # noqa: T001 + f'Loss D: {loss_d.detach().cpu(): .4f}', + flush=True) + + @random_state + def sample(self, n, condition_column=None, condition_value=None): + """Sample data similar to the training data. + + Choosing a condition_column and condition_value will increase the probability of the + discrete condition_value happening in the condition_column. + + Args: + n (int): + Number of rows to sample. + condition_column (string): + Name of a discrete column. + condition_value (string): + Name of the category in the condition_column which we wish to increase the + probability of happening. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + if condition_column is not None and condition_value is not None: + condition_info = self._transformer.convert_column_name_value_to_id( + condition_column, condition_value) + global_condition_vec = self._data_sampler.generate_cond_from_condition_column_info( + condition_info, self._batch_size) + else: + global_condition_vec = None + + steps = n // self._batch_size + 1 + data = [] + for i in range(steps): + mean = torch.zeros(self._batch_size, self._embedding_dim) + std = mean + 1 + fakez = torch.normal(mean=mean, std=std).to(self._device) + + if global_condition_vec is not None: + condvec = global_condition_vec.copy() + else: + condvec = self._data_sampler.sample_original_condvec(self._batch_size) + + if condvec is None: + pass + else: + c1 = condvec + c1 = torch.from_numpy(c1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:n] + + return self._transformer.inverse_transform(data) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + if self._generator is not None: + self._generator.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..1baa3f38a8157b80fb866c205491616543fb0470 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py @@ -0,0 +1,218 @@ +"""TVAESynthesizer module.""" + +import numpy as np +import torch +from torch.nn import Linear, Module, Parameter, ReLU, Sequential +from torch.nn.functional import cross_entropy +from torch.optim import Adam +from torch.utils.data import DataLoader, TensorDataset + +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Encoder(Module): + """Encoder for the TVAESynthesizer. + + Args: + data_dim (int): + Dimensions of the data. + compress_dims (tuple or list of ints): + Size of each hidden layer. + embedding_dim (int): + Size of the output vector. + """ + + def __init__(self, data_dim, compress_dims, embedding_dim): + super(Encoder, self).__init__() + dim = data_dim + seq = [] + for item in list(compress_dims): + seq += [ + Linear(dim, item), + ReLU() + ] + dim = item + + self.seq = Sequential(*seq) + self.fc1 = Linear(dim, embedding_dim) + self.fc2 = Linear(dim, embedding_dim) + + def forward(self, input_): + """Encode the passed `input_`.""" + feature = self.seq(input_) + mu = self.fc1(feature) + logvar = self.fc2(feature) + std = torch.exp(0.5 * logvar) + return mu, std, logvar + + +class Decoder(Module): + """Decoder for the TVAESynthesizer. + + Args: + embedding_dim (int): + Size of the input vector. + decompress_dims (tuple or list of ints): + Size of each hidden layer. + data_dim (int): + Dimensions of the data. + """ + + def __init__(self, embedding_dim, decompress_dims, data_dim): + super(Decoder, self).__init__() + dim = embedding_dim + seq = [] + for item in list(decompress_dims): + seq += [Linear(dim, item), ReLU()] + dim = item + + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + self.sigma = Parameter(torch.ones(data_dim) * 0.1) + + def forward(self, input_): + """Decode the passed `input_`.""" + return self.seq(input_), self.sigma + + +def _loss_function(recon_x, x, sigmas, mu, logvar, output_info, factor): + st = 0 + loss = [] + for column_info in output_info: + for span_info in column_info: + if span_info.activation_fn != 'softmax': + ed = st + span_info.dim + std = sigmas[st] + eq = x[:, st] - torch.tanh(recon_x[:, st]) + loss.append((eq ** 2 / 2 / (std ** 2)).sum()) + loss.append(torch.log(std) * x.size()[0]) + st = ed + + else: + ed = st + span_info.dim + loss.append(cross_entropy( + recon_x[:, st:ed], torch.argmax(x[:, st:ed], dim=-1), reduction='sum')) + st = ed + + assert st == recon_x.size()[1] + KLD = -0.5 * torch.sum(1 + logvar - mu**2 - logvar.exp()) + return sum(loss) * factor / x.size()[0], KLD / x.size()[0] + + +class TVAESynthesizer(BaseSynthesizer): + """TVAESynthesizer.""" + + def __init__( + self, + embedding_dim=128, + compress_dims=(128, 128), + decompress_dims=(128, 128), + l2scale=1e-5, + batch_size=500, + epochs=300, + lr=1e-3, + loss_factor=2, + device="cuda:0" + ): + self.embedding_dim = embedding_dim + self.compress_dims = compress_dims + self.decompress_dims = decompress_dims + + self.lr = lr + self.l2scale = l2scale + self.batch_size = batch_size + self.loss_factor = loss_factor + self.epochs = epochs + + + self._device = torch.device(device) + + @random_state + def fit(self, train_data, discrete_columns=()): + """Fit the TVAE Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self.transformer = DataTransformer() + self.transformer.fit(train_data, discrete_columns) + train_data = self.transformer.transform(train_data) + dataset = TensorDataset(torch.from_numpy(train_data.astype('float32'))) + loader = DataLoader(dataset, batch_size=self.batch_size, shuffle=True, drop_last=False) + + data_dim = self.transformer.output_dimensions + encoder = Encoder(data_dim, self.compress_dims, self.embedding_dim).to(self._device) + self.decoder = Decoder(self.embedding_dim, self.decompress_dims, data_dim).to(self._device) + optimizerAE = Adam( + list(encoder.parameters()) + list(self.decoder.parameters()), + lr=self.lr, + weight_decay=self.l2scale) + data_iter = iter(loader) + print('Training:') + for i in range(self.epochs): + try: + data = next(data_iter) + except: + data_iter = iter(loader) + data = next(data_iter) + + optimizerAE.zero_grad() + real = data[0].to(self._device) + mu, std, logvar = encoder(real) + eps = torch.randn_like(std) + emb = eps * std + mu + rec, sigmas = self.decoder(emb) + loss_1, loss_2 = _loss_function( + rec, real, sigmas, mu, logvar, + self.transformer.output_info_list, self.loss_factor + ) + loss = loss_1 + loss_2 + loss.backward() + optimizerAE.step() + self.decoder.sigma.data.clamp_(0.01, 1.0) + if (i + 1) % 1000 == 0: + print(f"{i + 1}/{self.epochs} {loss}", flush=True) + + @random_state + def sample(self, samples, seed=0): + """Sample data similar to the training data. + + Args: + samples (int): + Number of rows to sample. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + + torch.cuda.manual_seed(seed) + torch.manual_seed(seed) + + self.decoder.eval() + + sample_batch_size = 8092 + steps = samples // sample_batch_size + 1 + data = [] + for _ in range(steps): + mean = torch.zeros(sample_batch_size, self.embedding_dim) + std = mean + 1 + noise = torch.normal(mean=mean, std=std).to(self._device) + fake, sigmas = self.decoder(noise) + fake = torch.tanh(fake) + data.append(fake.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:samples] + return self.transformer.inverse_transform(data, sigmas.detach().cpu().numpy()) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + self.decoder.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg new file mode 100644 index 0000000000000000000000000000000000000000..8398eee0de75e378fa157456b8594f9ec383c45c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg @@ -0,0 +1,59 @@ +[bumpversion] +current_version = 0.5.2.dev0 +commit = True +tag = True +parse = (?P\d+)\.(?P\d+)\.(?P\d+)(\.(?P[a-z]+)(?P\d+))? +serialize = + {major}.{minor}.{patch}.{release}{candidate} + {major}.{minor}.{patch} + +[bumpversion:part:release] +optional_value = release +first_value = dev +values = + dev + release + +[bumpversion:part:candidate] + +[bumpversion:file:setup.py] +search = version='{current_version}' +replace = version='{new_version}' + +[bumpversion:file:ctgan/__init__.py] +search = __version__ = '{current_version}' +replace = __version__ = '{new_version}' + +[bumpversion:file:conda/meta.yaml] +search = version = '{current_version}' +replace = version = '{new_version}' + +[bdist_wheel] +universal = 1 + +[flake8] +convention = google +max-line-length = 99 +exclude = docs, .tox, .git, __pycache__, .ipynb_checkpoints +extend-ignore = D107, # Missing docstring in __init__ + D407, # Missing dashed underline after section + D417, # Missing argument descriptions in the docstring + SFS3, # String literal formatting using f-string. + VNE001 # Single letter variable names are not allowed +per-file-ignores = + ctgan/data.py:T001 + +[isort] +include_trailing_comment = True +line_length = 99 +lines_between_types = 0 +multi_line_output = 4 +not_skip = __init__.py +use_parentheses = True + +[aliases] +test = pytest + +[tool:pytest] +collect_ignore = ['setup.py'] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.py new file mode 100644 index 0000000000000000000000000000000000000000..83d973eb603ce5a4f4dc31f3bac459eeabdd1ec5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/setup.py @@ -0,0 +1,119 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""The setup script.""" + +from setuptools import find_packages, setup + +with open('README.md', encoding='utf-8') as readme_file: + readme = readme_file.read() + +with open('HISTORY.md', encoding='utf-8') as history_file: + history = history_file.read() + +install_requires = [ + 'packaging>=20,<22', + "numpy>=1.18.0,<1.20.0;python_version<'3.7'", + "numpy>=1.20.0,<2;python_version>='3.7'", + 'pandas>=1.1.3,<2', + 'scikit-learn>=0.24,<2', + 'torch>=1.8.0,<2', + 'torchvision>=0.9.0,<1', + 'rdt>=0.6.2,<0.7', +] + +setup_requires = [ + 'pytest-runner>=2.11.1', +] + +tests_require = [ + 'pytest>=3.4.2', + 'pytest-rerunfailures>=9.1.1,<10', + 'pytest-cov>=2.6.0', +] + +development_requires = [ + # general + 'pip>=9.0.1', + 'bumpversion>=0.5.3,<0.6', + 'watchdog>=0.8.3,<0.11', + + # style check + 'flake8>=3.7.7,<4', + 'isort>=4.3.4,<5', + 'dlint>=0.11.0,<0.12', # code security addon for flake8 + 'flake8-debugger>=4.0.0,<4.1', + 'flake8-mock>=0.3,<0.4', + 'flake8-mutable>=1.2.0,<1.3', + 'flake8-absolute-import>=1.0,<2', + 'flake8-multiline-containers>=0.0.18,<0.1', + 'flake8-print>=4.0.0,<4.1', + 'flake8-quotes>=3.3.0,<4', + 'flake8-fixme>=1.1.1,<1.2', + 'flake8-expression-complexity>=0.0.9,<0.1', + 'flake8-eradicate>=1.1.0,<1.2', + 'flake8-builtins>=1.5.3,<1.6', + 'flake8-variables-names>=0.0.4,<0.1', + 'pandas-vet>=0.2.2,<0.3', + 'flake8-comprehensions>=3.6.1,<3.7', + 'dlint>=0.11.0,<0.12', + 'flake8-docstrings>=1.5.0,<2', + 'flake8-sfs>=0.0.3,<0.1', + 'flake8-pytest-style>=1.5.0,<2', + + # fix style issues + 'autoflake>=1.1,<2', + 'autopep8>=1.4.3,<1.6', + + # distribute on PyPI + 'twine>=1.10.0,<4', + 'wheel>=0.30.0', + + # Advanced testing + 'coverage>=4.5.1,<6', + 'tox>=2.9.1,<4', + + 'invoke', +] + +setup( + author='MIT Data To AI Lab', + author_email='dailabmit@gmail.com', + classifiers=[ + 'Development Status :: 2 - Pre-Alpha', + 'Intended Audience :: Developers', + 'License :: OSI Approved :: MIT License', + 'Natural Language :: English', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + ], + description='Conditional GAN for Tabular Data', + entry_points={ + 'console_scripts': [ + 'ctgan=ctgan.__main__:main' + ], + }, + extras_require={ + 'test': tests_require, + 'dev': development_requires + tests_require, + }, + install_package_data=True, + install_requires=install_requires, + license='MIT license', + long_description=readme + '\n\n' + history, + long_description_content_type='text/markdown', + include_package_data=True, + keywords='ctgan CTGAN', + name='ctgan', + packages=find_packages(include=['ctgan', 'ctgan.*']), + python_requires='>=3.6,<3.10', + setup_requires=setup_requires, + test_suite='tests', + tests_require=tests_require, + url='https://github.com/sdv-dev/CTGAN', + version='0.5.2.dev0', + zip_safe=False, +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tasks.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tasks.py new file mode 100644 index 0000000000000000000000000000000000000000..78730cea28cec928ff175364db655f10abe6143e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tasks.py @@ -0,0 +1,121 @@ +import glob +import operator +import os +import re +import platform +import shutil +import stat +from pathlib import Path + +from invoke import task + +COMPARISONS = { + '>=': operator.ge, + '>': operator.gt, + '<': operator.lt, + '<=': operator.le +} + + +@task +def check_dependencies(c): + c.run('python -m pip check') + + +@task +def unit(c): + c.run('python -m pytest ./tests/unit --cov=ctgan --cov-report=xml') + + +@task +def integration(c): + c.run('python -m pytest ./tests/integration --reruns 3') + + +@task +def readme(c): + test_path = Path('tests/readme_test') + if test_path.exists() and test_path.is_dir(): + shutil.rmtree(test_path) + + cwd = os.getcwd() + os.makedirs(test_path, exist_ok=True) + shutil.copy('README.md', test_path / 'README.md') + os.chdir(test_path) + c.run('rundoc run --single-session python3 -t python3 README.md') + os.chdir(cwd) + shutil.rmtree(test_path) + + +def _validate_python_version(line): + python_version_match = re.search(r"python_version(<=?|>=?)\'(\d\.?)+\'", line) + if python_version_match: + python_version = python_version_match.group(0) + comparison = re.search(r'(>=?|<=?)', python_version).group(0) + version_number = python_version.split(comparison)[-1].replace("'", "") + comparison_function = COMPARISONS[comparison] + return comparison_function(platform.python_version(), version_number) + + return True + + +@task +def install_minimum(c): + with open('setup.py', 'r') as setup_py: + lines = setup_py.read().splitlines() + + versions = [] + started = False + for line in lines: + if started: + if line == ']': + started = False + continue + + line = line.strip() + if _validate_python_version(line): + requirement = re.match(r'[^>]*', line).group(0) + requirement = re.sub(r"""['",]""", '', requirement) + version = re.search(r'>=?[^(,|#)]*', line).group(0) + if version: + version = re.sub(r'>=?', '==', version) + version = re.sub(r"""['",]""", '', version) + requirement += version + + versions.append(requirement) + + elif (line.startswith('install_requires = [') or + line.startswith('pomegranate_requires = [')): + started = True + + c.run(f'python -m pip install {" ".join(versions)}') + + +@task +def minimum(c): + install_minimum(c) + check_dependencies(c) + unit(c) + integration(c) + + +@task +def lint(c): + check_dependencies(c) + c.run('flake8 ctgan') + c.run('flake8 tests --ignore=D101') + c.run('isort -c --recursive ctgan tests') + + +def remove_readonly(func, path, _): + "Clear the readonly bit and reattempt the removal" + os.chmod(path, stat.S_IWRITE) + func(path) + + +@task +def rmdir(c, path): + try: + shutil.rmtree(path, onerror=remove_readonly) + except PermissionError: + pass diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a750d3dabc716a49fb722dbbb87e7a2120fc5fd4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py @@ -0,0 +1,275 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for ctgan. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import tempfile as tf + +import numpy as np +import pandas as pd +import pytest + +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def test_ctgan_no_categoricals(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000) + }) + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, []) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 1) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous'} + + +def test_ctgan_dataframe(): + """Test the CTGANSynthesizer when passed a dataframe.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_ctgan_numpy(): + """Test the CTGANSynthesizer when passed a numpy array.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = [1] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data.to_numpy(), discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, np.ndarray) + assert set(np.unique(sampled[:, 1])) == {'a', 'b', 'c'} + + +def test_log_frequency(): + """Test the CTGANSynthesizer with no `log_frequency` set to False.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000), + 'discrete': np.repeat(['a', 'b', 'c'], [950, 25, 25]) + }) + + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] < 6500 + + ctgan = CTGANSynthesizer(log_frequency=False, epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] > 9000 + + +def test_categorical_nan(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(30), + # This must be a list (not a np.array) or NaN will be cast to a string. + 'discrete': [np.nan, 'b', 'c'] * 10 + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + + # since np.nan != np.nan, we need to be careful here + values = set(sampled['discrete'].unique()) + assert len(values) == 3 + assert any(pd.isna(x) for x in values) + assert {'b', 'c'}.issubset(values) + + +def test_synthesizer_sample(): + """Test the CTGANSynthesizer samples the correct datatype.""" + data = pd.DataFrame({ + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + samples = ctgan.sample(1000, 'discrete', 'a') + assert isinstance(samples, pd.DataFrame) + + +def test_save_load(): + """Test the CTGANSynthesizer load/save methods.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with tf.TemporaryDirectory() as temporary_directory: + ctgan.save(temporary_directory + 'test_tvae.pkl') + ctgan = CTGANSynthesizer.load(temporary_directory + 'test_tvae.pkl') + + sampled = ctgan.sample(1000) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_wrong_discrete_columns_dataframe(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['b', 'c'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match="Invalid columns found: {'.*', '.*'}"): + ctgan.fit(data, discrete_columns) + + +def test_wrong_discrete_columns_numpy(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = [0, 1] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: \[1\]'): + ctgan.fit(data.to_numpy(), discrete_columns) + + +def test_wrong_sampling_conditions(): + """Test the CTGANSynthesizer correctly crashes when passed incorrect sampling conditions.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with pytest.raises(ValueError, match="The column_name `cardinal` doesn't exist in the data."): + ctgan.sample(1, 'cardinal', "doesn't matter") + + with pytest.raises(ValueError): # noqa: RDT currently incorrectly raises a tuple instead of a string + ctgan.sample(1, 'discrete', 'd') + + +def test_fixed_random_seed(): + """Test the CTGANSynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + + # Run + ctgan.fit(data, discrete_columns) + sampled_random = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_0_0 = ctgan.sample(10) + sampled_0_1 = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_1_0 = ctgan.sample(10) + sampled_1_1 = ctgan.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) + + +# Below are CTGAN tests that should be implemented in the future +def test_continuous(): + """Test training the CTGAN synthesizer on a continuous dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using kstest: + # - uniform (assert p-value > 0.05) + # - gaussian (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical(): + """Test training the CTGAN synthesizer on a categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical_log_frequency(): + """Test training the CTGAN synthesizer on a small categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_mixed(): + """Test training the CTGAN synthesizer on a small mixed-type dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test_conditional(): + """Test training the CTGAN synthesizer and sampling conditioned on a categorical.""" + # verify that conditioning increases the likelihood of getting a sample with the specified + # categorical value + + +def test_batch_size_pack_size(): + """Test that if batch size is not a multiple of pack size, it raises a sane error.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..ab8c583e0dd11fee3e1ce3d5cd4ac8f0a847a192 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py @@ -0,0 +1,131 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for tvae. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import numpy as np +import pandas as pd +from sklearn import datasets + +from ctgan.synthesizers.tvae import TVAESynthesizer + + +def test_tvae(tmpdir): + """Test the TVAESynthesizer load/save methods.""" + iris = datasets.load_iris() + data = pd.DataFrame(iris.data, columns=iris.feature_names) + data['class'] = pd.Series(iris.target).map(iris.target_names.__getitem__) + + tvae = TVAESynthesizer(epochs=10) + tvae.fit(data, ['class']) + + path = str(tmpdir / 'test_tvae.pkl') + tvae.save(path) + tvae = TVAESynthesizer.load(path) + + sampled = tvae.sample(100) + + assert sampled.shape == (100, 5) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == set(data.columns) + assert set(sampled.dtypes) == set(data.dtypes) + + +def test_drop_last_false(): + """Test the TVAESynthesizer predicts the correct values.""" + data = pd.DataFrame({ + '1': ['a', 'b', 'c'] * 150, + '2': ['a', 'b', 'c'] * 150 + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data, ['1', '2']) + + sampled = tvae.sample(100) + correct = 0 + for _, row in sampled.iterrows(): + if row['1'] == row['2']: + correct += 1 + + assert correct >= 95 + + +# TVAE tests that should be implemented in the future. +def test_continuous(): + """Test training the TVAE synthesizer on a small continuous dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest. + + +def test_categorical(): + """Test training the TVAE synthesizer on a small categorical dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a cstest. + + +def test_mixed(): + """Test training the TVAE synthesizer on a small mixed-type dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test__loss_function(): + """Test the TVAESynthesizer produces average values similar to the training data.""" + data = pd.DataFrame({ + '1': [float(i) for i in range(1000)], + '2': [float(2 * i) for i in range(1000)] + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data) + + num_samples = 1000 + sampled = tvae.sample(num_samples) + error = 0 + for _, row in sampled.iterrows(): + error += abs(2 * row['1'] - row['2']) + + avg_error = error / num_samples + + assert avg_error < 400 + + +def test_fixed_random_seed(): + """Test the TVAESynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + tvae = TVAESynthesizer(epochs=1) + + # Run + tvae.fit(data, discrete_columns) + sampled_random = tvae.sample(10) + + tvae.set_random_state(0) + sampled_0_0 = tvae.sample(10) + sampled_0_1 = tvae.sample(10) + + tvae.set_random_state(0) + sampled_1_0 = tvae.sample(10) + sampled_1_1 = tvae.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..2f0314ca08a4cbd05d2dba7560edeeab57780306 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py @@ -0,0 +1,42 @@ +"""Data transformer intergration testing module.""" + + +# Data Transformer tests that should be implemented in the future. +def test_constant(): + """Test transforming a dataframe containing constant values.""" + + +def test_df_continuous(): + """Test transforming a dataframe containing only continuous values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is **not** deterministic + # make sure it can be inverted + + +def test_df_categorical(): + """Test transforming a dataframe containing only categorical values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is deterministic + # make sure it can be inverted + + +def test_df_mixed(): + """Test transforming a dataframe containing mixed data types.""" + + +def test_df_mixed_nan(): + """Test transforming a dataframe containing mixed data types + NaN for categoricals.""" + + +def test_np_continuous(): + """Test transforming a np.array containing only continuous values.""" + + +def test_np_categorical(): + """Test transforming a np.array containing only categorical values.""" + + +def test_np_mixed(): + """Test transforming a np.array containing mixed data types.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..60ff4d04eff14032ccb698a80a37aa16cb4ff1ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py @@ -0,0 +1 @@ +"""Unit testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..80d7afbb190ef7d1204849cae14f6a89312c39f7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py @@ -0,0 +1 @@ +"""CTGANSynthesizer testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py new file mode 100644 index 0000000000000000000000000000000000000000..5859d93deb2bebe6f07faf0a7c3b08c841e66546 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py @@ -0,0 +1,111 @@ + +"""BaseSynthesizer unit testing module.""" + +from unittest.mock import MagicMock, call, patch + +import numpy as np +import torch + +from ctgan.synthesizers.base import BaseSynthesizer, random_state + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_valid_random_state(random_mock, torch_mock): + """Test the ``random_state`` attribute with a valid random state. + + Expect that the decorated function uses the random_state attribute. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + + random_state_mock = MagicMock() + random_state_mock.get_state.return_value = 'desired numpy state' + torch_generator_mock = MagicMock() + torch_generator_mock.get_state.return_value = 'desired torch state' + instance.random_states = (random_state_mock, torch_generator_mock) + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + random_mock.RandomState.return_value = random_state_mock + random_mock.get_state.return_value = 'random state' + torch_mock.Generator.return_value = torch_generator_mock + torch_mock.get_rng_state.return_value = 'torch random state' + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + assert random_mock.get_state.call_count == 2 + assert torch_mock.get_rng_state.call_count == 2 + random_mock.RandomState.assert_has_calls( + [call().get_state(), call(), call().set_state('random state')]) + random_mock.set_state.assert_has_calls([call('desired numpy state'), call('random state')]) + torch_mock.set_rng_state.assert_has_calls( + [call('desired torch state'), call('torch random state')]) + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_no_random_seed(random_mock, torch_mock): + """Test the ``random_state`` attribute with no random state. + + Expect that the decorated function calls the original function + when there is no random state. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + instance.random_states = None + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + random_mock.get_state.assert_not_called() + random_mock.RandomState.assert_not_called() + random_mock.set_state.assert_not_called() + torch_mock.get_rng_state.assert_not_called() + torch_mock.Generator.assert_not_called() + torch_mock.set_rng_state.assert_not_called() + + +class TestBaseSynthesizer: + + def test_set_random_state(self): + """Test ``set_random_state`` works as expected.""" + # Setup + instance = BaseSynthesizer() + + # Run + instance.set_random_state(3) + + # Assert + assert isinstance(instance.random_states, tuple) + assert isinstance(instance.random_states[0], np.random.RandomState) + assert isinstance(instance.random_states[1], torch.Generator) + + def test_set_random_state_with_none(self): + """Test ``set_random_state`` with None.""" + # Setup + instance = BaseSynthesizer() + + # Run and assert + instance.set_random_state(3) + assert instance.random_states is not None + + instance.set_random_state(None) + assert instance.random_states is None diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..7a724d30779cea4e9512fc480e8417c17a21da7a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py @@ -0,0 +1,343 @@ +"""CTGANSynthesizer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock + +import pandas as pd +import pytest +import torch + +from ctgan.data_transformer import SpanInfo +from ctgan.synthesizers.ctgan import CTGANSynthesizer, Discriminator, Generator, Residual + + +class TestDiscriminator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 3*`discriminator_dim` + 1. + + Setup: + - Create Discriminator + + Input: + - input_dim = positive integer + - discriminator_dim = list of integers + - pack = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.pack` and `self.packdim` + """ + discriminator_dim = [1, 2, 3] + discriminator = Discriminator(input_dim=50, discriminator_dim=discriminator_dim, pac=7) + + assert discriminator.pac == 7 + assert discriminator.pacdim == 350 + assert len(discriminator.seq) == 3 * len(discriminator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. Notice that the input_dim = input_size. + + Setup: + - initialize with input_size, discriminator_dim, pac + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N/pac, 1) + """ + discriminator = Discriminator(input_dim=50, discriminator_dim=[100, 200, 300], pac=7) + output = discriminator(torch.randn(70, 50)) + assert output.shape == (10, 1) + + # Check to make sure no gradients attached + for parameter in discriminator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in discriminator.parameters(): + assert parameter.grad is not None + + +class TestResidual(TestCase): + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with input_size, output_size + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, input_size + output_size) + """ + residual = Residual(10, 2) + output = residual(torch.randn(100, 10)) + assert output.shape == (100, 12) + + # Check to make sure no gradients attached + for parameter in residual.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in residual.parameters(): + assert parameter.grad is not None + + +class TestGenerator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure `self.seq` has same length as `generator_dim` + 1. + + Setup: + - Create Generator + + Input: + - embedding_dim = positive integer + - generator_dim = list of integers + - data_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq` + """ + generator_dim = [1, 2, 3] + generator = Generator(embedding_dim=50, generator_dim=generator_dim, data_dim=7) + + assert len(generator.seq) == len(generator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with embedding_dim, generator_dim, data_dim + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, data_dim) + """ + generator = Generator(embedding_dim=60, generator_dim=[100, 200, 300], data_dim=500) + output = generator(torch.randn(70, 60)) + assert output.shape == (70, 500) + + # Check to make sure no gradients attached + for parameter in generator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in generator.parameters(): + assert parameter.grad is not None + + +def _assert_is_between(data, lower, upper): + """Assert all values of the tensor 'data' are within range.""" + assert all((data >= lower).numpy().tolist()) + assert all((data <= upper).numpy().tolist()) + + +class TestCTGANSynthesizer(TestCase): + + def test__apply_activate_(self): + """Test `_apply_activate` for tables with both continuous and categoricals. + + Check every continuous column has all values between -1 and 1 + (since they are normalized), and check every categorical column adds up to 1. + + Setup: + - Mock `self._transformer.output_info_list` + + Input: + - data = tensor of shape (N, data_dims) + + Output: + - tensor = tensor of shape (N, data_dims) + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(3, 'softmax')], + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')] + ] + + data = torch.randn(100, 6) + result = model._apply_activate(data) + + assert result.shape == (100, 6) + _assert_is_between(result[:, 0:3], 0.0, 1.0) + _assert_is_between(result[: 3], -1.0, 1.0) + _assert_is_between(result[:, 4:6], 0.0, 1.0) + + def test__cond_loss(self): + """Test `_cond_loss`. + + Test that the loss is purely a function of the target categorical. + + Setup: + - mock transformer.output_info_list + - create two categoricals, one continuous + - compute the conditional loss, conditioned on the 1st categorical + - compare the loss to the cross-entropy of the 1st categorical, manually computed + + Input: + data - the synthetic data generated by the model + c - a tensor with the same shape as the data but with only a specific one-hot vector + corresponding to the target column filled in + m - binary mask used to select the categorical column to condition on + + Output: + loss scalar; this should only be affected by the target column + + Note: + - even though the implementation of this is probably right, I'm not sure if the idea + behind it is correct + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')], + [SpanInfo(3, 'softmax')], # this is the categorical column we are conditioning on + [SpanInfo(2, 'softmax')], # this is the categorical column we are bry jrbec on + ] + + data = torch.tensor([ + # first 3 dims ignored, next 3 dims are the prediction, last 2 dims are ignored + [0.0, -1.0, 0.0, 0.05, 0.05, 0.9, 0.1, 0.4], + ]) + + c = torch.tensor([ + # first 3 dims are a one-hot for the categorical, + # next 2 are for a different categorical that we are not conditioning on + # (continuous values are not stored in this tensor) + [0.0, 0.0, 1.0, 0.0, 0.0], + ]) + + # this indicates that we are conditioning on the first categorical + m = torch.tensor([[1, 0]]) + + result = model._cond_loss(data, c, m) + expected = torch.nn.functional.cross_entropy( + torch.tensor([ + [0.05, 0.05, 0.9], # 3 categories, one hot + ]), + torch.tensor([2]) + ) + + assert (result - expected).abs() < 1e-3 + + def test__validate_discrete_columns(self): + """Test `_validate_discrete_columns` if the discrete column doesn't exist. + + Check the appropriate error is raised if `discrete_columns` is invalid, both + for numpy arrays and dataframes. + + Setup: + - Create dataframe with a discrete column + - Define `discrete_columns` as something not in the dataframe + + Input: + - train_data = 2-dimensional numpy array or a pandas.DataFrame + - discrete_columns = list of strings or integers + + Output: + None + + Side Effects: + - Raises error if the discrete column is invalid. + + Note: + - could create another function for numpy array + """ + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['doesnt exist'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: {\'doesnt exist\'}'): + ctgan.fit(data, discrete_columns) + + def test_sample(self): + """Test `sample` correctly sets `condition_info` and `global_condition_vec`. + + Tests the first 7 lines of sample by mocking the DataTransformer and DataSampler + and checking that they are being correctly used. + + Setup: + - Create and fit the synthesizer + - Mock DataTransformer, DataSampler + + Input: + - n = integer + - condition_column = string (not None) + - condition_value = string (not None) + + Output: + Not relevant + + Note: + - I'm not sure we need this test + """ + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cff981a86078d1689bec7bb5a37856aa903b68e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py @@ -0,0 +1,123 @@ +"""TVAESynthesizer unit testing module.""" + +from unittest import TestCase + + +class TestEncoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`compress_dims`. + + Setup: + - Create Encoder + + Input: + - data_dim = positive integer + - compress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.fc1` and `self.fc2` + """ + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct and that std is positive. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(mu) + torch.mean(std) + torch.mean(logvar)`. + + Setup: + - Create random tensor + + Input: + - input = random tensor of shape (N, data_dim) + + Output: + - Tuple of (mu, std, logvar): + mu - tensor of shape (N, embedding_dim) + std - tensor of shape (N, embedding_dim), non-negative values + logvar - tensor of shape (N, embedding_dim) + """ + + +class TestDecoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`decompress_dims` + 1. + + Setup: + - Create Decoder + + Input: + - data_dim = positive integer + - decompress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.sigma` + """ + + +class TestLossFunction(TestCase): + + def test__loss_function(self): + """Test `_loss_function`. + + Check loss values = to specific numbers. + + Setup: + Build all the tensors, lists, etc. + + Input: + recon_x = tensor of shape (N, data_dims) + x = tensor of shape (N, data_dims) + sigmas = tensor of shape (N,) + mu = tensor of shape (N,) + logvar = tensor of shape (N,) + output_info = list of SpanInfo objects from the data transformer, + including at least 1 continuous and 1 discrete + factor = scalar + + Output: + reconstruction loss = scalar = f(recon_x, x, sigmas, output_info, factor) + kld loss = scalar = f(logvar, mu) + """ + + +class TestTVAESynthesizer(TestCase): + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..305f84ee5e57d156348b54400a5c6138d3466b40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py @@ -0,0 +1,473 @@ +"""Data transformer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock, patch + +import numpy as np +import pandas as pd + +from ctgan.data_transformer import ColumnTransformInfo, DataTransformer, SpanInfo + + +class TestDataTransformer(TestCase): + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test___fit_continuous(self, MockBGM): + """Test ``_fit_continuous`` on a simple continuous column. + + A ``BayesGMMTransformer`` will be created and fit with some ``data``. + + Setup: + - Mock the ``BayesGMMTransformer`` with ``valid_component_indicator`` as + ``[True, False, True]``. + - Initialize a ``DataTransformer``. + + Input: + - A dataframe with only one column containing random float values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``BayesGMMTransformer`` instance. + - ``output_dimensions`` is 3 (matches size of ``valid_component_indicator``). + - ``output_info`` assigns the correct activation functions. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.valid_component_indicator = [True, False, True] + transformer = DataTransformer() + data = pd.DataFrame(np.random.normal((100, 1)), columns=['column']) + + # Run + info = transformer._fit_continuous(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == bgm_instance + assert info.output_dimensions == 3 + assert info.output_info[0].dim == 1 + assert info.output_info[0].activation_fn == 'tanh' + assert info.output_info[1].dim == 2 + assert info.output_info[1].activation_fn == 'softmax' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__fit_continuous_max_clusters(self, MockBGM): + """Test ``_fit_continuous`` with data that has less than 10 rows. + + Expect that a ``BayesGMMTransformer`` is created with the max number of clusters + set to the length of the data. + + Input: + - Data with less than 10 rows. + + Side Effects: + - A ``BayesGMMTransformer`` is created with the max number of clusters set to the + length of the data. + """ + # Setup + data = pd.DataFrame(np.random.normal((7, 1)), columns=['column']) + transformer = DataTransformer() + + # Run + transformer._fit_continuous(data) + + # Assert + MockBGM.assert_called_once_with(max_clusters=len(data)) + + @patch('ctgan.data_transformer.OneHotEncodingTransformer') + def test___fit_discrete(self, MockOHE): + """Test ``_fit_discrete_`` on a simple discrete column. + + A ``OneHotEncodingTransformer`` will be created and fit with the ``data``. + + Setup: + - Mock the ``OneHotEncodingTransformer``. + - Create ``DataTransformer``. + + Input: + - A dataframe with only one column containing ``['a', 'b']`` values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``OneHotEncodingTransformer`` instance. + - ``output_dimensions`` is 2. + - ``output_info`` assigns the correct activation function. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + ohe_instance = MockOHE.return_value + ohe_instance.dummies = ['a', 'b'] + transformer = DataTransformer() + data = pd.DataFrame(np.array(['a', 'b'] * 100), columns=['column']) + + # Run + info = transformer._fit_discrete(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == ohe_instance + assert info.output_dimensions == 2 + assert info.output_info[0].dim == 2 + assert info.output_info[0].activation_fn == 'softmax' + + def test_fit(self): + """Test ``fit`` on a np.ndarray with one continuous and one discrete columns. + + The ``fit`` method should: + - Set ``self.dataframe`` to ``False``. + - Set ``self._column_raw_dtypes`` to the appropirate dtypes. + - Use the appropriate ``_fit`` type for each column. + - Update ``self.output_info_list``, ``self.output_dimensions`` and + ``self._column_transform_info_list`` appropriately. + + Setup: + - Create ``DataTransformer``. + - Mock ``_fit_discrete``. + - Mock ``_fit_continuous``. + + Input: + - A table with one continuous and one discrete columns. + - A list with the name of the discrete column. + + Side Effects: + - ``_fit_discrete`` and ``_fit_continuous`` should each be called once. + - Assigns ``self._column_raw_dtypes`` the appropriate dtypes. + - Assigns ``self.output_info_list`` the appropriate ``output_info``. + - Assigns ``self.output_dimensions`` the appropriate ``output_dimensions``. + - Assigns ``self._column_transform_info_list`` the appropriate + ``column_transform_info``. + """ + # Setup + transformer = DataTransformer() + transformer._fit_continuous = Mock() + transformer._fit_continuous.return_value = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + transformer._fit_discrete = Mock() + transformer._fit_discrete.return_value = ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + + data = pd.DataFrame({ + 'x': np.random.random(size=100), + 'y': np.random.choice(['yes', 'no'], size=100) + }) + + # Run + transformer.fit(data, discrete_columns=['y']) + + # Assert + transformer._fit_discrete.assert_called_once() + transformer._fit_continuous.assert_called_once() + assert transformer.output_dimensions == 6 + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__transform_continuous(self, MockBGM): + """Test ``_transform_continuous``. + + Setup: + - Mock the ``BayesGMMTransformer`` with the transform method returning + some dataframe. + - Create ``DataTransformer``. + + Input: + - ``ColumnTransformInfo`` object. + - A dataframe containing a continuous column. + + Output: + - A np.array where the first column contains the normalized part + of the mocked transform, and the other columns are a one hot encoding + representation of the component part of the mocked transform. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + data = pd.DataFrame({'x': np.array([0.1, 0.3, 0.5])}) + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._transform_continuous(column_transform_info, data) + + # Assert + expected = np.array([ + [0.1, 1, 0, 0], + [0.2, 0, 1, 0], + [0.3, 0, 1, 0], + ]) + np.testing.assert_array_equal(result, expected) + + def test_transform(self): + """Test ``transform`` on a dataframe with one continuous and one discrete columns. + + It should use the appropriate ``_transform`` type for each column and should return + them concanenated appropriately. + + Setup: + - Initialize a ``DataTransformer`` with a ``column_transform_info`` detailing + a continuous and a discrete columns. + - Mock the ``_transform_discrete`` and ``_transform_continuous`` methods. + + Input: + - A table with one continuous and one discrete columns. + + Output: + - np.array containing the transformed columns. + + Side Effects: + - ``_transform_discrete`` and ``_transform_continuous`` should each be called once. + """ + # Setup + data = pd.DataFrame({ + 'x': np.array([0.1, 0.3, 0.5]), + 'y': np.array(['yes', 'yes', 'no']) + }) + + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + transformer._transform_continuous = Mock() + selected_normalized_value = np.array([[0.1], [0.3], [0.5]]) + selected_component_onehot = np.array([ + [1, 0, 0], + [0, 1, 0], + [0, 1, 0], + ]) + return_value = np.concatenate( + (selected_normalized_value, selected_component_onehot), axis=1) + transformer._transform_continuous.return_value = return_value + + transformer._transform_discrete = Mock() + transformer._transform_discrete.return_value = np.array([ + [0, 1], + [0, 1], + [1, 0], + ]) + + # Run + result = transformer.transform(data) + + # Assert + transformer._transform_continuous.assert_called_once() + transformer._transform_discrete.assert_called_once() + + expected = np.array([ + [0.1, 1, 0, 0, 0, 1], + [0.3, 0, 1, 0, 0, 1], + [0.5, 0, 1, 0, 1, 0], + ]) + assert result.shape == (3, 6) + assert (result[:, 0] == expected[:, 0]).all(), 'continuous-cdf' + assert (result[:, 1:4] == expected[:, 1:4]).all(), 'continuous-softmax' + assert (result[:, 4:6] == expected[:, 4:6]).all(), 'discrete' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__inverse_transform_continuous(self, MockBGM): + """Test ``_inverse_transform_continuous``. + + Setup: + - Create ``DataTransformer``. + - Mock the ``BayesGMMTransformer`` where: + - ``get_output_types`` returns the appropriate dictionary. + - ``reverse_transform`` returns some dataframe. + + Input: + - A ``ColumnTransformInfo`` object. + - A np.ndarray where: + - The first column contains the normalized value + - The remaining columns correspond to the one-hot + - sigmas = np.ndarray of floats + - st = index of the sigmas ndarray + + Output: + - Dataframe where the first column are floats and the second is a lable encoding. + + Side Effects: + - The ``reverse_transform`` method should be called with a dataframe + where the first column are floats and the second is a lable encoding. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.get_output_types.return_value = { + 'x.normalized': 'numerical', + 'x.component': 'numerical' + } + + bgm_instance.reverse_transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + column_data = np.array([ + [0.1, 1, 0, 0], + [0.3, 0, 1, 0], + [0.5, 0, 1, 0], + ]) + + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._inverse_transform_continuous( + column_transform_info, column_data, None, None) + + # Assert + expected = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + np.testing.assert_array_equal(result, expected) + + expected_data = pd.DataFrame({ + 'x.normalized': [0.1, 0.3, 0.5], + 'x.component': [0, 1, 1] + }) + + pd.testing.assert_frame_equal( + bgm_instance.reverse_transform.call_args[0][0], + expected_data + ) + + def test_inverse_transform(self): + """Test ``inverse_transform`` on a np.ndarray with continuous and discrete columns. + + It should use the appropriate '_fit' type for each column and should return + the corresponding columns. Since we are using the same example as the 'test_transform', + and these two functions are inverse of each other, the returned value here should + match the input of that function. + + Setup: + - Mock _column_transform_info_list + - Mock _inverse_transform_discrete + - Mock _inverse_trarnsform_continuous + + Input: + - column_data = a concatenation of two np.ndarrays + - the first one refers to the continuous values + - the first column contains the normalized values + - the remaining columns correspond to the a one-hot + - the second one refers to the discrete values + - the columns correspond to a one-hot + Output: + - numpy array containing a discrete column and a continuous column + + Side Effects: + - _transform_discrete and _transform_continuous should each be called once. + """ + + def test_convert_column_name_value_to_id(self): + """Test ``convert_column_name_value_to_id`` on a simple ``_column_transform_info_list``. + + Tests that the appropriate indexes are returned when a table of three columns, + discrete, continuous, discrete, is passed as '_column_transform_info_list'. + + Setup: + - Mock ``_column_transform_info_list``. + + Input: + - column_name = the name of a discrete column + - value = the categorical value + + Output: + - dictionary containing: + - ``discrete_column_id`` = the index of the target column, + when considering only discrete columns + - ``column_id`` = the index of the target column + (e.g. 3 = the third column in the data) + - ``value_id`` = the index of the indicator value in the one-hot encoding + """ + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('y', 'yes') + + # Assert + assert result['column_id'] == 1 # this is the 2nd column + assert result['discrete_column_id'] == 0 # this is the 1st discrete column + assert result['value_id'] == 1 # this is the 2nd dimension in the one hot encoding + + def test_convert_column_name_value_to_id_multiple(self): + """Test ``convert_column_name_value_to_id``.""" + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1, 0] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ), + ColumnTransformInfo( + column_name='z', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('z', 'yes') + + # Assert + assert result['column_id'] == 2 # this is the 3rd column + assert result['discrete_column_id'] == 1 # this is the 2nd discrete column + assert result['value_id'] == 1 # this is the 1st dimension in the one hot encoding diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tox.ini b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tox.ini new file mode 100644 index 0000000000000000000000000000000000000000..5fbffba409c0fee10719de58cf5a5bf4639b374e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/CTGAN/tox.ini @@ -0,0 +1,19 @@ +[tox] +envlist = py38-lint, py3{6,7,8,9}-{unit,integration,readme} + +[testenv] +skipsdist = false +skip_install = false +deps = + invoke + readme: rundoc +extras = + lint: dev + unit: test + integration: test +commands = + lint: invoke lint + unit: invoke unit + integration: invoke integration + readme: invoke readme + invoke rmdir --path {envdir} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/pipeline_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/pipeline_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cd8f0c4afd222607db65aae70fe969385ea4d79b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/pipeline_tvae.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_tvae( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_tvae( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/train_sample_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/train_sample_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..7db74590f2826edf87938d3707bf12fdcfbf2b5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/train_sample_tvae.py @@ -0,0 +1,117 @@ +import lib +import os +import numpy as np +import argparse +from CTGAN.ctgan import TVAESynthesizer +from pathlib import Path +import torch +import pickle +import warnings +from sklearn.exceptions import ConvergenceWarning + +warnings.filterwarnings("ignore", category=ConvergenceWarning) + +def train_tvae( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = TVAESynthesizer( + **train_params, + device=device + ) + + synthesizer.fit(X, cat_features) + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "tvae.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_tvae( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + with open(parent_dir / "tvae.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.decoder = synthesizer.decoder.to(device) + + gen_data = synthesizer.sample(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + y = y.astype(float) + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + y = y.astype(int) + np.save(parent_dir / 'y_train', y) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_tvae(args.parent_dir, args.real_data_path, change_val=True) + sample_tvae(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/tune_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/tune_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..0b6558c024ea45bdc43b09025ba4f233417de999 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/CTGAN/tune_tvae.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 3, 6, 9 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [1000]) + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + embedding_dim = 2 ** trial.suggest_int('embedding_dim', 6, 10) + loss_factor = trial.suggest_loguniform('loss_factor', 0.001, 10) + + + train_params = { + "lr": lr, + "epochs": steps, + "embedding_dim": embedding_dim, + "batch_size": batch_size, + "loss_factor": loss_factor, + "compress_dims": d_layers, + "decompress_dims": d_layers + } + + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_tvae( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_tvae( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/tvae/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/tvae/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_tvae( + parent_dir=f"exp/{Path(real_data_path).name}/tvae/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "tvae", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/LICENSE.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/LICENSE.md new file mode 100644 index 0000000000000000000000000000000000000000..3c105473f782136fd5659e03d454cfc3ba31252e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/LICENSE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022 Akim Kotelnikov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/README.md new file mode 100644 index 0000000000000000000000000000000000000000..517e9aa2f8024a8412a9028529e7fe88f6c57dec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/README.md @@ -0,0 +1,99 @@ +# TabDDPM: Modelling Tabular Data with Diffusion Models +This is the official code for our paper "TabDDPM: Modelling Tabular Data with Diffusion Models" ([paper](https://arxiv.org/abs/2209.15421)) + + + +## Setup the environment +1. Install [conda](https://docs.conda.io/en/latest/miniconda.html) (just to manage the env). +2. Run the following commands + ```bash + export REPO_DIR=/path/to/the/code + cd $REPO_DIR + + conda create -n tddpm python=3.9.7 + conda activate tddpm + + pip install torch==1.10.1+cu111 -f https://download.pytorch.org/whl/torch_stable.html + pip install -r requirements.txt + + # if the following commands do not succeed, update conda + conda env config vars set PYTHONPATH=${PYTHONPATH}:${REPO_DIR} + conda env config vars set PROJECT_DIR=${REPO_DIR} + + conda deactivate + conda activate tddpm + ``` + +## Running the experiments + +Here we describe the neccesary info for reproducing the experimental results. +Use `agg_results.ipynb` to print results for all dataset and all methods. + +### Datasets + +We upload the datasets used in the paper with our train/val/test splits (link below). We do not impose additional restrictions to the original dataset licenses, the sources of the data are listed in the paper appendix. + +You could load the datasets with the following commands: + +``` bash +conda activate tddpm +cd $PROJECT_DIR +wget "https://www.dropbox.com/s/rpckvcs3vx7j605/data.tar?dl=0" -O data.tar +tar -xvf data.tar +``` + +### File structure +`tab-ddpm/` -- implementation of the proposed method +`tuned_models/` -- tuned hyperparameters of evaluation model (CatBoost or MLP) + +All main scripts are in `scripts/` folder: + +- `scripts/pipeline.py` are used to train, sample and eval TabDDPM using a given config +- `scripts/tune_ddpm.py` -- tune hyperparameters of TabDDPM +- `scripts/eval_[catboost|mlp|simple].py` -- evaluate synthetic data using a tuned evaluation model or simple models +- `scripts/eval_seeds.py` -- eval using multiple sampling and multuple eval seeds +- `scripts/eval_seeds_simple.py` -- eval using multiple sampling and multuple eval seeds (for simple models) +- `scripts/tune_evaluation_model.py` -- tune hyperparameters of eval model (CatBoost or MLP) +- `scripts/resample_privacy.py` -- privacy calculation + +Experiments folder (`exp/`): +- All results and synthetic data are stored in `exp/[ds_name]/[exp_name]/` folder +- `exp/[ds_name]/config.toml` is a base config for tuning TabDDPM +- `exp/[ds_name]/eval_[catboost|mlp].json` stores results of evaluation (`scripts/eval_seeds.py`) + +To understand the structure of `config.toml` file, read `CONFIG_DESCRIPTION.md`. + +Baselines: +- `smote/` +- `CTGAN/` -- TVAE [official repo](https://github.com/sdv-dev/CTGAN) +- `CTAB-GAN/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN) +- `CTAB-GAN-Plus/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN-Plus) + +### Examples + +Run TabDDPM tuning. + +Template and example (`--eval_seeds` is optional): +```bash +python scripts/tune_ddpm.py [ds_name] [train_size] synthetic [catboost|mlp] [exp_name] --eval_seeds +python scripts/tune_ddpm.py churn2 6500 synthetic catboost ddpm_tune --eval_seeds +``` + +Run TabDDPM pipeline. + +Template and example (`--train`, `--sample`, `--eval` are optional): +```bash +python scripts/pipeline.py --config [path_to_your_config] --train --sample --eval +python scripts/pipeline.py --config exp/churn2/ddpm_cb_best/config.toml --train --sample +``` +It takes approximately 7min to run the script above (NVIDIA GeForce RTX 2080 Ti). + +Run evaluation over seeds +Before running evaluation, you have to train the model with the given hyperparameters (the example above). + +Template and example: +```bash +python scripts/eval_seeds.py --config [path_to_your_config] [n_eval_seeds] [ddpm|smote|ctabgan|ctabgan-plus|tvae] synthetic [catboost|mlp] [n_sample_seeds] +python scripts/eval_seeds.py --config exp/churn2/ddpm_cb_best/config.toml 10 ddpm synthetic catboost 5 +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/_compat_run.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/_compat_run.py new file mode 100644 index 0000000000000000000000000000000000000000..77f1230651645a74d0f38b3ff44204cbe28e07ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/_compat_run.py @@ -0,0 +1,6 @@ +import collections, collections.abc +for _a in ('Sequence','MutableSequence','MutableMapping','Mapping','MutableSet','Set','Callable','Iterable','Iterator'): + if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None)) +import sys, runpy +sys.argv = sys.argv[1:] +runpy.run_path(sys.argv[0], run_name='__main__') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/agg_results.ipynb b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/agg_results.ipynb new file mode 100644 index 0000000000000000000000000000000000000000..b2265036321a1b9a52a99daf500759ef4b03d60a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/agg_results.ipynb @@ -0,0 +1,315 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Aggregating results to DataFrame" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import os\n", + "import lib\n", + "import numpy as np\n", + "import pandas as pd\n", + "\n", + "DATASETS = [\n", + " \"abalone\",\n", + " \"adult\",\n", + " \"buddy\",\n", + " \"california\",\n", + " \"cardio\",\n", + " \"churn2\",\n", + " \"default\",\n", + " \"diabetes\",\n", + " \"fb-comments\",\n", + " \"gesture\",\n", + " \"higgs-small\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + " \"miniboone\",\n", + " \"wilt\"\n", + "]\n", + "\n", + "_REGRESSION = [\n", + " \"abalone\",\n", + " \"california\",\n", + " \"fb-comments\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + "]\n", + "\n", + "\n", + "method2exp = {\n", + " \"real\": \"exp/{}/ddpm_cb_best/\",\n", + " \"tab-ddpm\": \"exp/{}/ddpm_cb_best/\",\n", + " \"smote\": \"exp/{}/smote/\",\n", + " \"ctabgan+\": \"exp/{}/ctabgan-plus/\",\n", + " \"ctabgan\": \"exp/{}/ctabgan/\",\n", + " \"tvae\": \"exp/{}/tvae/\"\n", + "}\n", + "\n", + "eval_file = \"eval_catboost.json\"\n", + "show_std = False\n", + "df = pd.DataFrame(columns=[\"method\"] + [_[:3].upper() for _ in DATASETS])\n", + "\n", + "for algo in method2exp: \n", + " algo_res = []\n", + " for ds in DATASETS:\n", + " if not os.path.exists(os.path.join(method2exp[algo].format(ds), eval_file)):\n", + " algo_res.append(\"--\")\n", + " continue\n", + " metric = \"r2\" if ds in _REGRESSION else \"f1\"\n", + " res_dict = lib.load_json(os.path.join(method2exp[algo].format(ds), eval_file))\n", + "\n", + " if algo == \"real\":\n", + " res = f'{res_dict[\"real\"][\"test\"][metric + \"-mean\"]:.4f}' \n", + " if show_std: res += f'+-{res_dict[\"real\"][\"test\"][metric + \"-std\"]:.4f}'\n", + " else:\n", + " res = f'{res_dict[\"synthetic\"][\"test\"][metric + \"-mean\"]:.4f}'\n", + " if show_std: res += f'+-{res_dict[\"synthetic\"][\"test\"][metric + \"-std\"]:.4f}'\n", + "\n", + " algo_res.append(res)\n", + " df.loc[len(df)] = [algo] + algo_res" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "
\n", + "\n", + "\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "
methodABAADUBUDCALCARCHUDEFDIAFB-GESHIGHOUINSKINMINWIL
0real0.55620.81520.90630.85680.73790.74030.68800.78490.83710.63650.72380.66160.81370.90700.93420.8982
1tab-ddpm0.54990.79510.90570.83620.73740.75480.69100.73980.71280.59670.72180.67660.80920.83310.93620.9045
2smote0.54860.79120.89060.83970.73230.74320.69300.68350.80350.65790.72190.66250.81190.84160.93230.9127
3ctabgan+0.46720.77240.88440.52470.73270.70240.68650.73390.50880.40550.66390.50400.79660.44380.89200.7983
4ctabgan--0.78310.8552--0.71710.68750.64370.7310--0.39220.5748------0.88920.9060
5tvae0.43280.78100.86380.75180.71740.73170.65640.71360.68530.43400.63780.49260.78420.82380.91250.5006
\n", + "
" + ], + "text/plain": [ + " method ABA ADU BUD CAL CAR CHU DEF DIA \\\n", + "0 real 0.5562 0.8152 0.9063 0.8568 0.7379 0.7403 0.6880 0.7849 \n", + "1 tab-ddpm 0.5499 0.7951 0.9057 0.8362 0.7374 0.7548 0.6910 0.7398 \n", + "2 smote 0.5486 0.7912 0.8906 0.8397 0.7323 0.7432 0.6930 0.6835 \n", + "3 ctabgan+ 0.4672 0.7724 0.8844 0.5247 0.7327 0.7024 0.6865 0.7339 \n", + "4 ctabgan -- 0.7831 0.8552 -- 0.7171 0.6875 0.6437 0.7310 \n", + "5 tvae 0.4328 0.7810 0.8638 0.7518 0.7174 0.7317 0.6564 0.7136 \n", + "\n", + " FB- GES HIG HOU INS KIN MIN WIL \n", + "0 0.8371 0.6365 0.7238 0.6616 0.8137 0.9070 0.9342 0.8982 \n", + "1 0.7128 0.5967 0.7218 0.6766 0.8092 0.8331 0.9362 0.9045 \n", + "2 0.8035 0.6579 0.7219 0.6625 0.8119 0.8416 0.9323 0.9127 \n", + "3 0.5088 0.4055 0.6639 0.5040 0.7966 0.4438 0.8920 0.7983 \n", + "4 -- 0.3922 0.5748 -- -- -- 0.8892 0.9060 \n", + "5 0.6853 0.4340 0.6378 0.4926 0.7842 0.8238 0.9125 0.5006 " + ] + }, + "execution_count": 2, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "df" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3.9.7 ('base')", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.9.7" + }, + "orig_nbformat": 4, + "vscode": { + "interpreter": { + "hash": "a06af253165e97d0c1e75e8bf6d3252013856f30b8177e11b02d3fa36c37333d" + } + } + }, + "nbformat": 4, + "nbformat_minor": 2 +} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..4440c9036b27a7ff5f55a6f733751f0d1d5caa0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db1cf55340ae5364a05a1c840094ca47fff79dd584850c9ee751b2a097f7b075 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..415f08cd7f0cafb12c8a8e86a587ca54e17e128a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dcb118d387bd15e6a79e571ad80c7a4fe900858c45ccea903e70a9550c86203 +size 256 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..239282facabecb1d9f1223c79c3fef51fe2be053 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe8c63e9f9a09cd9ca89affd4bb5e4d1545d59cdb31f9f73fb486257bbfd447f +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1bce1d2e055e5b55b325fe6842697c47a89b8461 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6bd872ae66f715fffcc92f2c7c4cc2246980b4df0e02b93738a8c9b4f697af0 +size 539 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2d0fab15dfaf04b2a9fb717ea0802d8e62fee7fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42a3a2e2f22ebc24b66aaa3403869283f6576ce04e5fafa81fec15735d66aee3 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6310c4aa9115b015b514b2a282c61d68fc369a75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d6478bba03b9309a26ef6e1247d95ce86668437fa08a6c5f15776ec9848a5e2 +size 2424 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9eb5c94dab72a3d1610e5222c6de3ddad5cd6c41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc6aa7d00bb5078f766e5d73ea4e04bbe8437bac44636cfd80a36b9262df0a01 +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76e24715bde6ce626bf4308daece11c372c83fef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7ef5506437037908e0c0d5f0bd0c5eb3c61747d9de491d345dc0e8e8be3845b8 +size 909 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..e1b158afbd5ef2c36faf553bf457b116fb84307c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe4a3e4e117924a65d2da76254394ba8aae00555e30bebae916e154a925f0e3e +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..49ecaecc1998e6d60b6cf38839b1801c76106646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aaf9df7911d5911b85f1a805c48a1c6d0e978e287c10f9ef78365b08a14da806 +size 4809 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json new file mode 100644 index 0000000000000000000000000000000000000000..d6c8c3f0aa45c5f991ef888e56074644c40f7643 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0684462d69e5c1c8db2b1fad1ae7760be1849abcc5a623b5eaf07255b04a17f8 +size 454 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json new file mode 100644 index 0000000000000000000000000000000000000000..812b1fa0d26104fc94f9d73497c59db5bda8c81b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce2cdfb51f7d37053edfa2250af17d1adef47d3e0eb141926a6a74a613c6cbb2 +size 442 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..38785f12fa8a0a5c6ec6924e5ddf9222ec12dd11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c621cbd0dcc71b7f8c19d01e2aa6e3497f82d84a40a97a2bfac4ed83e3e0df42 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..7e3f93f4f09ff79f86157b296529a7e893d25078 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1b145c01ef06f81e77de7b8438cb942b863881a21cd76afbcb96b7a61100e96 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e1290d33f1f124f533c3159f32d21a3e917e8872 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d17baaaca34b2ff7aa0e7a68f062bfa12782bd4c483d07e7f97758a1f6a8357 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2a6ae85d7cb08d2200c0fd578de2cd4e0cacea2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00526ecd9377b1904c01ed6cce54c0e9b691c850e292f0588107f770ca1f8fc2 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..91fdedad84e55e1fef159b04ee30ed4841dc7692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3996ee9bde79e3982c88235d2b1122b8988c89611bb7c41dee2d1c12139e3bb +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa9932fd4604af72d4378fa0f4c66c2b7d3218e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e9cb8da939d962852869d248afad2320f27d30ac1900442e6f1379fe88051b76 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..41fdb7e2dca3291094b85592a2b047e69f29f529 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:207d7dcbfac7bbfc854a941b32c95a76a51496bb71717c2a5ff2a2dbb829b26e +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9bc4cdcb8f275644399a66aa1b80f60616bc3e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7df36381315039d5cb9a27726a08f74032f27bce1000fefbbb01aed9b3e4b2ae +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c623de2b0e3bf0dd3be30de30b65a60c9436a979 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df8ce015eace899092d39efd5c2b7d3fde374ed529dc16feac566fb6447990d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..511f215474c59b8543820b3d0b88de78e0de0d9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:559fcc7559fdf7b84792453eb40b37ba2940146f16519894b6f6fd37fa3bb5b3 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b6a8ec4bb5bd70ce60006afd3a7dff1822feb169 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20b5b6b62d80477424158fc13250fd86a5c810bffbf9f930efb7a1e3bcddf0af +size 2407 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a9fb552c41e001e71154ecafb476a465879687a7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c6b40deb21de47336a7784135e055cae8e4162fec33c39b78c3a41e3f74c948 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4da4fc191a2e5f0676788c852c5e1cbed41d32ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9f78af172c35514168b0ba7aa97d29f9d9e44ba99293de739049be2e3705645 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3723363ce4b36e338ef02bdf850bc9f02336320d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0290647040001ea9a368bf406a5f0fe3bfd8ad34fc91e12f9b3cbe4de489cd9c +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac7bcb5f706eeea6d76d7540548852531b06071a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bd237e3800561b53e3ad33f78abd40d90631f66532d2efdcef113e02a239cc46 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..32cb493748339cff60f7fded2233546e5e32cc84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d181d9e4e274ba8953549a2a86feb4f9fd0d344a56fc0c23dee58489fb2f4dea +size 2412 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/abalone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c91eaa420a435b2548fe9f6fa7cf86aca25a447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82fa681345385f4cbddf6c2946308525a747b4e8502e5eb0700402911680c3ee +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5f1a10d99f376c73048318bd2af6ae390e8a4490 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b99ae92eed9a1e581aa7ff0d271cd67f0955d0cf09a510dc5e1cc6a385e21b3 +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..38203892c516eb52a6199e64ce8d12d24b452965 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc182a50c2f168db47f03cf6e35aad805d855e67504c16b7abf4a54010869fe +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..66d6fdbcc81074fe3726c4679a8f0f06df75877d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98523dda3ed661941608fe1b376806a9d0affc87834ca87779f4671ba571c54b +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fbc7353d875b05901555aa21421fdbed1c536705 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea807b1b78a37648296de632ce735f58d486a97f4b24e932aa779c67e25acb9f +size 552 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..53d639a085e90b656b18c69da21e580cea010516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c80c4d789cbc01a2220a215ce23df5afd3492eed59f66682ac55336b42bcab6b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bef94f899e84c5df37d7988dd17dcb902600974b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85088d7d9b8600f758d5ff5571b8a8c6704d5a59ca6abe26fd4904ae19c55632 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..63cd2f794eb62ec7a0ee29203f9a9a9d4dff5462 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:289633f5b676d2316c97619996c97c873176e1210dd6db4a61191a6f4bb17f80 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d0d477a0e57573a39b7fd81b710503bd4e73724d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e8bc409e88198d374b05d90076684ca2b90d591045db6766a5e936801333b53f +size 945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4ca38c916877e7e9eaf024c9fb6c28a56f3c474e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b8d5261312695be59977ccae61c966a26b0cb69a14c644c68f922ac8f893a32 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2d09f8eb221ed76948966ea9f07fc9563f632d58 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2af8c461fb0755cb3b48fcc7f09188e00cf86cd81eda9c0b4bd578f27a7e4958 +size 1317 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6daff009fa1786d5a82839aa85d058902b799602 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fb01634aa14168c902aa056ab75585f0e651d9f26731512fd0012ae3e689318 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab913f002d23e5ae0a7f14750752565fcbfd8ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2b61e81512f6e5be97135a46ef8fd46a22f64a9a53d6659700abdc151142c9 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..36d2e6dda9874bdd9bab29341f3c433d97584768 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df063802251823342ba95960aefc6e9a7860c912f1d086b50145bb973c372b69 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0402c64128c1641e1847800e507d54d189c6f51f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ccdb7ba1c26da827d15509d3040ebe6465586801b404cd099913fcd39dff534 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1cc8823537ac8759cdf13cf468f7da760c1dceb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42ae10d1554df7b8b364f5e0ac4701986cd67aecb9967eb70ea2e077bb134652 +size 901 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..55a0bb6fcaf422c13a2c2ff53c58a57f8b9331d3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b61d18963acc154eb7ea64dfddcf182ed993a93b15c86cd757bc53cacbb9a23 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..139a662dcc89b87ec89a84edfd564e8c2de7cd30 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fdf95abca172dac3b978818cd21f1505d45d69d95bcd9d87e51cc0ee74025d4b +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d32d9411660891640b125047bf880d1fe4b25ab7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:62d657b20c19d7f33e7e5b64472078bd7db69f460cc77bce2b9da69939f7d13d +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..46589fdd2546416d8423587d17e49ab98f2fdb72 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:537b8d3c395d476ad7191337d6f7ca04e938ca5743ccec0bdc0ff94bd48997d2 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7ab60cea704ce4061d24f98827d49d17a1c9d10 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a2a0754baabf29b1ecb6a70d42bd4d1586800bfc47b6bbb0f1f304bb1242b09c +size 3324 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..00321a9ffa3e714125668ab0501694db50470136 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba31f53b7ae00081599032869b9b661df43572e336d56db4fa08beff271a4abb +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8f9ac5ebeb685a33a38e5c51e47b623dde84802e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d91e2295ca75ac6be7cb33c17ef83238dfb8a2e8b2b92237ed405bbaf111d6d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65e9f57bae10cf98cf7283cffec68a0a5fad217a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25a126b5e9fe86493e96b5df30b1a53919680a3a444f6f2605f45fba1d1598e2 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..872de3d2083c260dc16bcac5c091025328ed54dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ae76a56a721fb2229982da25398fc47af989bf8c76be29b8ec07d16eb8963c3 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bab398cb86a7bd5b269964545090c18d3004f9a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cf5cf2766e0d2e778fd96198b87441aeb3272204d8c8ec028f9e1ef671f99db6 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/adult/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fec2e348eead32758349c9ff196afdaab3864d9d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a44105b82634b3c9b91016d8e954a0094ffad036e51845477eabd00e7d4094c9 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..30aad0f91dff111a4fedd1215e6009a644b61e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9e3cc82640c33eb1b4b850f705145d9f84c7c20b787c0db7c3fbe856dc4b11b2 +size 535 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..42f18f71c16e70c9d9b070942fca0f017000e140 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:83d2c2f95c8958abaab28a0adba1d1d3d1e3702d2045c6b4533e35a63a55e604 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b0b6c1aa4f31697486bb4e03a22cc21ba57c7b99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab1c4263a713421bc1d7552aaa52a651e1020f71e1fe7a42b3723e4e7e143d1c +size 2393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2561375d3b6eb2798994bd9db1120b027b7a1cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b238f1464d4e714993012382f3e052a3fc0722743a200411551aa5031fe0874 +size 516 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4021982c6c299c4de244288a83dc31e691242289 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98856815bb0939c1231594e31ce2b910e1fc809f185d28ffaf7a0b6603664c9a +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bb60ee553f1ea7d4c2d8540e3c2248a14b69f74c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2620ed0d33427576a9c706e74f86ae948076ac55615e4b87a82ba1daf9c789db +size 2394 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..49363d44b0b4c826d5d675158164c93de19c68d2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d35a863d159b0cd489d94ae8ae1cfb9b916fc02c99a931ce487cdf189532f3e4 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..722c460979cf67531c5b946aa745fd20ddb80a07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba6dda074f72eee74b8afbc2b18fd4626e710a2d3583d4379509cf9025edcac +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac199ba6cbf5784bc6a656c727d92923bb947df3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61aa5b3aaa5ab7da9c58c291c32533b9945e60b67f43f898ab179a9b3060d895 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..81d026923d55ab59b3dc3c6383b52450a1a03f0c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b941bcd7d8c5cb1cc585540ec98f24a0c12236698bea9b81f59b95e3783eeb30 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..47e136ee719855e17287e833b4946e398a10e2b1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb18ddf958aa699f11e0af740a81cd39b8f6df95860b5fbd18185bbe47ddad4a +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6041d3975ff389fe0d3062e98b03c07159250e16 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b15ec2d2c0d7b64cc6c3c65f03be04a7b813ad6f58ac10c92591045cc079cde +size 307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..52f8c0995c704b748fee904d2b83d774f1717913 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c3675f54196bc3cb4b2d19bcb5618d8577268882c082a4e64c52e5f1f7f05c9 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c846e6c961316abf6d4e1a63f0e0b8247e643f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aac333513d83a2571f92a1ccd30688bcbb74b4c2334da701d2514a83605d652f +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3e5fb807e5fbc4e8b6daeae882cbf7220dfad65a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86ea8bc3b6b08c587585c1cd2287359abff44cc3e717767bd85cbc6a390e0870 +size 962 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae7fd0cda795fa6c97a342a0c128db17b5d7a763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b849b1a0af8d78f67ccbd04a3a35dee96b72f8aeb10ce3090ff3e11f6b425b5 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..778b938d4d50038bb857dddcffec813f70a4b1ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc2aec212d7363d486a316be109ee1d435c0944022f9f3a0279588b3ab4fc456 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c068a90386d6600e32f428498170073bd7e8990 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa163009f809658f57d8d5128088de7586d4b689e127f65c61583796611e5c56 +size 399 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..318d2bf2e09df253811516d67ebca9f7c7f0695c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fde8a58d975533a542c08c06ea1b796065a6dee6cb0cfd4378e1b985818c71d0 +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7833ba5f315b943a8d73137b7ed675646fb2715 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f71aaa39f6f7126dd425a82aa795129a6fc31019607c8ea99f4b6f8bf523a7e +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..f2c93e38fc570c526ef27a6db0f2d0234937f642 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:84f60f6dfb97afdb242b799a412b7c73905b61bde1593a62a7729e6c3f3c246a +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..45d86aec79a33b80cfbbcacdc2a7ee1bcd2760ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9f43aacc1c469ef228585feae4b8ee193ce1602a6855ab41bf5bac7f30f2386 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5fa9cedcd3cf536a2a379ff590486c9b4eedcb53 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49a118abbde6ea1ca044c5f60965e23689dd5faef50a612bb571bd6b1774c57e +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..338bb99b41bfe233281929d5d2e05416b1095031 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2235588571940c74c58717080910fd181be9fae29e9a387b6d34ead239db91a9 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c27447695997806191b34155281cd904003c4235 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d66bfbd3170e741c11c189ab9c40e4d4ba0310d70df88fede66df233d7a13e6a +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/buddy/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..269fa24454c2b0228ea9d70a27f3217c50cd73fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:47fa5e3a33f17e31a9a3a7a986c4d189aa6de421185bf67340c6f851c5f68503 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9389e17f5523a293bafcbf07879c4fa7ba402a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c263f7234c47093e6b0c0ae04e54ff853ef64604141527e6099587da4c158fbc +size 536 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c01ed90eace99eefca1d9ddec2b75aebbea0c968 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:45cedb6e79c0e481d2608def3e1fcef07f832f989acc78d1397e373b261dfada +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..de5b58adce509a35f047a0ed963404afd0acdbbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ff12d95e026451c0ea70fc9877fdeeaa06a5e55e8424c151b14ea8d5c4a65d +size 2425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..645123d51e5899d9ae6aa4d041c63d8c5f40b69a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b7f06bd35da5fa1b2a7af11faf1517e42bc7300a33804adc14a6a937d40e0b99 +size 961 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0c21aedc0ea78626a22795cfebdea5f097649bea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b8c5497ed9e9dd29cd6423795998a32a9e064afe3e25fa166429d1d4531c7632 +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..183d6bf2f7200c58fab0537bc71eea8dd9029042 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f45f5378800af031cc1189625a89e6f971f244084ab6a1ec44851c1cc97791bd +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4cd56144fff8b9f7435faaa60e0495f1b25eb902 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:449806d716989b618e9937da4fcd1d1b34a3303af0fed823518593f10210dc08 +size 4815 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c94ec5f2c60e366c93758984ccedf7276f71cce2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a28f54c683196f15422a3de9fd1729928800c9c6d9f2b2c4f306781a58bb0d57 +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..65f9bc67bb2bb4816ecc0159070ed355b2bc882a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25c3b72ca028e0ac20a23ef943128c03c5be2361341e312f6fb970bbadbea62a +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0914fb8061937287fa55186e588aee0978202325 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db0bf0f16268095c085c9578c9dc6929619b25d85de4beafa71e2e2c0b8aba9a +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc53309f95d9da1956bf01d9d813899524f1a2ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:043cbac22ddcc78d3bf1ba8667bfd3319f2ef4d20be12171ddd794f02e3819b2 +size 974 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e6a741bc6e80d9a8caa8cd4d5aced901340df557 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f473c3dbf1df529cb9c83e61d15ece198d860dc01b2a2e89eb85fe9ddfb71e09 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2a303e9844c21875d49583eb43bde27f212fdd91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d349508f350d7d86ab8f1bccd80706db33b4c493d8d0fbbe7a78dda7daa7bad +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..455675f5055f90694438c7fb7b00c6ab6a1f776e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2d64e51d8b6b24265a2c3948da7bf7ebf652a479ffc356690c7c32e7d05de0 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..110388b3920b6cc8b54b8d5674f95d816e8401fb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d918b0594fae87d25263c250b82a3481da89d2b27414bc5f46fc15a128e3dec7 +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..cbd3b9076dc55fdf3c0d603ffe7c1128a83f2ab1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db184ee0c7f1a2f3b154833c774c7cc95247bee0f0bb332fdf2f81fee52d2980 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..422c57be1a335bc126ae19e81f8de261046667c8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:684c20875442fd0af9aef20e258408265a0afefd337b3095e30f383f558f4e66 +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ebf8752d97e0b55ee67d6b25ea55a0a6035bec7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cba89f4f5a0ee277861f5c59874977e192052179029bae2ce1d4d51afcdf3ba0 +size 2409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a63e8c4e3026a48b79e8f373d7b97101cb791ebb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfc716ea0562b0304e5fc93363c2b47e3c62c6f3b53efdf627d4016698dc628a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..57ac452fdc6cba483d2217dfdebff391e5ef5679 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:31f62570889e2465b493833d65252ee55965ed96a5621737168d7908c8847592 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..11fcabb46bddd9db63302a9187e507bce762f416 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2040299a5b6055953f17fb97dadaaf61b71b994f54639358a474976448bafe99 +size 620 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9aa6e63ec8e0a96295b61ede2f6fa3bfbcc3c4d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d208514a5cbe37b42c4a6d9be3ac9e2f32f359162f9e6e8c4f4482b5e487880d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e2392a3b0b097544d9e26713aaae9629aa1625a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46f24cdcb144018444629866ac8d0cb66b41c004e3fdb3f30e037c63cf5676c8 +size 2427 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/california/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..32d5bd49be0dc36ca2706cd274f3d7a528666572 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7559f0164dc80330ee436b9c6776f02149f6292e4b43c6a46ae5e14dc42ac6bd +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c49810fdd2e5118eca066398387f600036483e15 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b8f5e646194ff57dcb4e98faf5ddd4bdf7bda7b88e30cd5467ed28b3bc3cca9 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e9acecbbb72edbbbad89031bd6ca7c1f812bafba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4741f1db86513a094d4851c28387739323b4a120db20c6876fb1c3c4882e8d90 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b37393fca5e2296bbb3f6766189c46f04372a0ab --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc5de6dffe429c643429ece101cb1c96a9fb69ff584943a3900e1c708b97781d +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6958fa6c7bdb05b6cdb345ec7a2b502db956de63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89520a1f3bea8b05349191737c397a74f73628e809f1b3e8812a9598676c95ba +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d54495c34176f8c6c531042f06f9cc6b328dc961 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7f673d62b4ca86b684d165166a9af155b8a46a2d04c3ff142119f3183b6c089d +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..359ad3f5de3d94dee020f29f1ed8e06d6dfe8b45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4092df04bdfa1202c4b36ae7b546150c9eb8b4208c2fdd0a10ec0fc8bc734df0 +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48aaa3431e36e4baf682bf2feced3c975e00af7b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ee347b13e03324fa6939416de58aa2d45353abf49d2974268edb9195cbb626c +size 950 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5b257cb1dad201b5cdf58957295f53d2956a44c2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfa9f334e88216ec3f8c3dbdf41093ff0625bd58366228b8f18693763e4c8ed5 +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..da7a7e578cf69534d49bc1e245f9baa6572df901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d20ca1246e05efc45538fa88921adcf96a1cff065e9596a56ebb6a3e898349d2 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e40f16736ba413da0169a57765b841abaf1a17ef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1ebb005049375997ae5edad683d9be7aabe9e9fe61adb441fcf2570dc3a67409 +size 6635 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..698e4c1f1677c0dcc9913dd979e88babc5138ea1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46040801014c5a90ce5594329dc9aa6df9f5149b14a31a0ebde94b8af530a2cb +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b5f8f7a4b101dba67cee17287d52bc9b3a4e502b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8059543ac2410dd6a9fcc21fdf78b27a52590fd11ad5ae78e8c0ec4c50562a1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..d27f58b1a316a4f1ec709075333dfba96bd26cc9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49914d0e4622823c539bf12671155b3eeba24785cf041e53d063c497a7aa8d84 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0fb1249b15b018b8e114a958355be527821c6f44 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddd98643049e38978a0c8ae1a9bf130dcffe50dd1d273f2ff9818c574ad577 +size 940 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..69342c6e3076359aacd57f8e4586aa0c5303f6e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:241fd60dff540e7a6cffc88bf736287b5a9782b2feb0c4e06b64c549dd9a6a05 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4fb60954e12fb8aaddaf1ea7e5fccd9a97a93a62 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c310bd2406837fa0bd6a0923ac0627f101f55858cdb76829377b7e09371253d3 +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..62ba2b0042239c143d50e65943ea37b201e89849 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f063a4c004754b6c20bf16e11367ccb025f0fe33950f8109db30b8526421a74 +size 419 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..24cac350450f348792b320bbd64757b74b48964a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:37181708cfd498a42c52b35bda7e7f8e53d2f79fe33bbb5badce97ab7e4a7a56 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6dee1e9c9b67a46cf3bb307905801fa58e17f2f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca153ba761027a6e81093233805f135627203e9fe4b42746a95078cb14b6c3f +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b0806ac8edf41b2e83d7de62a63399e9c7777a09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef17a4731ea97162ec746c119be4f28692a05e2d754f03d1b0e078955ae6e35a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ff39c3baec69488d818d8e8862c15e6ba8697bc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d2cf3e6141978001f881e237a047125480c5d708c02bb2a8d2b8f8adfc3ca991 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..989257f2cd7879e01e0bae118eb99dc460a7135b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d60432905833e78c163a5ca441762a3457df059ee5f863599d7bf5f05573d206 +size 645 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac1b0d7e901fad6a33299d8096cce6f7180b04db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6d4572c0f1c4eb5fa790e3626f7625b2278ef32a7d1d5571fcacb8e1c4a4239 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ba5d09d21c650c6a429bb224f86a64d69ab8b056 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7c30896741da121fa904dd52b9512b9d1c46dcc2ea99073d445cdaf46255c970 +size 3323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/cardio/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6f116f2fba5dd8fc3b3d3a10760f8dfb7b20085c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5b571a95162a652fb0bf6963894d4f7bd0ad6af23c8d2e127d86ae8dc999d72 +size 900 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..890861bb0bd5c3b987c7bda6bda240ac57b5d287 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e427c6255a473f42cfc122abab8aac0663a8097a41c3ac82d1c937dd870df391 +size 514 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..23d90d8e9e197920c034ac32fee3128856b1ad32 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bee7ae165c8bd90f9599466bd937fbcc6382c85d4343664f002ae95323fd72e +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d9ea289193f0768b7476e5d29c6b1091d578ecaf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e6e0154410a192860debc43db1cc1bf95f1d64cc640e1be959ce864e14681ea +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e71bbfb5fe8ff8bbf9acb97402fa7f2c9752be4a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aeeef2beec0f188de9c8750c3ba9bff9ba497d52f60356a7cb1a6e307655d8bb +size 517 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..02da94123d89e9965060193a542baf1006d1e3e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5d8435dc0d389e501f8610b20dfa241443a4f26f0b490de7a2d3217e9b4fbaa3 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..82588f08417a5ac5d0b69922556c30b885479731 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26a4c16b1bef3bb88df83fe744e9fe90f7ae6bf920c9d8ae07001a367c8c1c01 +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2979b9f99debb0c439adf35c53038c5cf739b938 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:54167a575ecc0ef5b9cfa8601a300b5158e88351e24f2bc4ff6d5051ddf27def +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c6027d7b382d2b945c75241a2f2d08a06940710 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a89baf17b151d566d008c18ac8c7c932fcc6b4bcd600cce2606683d2aa0a235 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..02a7c3eb6688aafb9a1c0f16e33158d2194fb695 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c601b334e49062a1fe2da765c22767626e2478bf295faf6313bd704732c5e6d4 +size 968 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76d80d8440204dc23c300538cec7bb957590aadd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04804a5fcb64dce7ee245ec0ae19ea2ba235aaa0b63364afcac4200a76b7b5a2 +size 1322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0ae295960b595eda7c3ba37879df08b75c1aded8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebf7c222b1216e92accff79804b4a00d2fd44919d5dd31bc6a6e60acd036fcc3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..dbde9454a5b06bf37c29db5e87b6bdec7a036723 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c003338c5f3ca1f6f85454ca4ae95e5c1716661addb4736e5e4df477fba9c332 +size 6633 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..74d365aa8e41d2a522edf59c2ea076c9b3dbe7f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8a2a35828ecd06e28b595f77b8033817d57b2ac1d399b487e8913c9b99080b8f +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..74568be19440089618d17c6a8a09ca1250c8baa2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4597ad66b89668b391f34929896e5efd8143ec192b8dd09743a5f369a4726e1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3785c98a3859f8e1c87cbe724aa130a396e5c792 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd10ce7b695ccc05ee555915c57cfe784c6b193d66223143542ad70fd2b95aff +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b743faede98137b4da69b7e73dd3c37e68f66090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4fed4a225190587ae6f6c5e7f6e9222dee02300e601232414b778488a3722dc +size 963 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9f709c6f28b5d6bb427d30148e84c6d040da00c9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2da779761d080f7f5b172c2cfb91aed74a04df83cbae1434f4fddbb188835820 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..c58de36a0ba076ba18f7edc3eec2d4c86e85b59c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b2062ba7a64a8c780bd72d03857641634071932507e5028ab8569d0a6839ebc4 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..1fd295065a538b8d64556e1134450227a6ab8450 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1486d35116d842c5f007c9638c5f9a042f6cc16fe64e3013c495af69cd76631f +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7ee39b00043cbce7f8f6551b74b9caf8d33a5f33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aebb8344a19ee1acce6ddc539289e78027660b8a4a1b31412a337cf189e8d7e0 +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..259b9c28e2216da88f2de4a2ada5f41fad0f3f66 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225c399903d85eecfa1180717481779c5181f957bdb0f19181252966d8e073b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f15da93f1bd7db41b61ab7274b891ecc9770ac3c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa30c8613e72c13f6f7c50feee02b7613ab54dd1e83e855c5ad884e88953fd24 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f23f43a640a36e089355ff831b1b3337f792d8ca --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3525848bbb0c7286606562d2141eacc717f087121cd663688fc213aaec6b04c5 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..87edb0ad883ac38f933339b7871283e57f5824b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f81553f0c9478bf6d53738d42abc5d200ae3c7dcba6c65952be292b66ad840e8 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..37910800c4a09e68e3c9d10588d70892ea76dc93 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:55674c76480d2de69613c7e6b3ed340f4cd8264e71cdcc0245d50ca2602cb406 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d6efa05500f2c702f445ed863ecd0ce0e6741e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8147293b90e33b933bcc4f90367f4321618d12c6a6dd8062b34a30b527a4ed29 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e61dff9649ff3977e3095a15a1b52ecb8814bb40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4902b279f2280269a77b7716d7029fbc4138d8341241ecf70733f6c72c2aecad +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1717d47b45f0d8bf948c052a264464bb740b7213 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7957770c239db6b73a5f331fa0bb2a6833f357ab9f1f64a7b8b09cdf949c27ec +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/churn2/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d30f0ede012a7833c2dd8b4a4b770d76147c8577 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:19952c8a0f8428d5490cb019e5126a86ba664b4ebc8fc003c4890b9527a934e4 +size 927 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d4aa3f601a85d94ecb748a479d8aef67264e933b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:735c7bce4b893f0d9e465858a37825e849e4042d4f226f9f47f0683eae5bf81e +size 521 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ce2910d3a7adde56c554a761c5e9955a44ebe99d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6686b110d578fce74aeff473f802b92e7cc4427df7461775f7b361f6661aa28 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3960734418f032c074d955fe7aedd33694c6e57d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb99b57d00d4fb78c9e05cdcab9744c7745d8aa1f099110fa7443e283a822359 +size 3337 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ae426a48600b38c867dc7ea13eb3c93a61a29901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:92b8d1bdb969df86f55c7f6a142aee1c5e7112e3c6ccf99c06d2b6bf8a0f2c0e +size 518 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5a7ecf664d2aed9530c9d93c71b6ea94c78409db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8f02e8ac53b185b01b03c28fd7eaf41ef6f8bdbcd0524bee7abbf2f80d3ebdeb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..7045c60ead66c0e3751c7a6a1d51ab959399eaa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0ee8dc771d2fb906975727cecddf706e80992b06407b16e43fa754c807005f6 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..cff6db9f8bd0a9dfbe13f3161ca7d146a8b8d9e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dd27a87c527c36e6b159360409614c204ece2116e30231f22c504dddcbcad72f +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..99b9db3416effd012701e0bd8d1a0d077a7da75d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6f3a62be3bb3e7bcbb49a451de901401bab916647596899f5b4a507a92073f6 +size 967 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da6b9ef6dd806fbaf4e6f1b3f4906c09487319bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ad87d4183c7897af8fa6d4a05a27527358bf028b3a7c5a7ba9c340f7618bbc3 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5a402f4ff2521978ec9a1cc58e0a87954e46948e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d11c6eca82e0a9100d0d50d57a43acc0d06991b2e21eb6eff7b089245368685 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d92579fd95aee209837d45082b3b356c9716ca8b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:15f8e3024dd62268a2398a89d07ae61e96e1d41531a74a919f3f025fa938c5ee +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5b0a2432100fc991c08f4124a8690c4a7102626c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db7e6bfc7b94bd5ad744097626148c79ab7334ad5cb3de320ff4f8b36a4e719c +size 259 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2a46dc0294af8413320fc3d932da96d5ceca964d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a4f55e7fd33edfead9868f09aa942bee3a0d6dd071564fce97612f875ea8160 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..bc3c5d4770e88eb3df2eeb57fd0a36b2abb756a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0718b6963905101eec88b075186859e2379f3f61d70f492e30941b323072c94 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65ed7fb261953c72d2734e4d1dfbd5c1fa61ff24 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:206e30cd29010a15d526d9bf307ff9e220b93d9d65e142498c913baa5b2e6794 +size 905 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b2525ddf750cb43cb10446426478ca0d352f9d87 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c378d9fa551517824323a936dd4bfa1176ac6daa2ebd7a0948e5537a27e1b64c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f6999ba31d01ec9f118325fbb37a1bdc1f1c97dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25ac461df4235687a4012bf375919c8416dd3d5f4934002a33a47359702f31e0 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..14e1055fbe71324f8d1b316e7c42fba105dcd5ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4df813362412b44dc398a2d105242831190a9f46b54a0baf14f319ab9b0a43f +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3a0d3c9b2e132ba75b354c6d433fe5c6e3dccf69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1903dbe282b8414db88bd733bed0abf2cb61970b92826102a0da5e3cd04374 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f5723c53a582026c2ee3b1e92972272e297ac8a2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9fbe41349d882083cd3eecc13ca6f3af44bc47878ef9426ecf24ddf30aa1a1b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1351825de5ca06090b694cd42c3ceba59d97e794 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6358398a28b79dd57ee851c40462f5a514180d6d06158a58ed104e9af3b16dd3 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..44ecb044b241ed35d3bb8e36d0d236c93cece41a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f7abe796aa6e50dd2efe53f6285070f2b3b38e68ea8e02ab9b324faefac47b75 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7a22dac1ca8ef349cf2e70b8e8c3aa8147f43bba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6be0b028d0c36c4dc84cef8da80044c409ae99bea5e4032a5f657e14778d0bf9 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d79bc224a67304eed73f67dab601806dd36cc011 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6a642fcfa77c00fcdc72b9601b3ac97ce51ffa4c6ed8597fd40fa813c6c441c +size 578 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..07c8183cb7a115a895147e636b4f94c773b98112 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:229cd05169992e974284aef4dce3a714d7f621072d7e3ba47bd0147d952c2032 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c933269e3b15eff51fd2530aadda7bbe13e702ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eb14e8186c7ee0cc954ea8c674750026de784be55db0371d7eda25ac7119a74a +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/default/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db8a2977a47b2e060bdbf2c7bf7c835c7ac3b701 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1044d3337e80aa3a09e1aaf07c6e0f944b8232c70027d2d650c99a29cf4ce84 +size 918 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..64169b1082ba9f39304adafa7713b56f2fc1cc5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1d6b146369ba3283478dc5a0016a8f42ed56d7df0a9057e41604f197e5cd4b0 +size 534 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e2c3ce3255a8b50b919da411cdf7186713c7be4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16cab54b8dbe820078b4538ecc0b3a44b264e2c1b060dec84f891ecd5cd8e2da +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f565d2a7b29d12eda6696ce249df33284dc3e942 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a89df37209f3ea372a4aa65a723aa80ae696502d7e39d61b96368b764b41ef3f +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c9238ac80736514455ce9f40ef17558e459f3811 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:020ad746993891a7b7e1e3680345c1d05515c059d0685a126c4473129166e150 +size 554 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c461843206ad3cbec9b3d2a03ebff8734dbcc8b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef0eef618b42ccf2c403385457cd075ea3815ac3b323206e0899b30524cfc7b1 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..45028174fec008f49746f487921eff5a9ecabda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16f7e4f7a24d25d699923ba9731a92b9abbd4808ce3dc14368d657114f701ecd +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..9df42bc64e8658d641d774b89b55bfa9cb15409a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5490d1e7ff5355cae1350dc796760ad6f75259ff7fd92387d0c18ffdffc3c85b +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0d61611df3edb22a4fa7e17866b3528ae725e646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b22a91aade7709026caa9df573adef3919be7295d2aa42f8adeee2e4f6cee8ef +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..1e3be13787ef2353940c2ff97f4e3c458b859d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d554d53508f81e3d86513abaed89d81369c452e67648b445fa8e245bb8fb3ccf +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae8c50f8789756015254621cee945d1bdf240692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:619f95f0490e193ed51da45ee60e9fdb393f6ee5e441117bf0446d763304ab1b +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..406ff1087ad01f0f5924482b967d16b657344a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5970542d676a9e85db91793c1a6567883769ab254860f446948750825e715d2 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c97fdc4bf623c0bd2820e22b138e0e8db2554855 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:74f92933f99075ac5696382e6a75e06808873d41d47ddae66d1bc0f73a87dc51 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..c6548854b54b44b909f204e40525c40e25142db7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ea4fa210ad435e41e9bf2632985560871ad757febc593f33fc1c6ab9fcf52d8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..eb6fd2749050c7886b58f0521b256f7f4d054875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c50563d980018084c24fe631e2b4a5f3c37a4c483d5d1f3f71c0d1001bf17cdd +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f4e72e3ca6322a41543e3b2817a682244ad04229 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b41c4feba56797309e908d0c41c8a91a0fa443c9ef5813c34daa30b0cb61b9b +size 951 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f354a7eb9b7cba64e1beb92da8258b3df548716 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0502b6755b48092f0e9ddc0a1f9e7910d8c6a6febcae015f5fa52cab91da1b4e +size 659 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..d3733b848b938dd807ec0a3cbc198e43a038264d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91a7a88913f932cf51b78509880337d29ce7aee87fc0488f5c686615f3a7f1c7 +size 661 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..93259a0b10c64dd8521ba6d3778a597b9caa9c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b9e7252bf842b1368f383a1fda59c5052d65cfcd691ce22185b0b3bd3a15e94 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fb86c4fa071f539308d8942d26bc788ca701dd7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1684541d340d8245725a274cb0f3a8df4269897bae8c0cab5ab13c9ec3410c9 +size 425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2c465e0671a0d8eacbc90fe6eca9bc28592b154c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d6e731c0d11226bcba2aa47683a707a8d0f85448d76466083b2c860f14dcad2 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa2b02b1418f83403abb6bd83fe1fe510ba64feb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1930c824d53c8691382820704e0cad315325343252257232c15fcc7ced22593 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..80d37feed69d46b96bef16cfad0033c3867079af --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a2d82505f43d7cd538c651690be0eb1b6750dd63ddae81f3da55f3366de78cb +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..3047c8a18b85dd975e5a5fede0fa4f3c4924e447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0b8decc62991b71d8d02bdfe76474fae54dc771e37cb7e5cb388ba93e2b5f63 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..12c19d9c8b4f9ff69e3b8b64a4dd72c542ffb26a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e72aa8a518936938f25ea7332941c9797ae045cf0aacf15b210496f546374e6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc2cdf43a114c76d6f4d2f31044559cb0ffb41b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c2c01bd6c97390826b97479ff7d2e267bd8a938b2d94838c2f2011bb2996b2dc +size 612 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..55801536016e53760cefd438950112a0ab992a01 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f50a6eb92711153300e23c4e8bbec37739c833cdbb38b12ea7e58e9e6689dbb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab187e19301452f9b46d116fd253c282a43b6d0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91404eee27abb530eeb50afcced5735db92546d32521326001405be6a5c40707 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/diabetes/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..333f6c895f63304005939bed734c5b4a3ba23495 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1bd2f7237c6614f727625e42237b558e33e022c2fbd79752fb3246f7b44eede9 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f7158576596ae7788b845467937ea3a4ad9b7889 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f1723bffa9730b2dc8d2e657be7336222ea277f78a841ed2e9f575416ddc7b4 +size 541 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..436b7fbc02226c3d4a24fd72c27d268fbf54b790 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a79a0099644def29c2966fd35dff1dec2e05baf62b955be7410128dcace002f +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..8fc348a12063c0c14bb14d84fe5f3f42ab00b40d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:519804cbf1f8f280277dd9beea08329578e68c3b22758bdb696f8178e57ba3a7 +size 2505 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d221aeaa17043ac673ddfa8ace328304852d5f9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e91f5a1d1f3302edde0c65a604cdc23cfafe6c0b418cf2a8b83b841c7c342b44 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..61fd254efcfbc44b3885c31c0616e157f66e720b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:601d66c4668274449c4a46b98255fc3bcea1cbeb0052f0936ece08fe190fda5d +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ebe53d92f95f03144b958faca7db5cf3e15b1a42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17c0e6a89a4b5bc58d756d439888ce605ef74efa9b177a8e8c6af9b405f1361b +size 4800 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..61c51c1d3b9ad8057df88c53dfd6a5bd442fa328 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d743a8baedd8c4c815620260fbf23b7330b1498a3d7b26f84fd1ab4ec64a1b73 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f224d16ca9341abd1dae347b7de8de6fbceaa3bd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e2bedbc213977a3b3fe5e11a7c04b32ee3017838a7d09a887bc460ee8227ff6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5ffd2305107e6b846c8e211b14255e83446be141 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3cce986a96cbf4423cf1bcda4f374410adf9474e039fd149961c8c806580c03 +size 413 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c617c43c04116720c9d654763c72be848070f707 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94eedba18072bbae480e6fbdf10104f668d6666848d6365be3c36cdc9bd66a35 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..85d3c0e39f51b351408d4f0435173c1a395eb070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2392f0e4394cd09cb0cd45b87aaf5188496af4bc5ccb1cd946540678a31fe655 +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7278ce874ed61570ccd5c1763a3aa160a24d8499 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:048378c429d0dbd4891b9b12c50903e3554e9d84114bc23846e0b648b579d1a0 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fced6196078064e5431ec67e3ca68252a8e1fef6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7b25fc4d49942d7b08d84b9168f733f4b9734d568962c4521943a3c849662f62 +size 589 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3d15815d1593a179fcc73748e47a4ab5fc2af4a0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0a72d23a0ab11b3df278791ad149095aed53d782d7a6ccc3511f4a860f80970 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..55d8628bc23724a14f674ade448134b1567e4520 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1db91a1ce3ffd88daf75415408cf9472ac868bcc8168a0cf75366dade0b5caf +size 2408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/fb-comments/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..06bc386a1db8469c5f21b3c8a2c81d1741dd446d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0a64df287ee37f9431a592eb17b0280e440d02a003fee701ff2945ab5c37325 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d7413f0670c6edd7361c9c7b82d9fa85aa6a0908 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:32c35703b248e0f0372b9e4612acc3a640730c95fe5e451abbe4c15731b5d6e0 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4d367e9abe1b44d5bb3b0dfccd75ea9967e01916 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa6e6bad2cf4145ea9388b0d207adc07ac8c571c2f779596e036e32e42b09fd7 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b10013726142a28b922fdbbae928562aee46db9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a12961a2ed12d47994fc41d22bc8f7f7e8d4c958d0d73edecbdcc5f8e07b4435 +size 2395 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..047615bee199b90843580fb20f179582f8f09996 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4613d2c2e1fe45c33d3545570f7cd4c035281c1909252be0415c0b95e298356e +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f01095b225b915cbb53e7577a076e32017c1c8e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51071871bd60b5388d81e23d9d36258836180796270dc482ba564e9621a2a643 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4d08b1150e13ad1bfe9fa4bf5c4a564a07b0eee0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30a844cd0dd2933bbc3dfcab3d87e669552edf034821ffd0a6a4a18f71d813fe +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..348755b263dded3e570682a653db8f053ca1357f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b3e6cd385cf4f905f491d54e29cc2ca35d9e6f910999af71ba913b3c5ef802c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..feed14b0f46d70949715e5e0c01a36d92a853510 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0993f5e522483b64d082bdea9503f95aae33fd65167630c12d82197f46c6dbc +size 929 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b13723f7431bf66f747a541e4991ee427f7c149a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0b25543c558ddd0bb6c114fcbf3e06b3c101f7733543b9013a9229e02d394b5 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..3f4e583bb1fd4b2ba0ac11ec89b8b9e2a2a9f5e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0ab5ece732683c2d181b262d5bccab99821fb12b880ceed78f4e040b8c31993 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..28deac7fa9e4a94c6242e0f0c6ffa4f353e8e08f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b63b0a26f2f87c7d2661655b8c9268aad1265ff4d7fe4f99535099c6b36338dc +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4c7232e3157e1133cb14ddc0f32436404e94c0f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d63b0ecacc41763b74551295b1542ce7c29c00b558c404b533671f3200842833 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..10d829f9802860a47baba3df9e9d8f7ea585c8a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:951c1d3750cc6631207ca7d6703a58c674a0409ab2eb63370aa2d5ba4700d7c9 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7237a8277a25f0c18163cc5c8f02a0495ddac37a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:11337372964d7148d6daf843a3f8a8456fcc2abb21a7d3bb1b2d71ee714f139b +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..24334b8d23bc604089b3b05e472de861477bd5f6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:48e3c7798c169dff4e5c80a35c11bb71eea5b91b14cb3c80f1ab78fb1cc8b34e +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c6f4f10d7bf4debd0e0baced9bba617420fe901b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d055d710a9d9743c9088059f5f3ac687c3b4a0039ecf6749df6f669542add73f +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a32da369bdcb78b612f903c8ee05338643be7afe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:398f0937631d218f8637e9cbbef1383fa54bbb88b4f9ffe33acc1a836a479d29 +size 2386 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..03d0abb886e6c6779a9ee57a90d867d538b266d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:be8a997b12a5ec6cd39aeaf7c46fc98936f8611977942d0474a0a20255899bdc +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..497c8110776c7faa8eeb0a2a35accc0b0cdee6cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d28d5b507fba9281f6f44380755b807674395417b853bd9442ee8ad52fd0f43 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..45c057f2486ac293fedac404bee4615cd59c1a97 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1099d2e1bfcc8f278c6b0a4cd6688526707eb2b7d80c7ea784d2d20db8b3da9 +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0754e116055863fcd9138a0aeb61e3fcc087d219 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00542b3e7203234bbf573df38c9c5f06ddefa0658f337b5049ba8c35a4004905 +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..800189407f477c0ac2ec1e17adc27f582d5d4a7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:97fcef113d1275c3927abce0ee6745447b6c2482baaab3eea683c8cbcde7e43c +size 2384 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/gesture/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..03fedb7c3dc25ad84d634da3a8b9380a858b678e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6a307600a0653c256432674bf2aa90990aba5f6a2a106e98e9618d588dcc7b8 +size 948 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ffc4c8ebe2fc39c897e30d7de49fdc1c2d31a66f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:760a12bb8b1a4b9ad522cdd0b61eb121b7d284024fd33f55493d07f96c1cdd5a +size 542 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b8d4afdedbe29648262787959ef96af1044f5f4f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de053c21039056c72a5cc3f09c7ddbf4ca3f9d16a7470c2f151e8c2c5bc461a8 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f8f46a3b3f773b4b986da71fd770b536d8aaa389 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a213faae594be359b84b406ab2e095cda9db5f9ab84e615970f1704259419fff +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..39618b0cdfe57e8f1b175668ee707b4e9910e808 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b991465bc1317d2e6ef0e57d37db6aff1108f4e6b492153c9e8389ad2512bf78 +size 546 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..75c93249436dc211b3c88c2dd76b0ac75ae03555 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00ba696dd5ebad1b715361d289aab901914cabc28e4462205016e273fce0d66b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..011849d3f534676137699f3a314759da540695ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d55c8036621ff2c9b35825e8268b11630b73ecea40c3854395f027fc44a29550 +size 3335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2f712d395035e226a28266e663d1036707bf132e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cea498edc79f0cdfa0d9cb168b8500a2832a3a2089775e33587710d887beb4fc +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..dcbb2d611176a2d8bf2043af45f560aaace04ce5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20a3fa610b0ea4fd4c5b66bde8f49a35b185a8c74908324bbb603d36ed4b7428 +size 989 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2dee08d78e7baa81ad1f2a43ec880583703c019c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c23a761b16ed59a3bf4294de51155c8fecd406103e3a5be1c757d5754d8acc6 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0cc09486dec2ed58becf0eac48fbccd216ff907e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f508f21ff5d6e2510fce419fcc73db98fa0913b263a0aa8074b3b588ed51b1c +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f950dec45a8f48ebe7a2488eb48e30043f36f109 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f8469720ccb837070f8d1f0b4b63151ce8e6434620f869b7c5ac9ff36fdc1b5e +size 6634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8e705ffbaa56cfed732689cd10dcb69c4decc919 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852e37effd946fb65b7f394fea65547d8f8f3890f63eb9db6c06a4cb6503e85a +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..75556e02a7e1071f92f499e9b9e13ea1d7db7c6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2705772e9869c7fca46bab06caaa10e427e5a1cd4d6ab5042a6e279a22e720f9 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7c62e69622e87f6d7e57ec9c82c66d61390c2d18 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6561fb96f7fcefa5ad991ed8e641629aefadb88e54ad82a072a3e83e22ccb35d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3f3d1c6e95ec4d69e9b8553aac109247c799bb91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c3ca4a3f3ead7e37b28bd406afdc57ac1739d5ef6508fcdc0e201b0bbe4204ec +size 414 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e4875ccf24467d05d4e8cbdc06cddb4a5180dbd0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:344d767fe2a9eb740e16d18883d7741ccb939978a3b99d7e73563766adaad05f +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a52d447e1aaab3ea5f028cea2de591aafcf45424 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d72f0802d95c5420400626fb325cefc9aa236cb6dc58314632ec5d4169c4df67 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6a33a35d66132cbc14f5658343ceacae40cee5ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cceedc073ade6c8c8c944873e34bf2938ac96cbcbb6eaf05954c50b6d9085e4e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9e8df7d13edf6634d616b42d800942e08d955062 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a557708d6af14a05fa86398f34357b5d6ef232e4296786a5d8e9ffa9c08c538 +size 622 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..25679afa0ba5ce7a6c2a746f04b2f46f0292f4ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:615fecbbd6b5ff85730ba4e9fa56efeece74fbe38f9ea1bf618d440acda6a3c0 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1cf49237444d6800803452dcc9bbedeb8bc8e950 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:927b6b4caf572c95a34e24ede594379a2c1e726db80161d2947b1593f0cdd138 +size 6665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/higgs-small/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e7e2b814e25f5bad1bf9fcc595954e7298eb3ea9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:528b40c2d3222184ffe33f75d19cff368f89da842a9ecf026f79d5f27bbe5276 +size 937 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0a7a4de2400da5fd39dbaeea852e919158901d45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bd3302bb25952c83194457388db6fea312a7df0745ba8ec476a158c566d70cc +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..80c84796e2f248316457ea713365801da14d237b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0a1bbba8b256a7aed551747d9063887f788472058b7e293948c4d47e242d23b +size 469 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..181bf61c695df6664b710767b0fb71afc8437d81 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ac9e6f524f29c2632ed8b9a2646c5425a50feae61118d3132d65320d608d19a7 +size 2479 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ff88133c4fcb328ac7b16552747fb8296426105f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225d032d97754931a2c9ee8811d21e445ceffedcb5035ccf634ef48ff87302ad +size 995 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d20d4457b1232ba47edbce4f64cec5f6fe7f1c99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9c7e4b3aea3b986a6636149776c64ddddb2cc600f26b257f262e4b56618b3e8 +size 930 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b8ba0ab926f1cfdffa5fc258c9f4d77982ce44d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:666746502985de8e700a9fcc0039bacc9bd146af432fb05b82b54355ab2424fd +size 933 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..042dcc933ac97e20ed3a22ff880465b27dd5ab9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb98360a56b180db06997eebd23a60482932a3747975bac918508bf02f4fb9ce +size 4915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5fff3289c7229732080c62d40d12efc032146f78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a7328a8b0d0c9a7de6226a7a1b8e514564d3c1083eb12c4ba617c5c6807e0228 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a693dec0d8434fab0336b794dd1e28c68c0241aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9045f8011c485cb55e81c9b4e95ca0fb052c9a3435e35a69a97b41797cf282f9 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..b7fb08dad9f572208abbeddd84e0740aa356c230 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bcee542673a48e33a23092776d8e96e6c1e4f3b21b7b8787d1f3a9073f218f91 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..adc4214b1b074d65987ed797ca6cf6448a5747d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ffa43c89ab8722792d7bcc54bc7dfcf5d41bcf20e3f3abf3d8e88a5b98e5978 +size 952 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5724f365db7fa2c28eed384744e97dc87946f445 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:23b8b7b4d549a42eacca574e4ce2266e7c8bceda5272a33c987eeaf80b7499a5 +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..2a998cf2f7de0b928103b222f8535d6c0a047e2f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7fe0b81e4deea87c242192e524807db9ab3f66e1dfc74aed2e3a78bde723f0ff +size 294 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0aa03ba62b1f302975116c4708a8a2efeda92ba5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2442f27f517cfb43bbaf59502be5cc6db24b9a097d51358fcc9df365d552dbb7 +size 402 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..314883b6eb24933d65156973e1afc1b27172f10b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d4ffd3b7adf6fcf1d327e847091368ecf0f71b40cb8b90436c604dc8a54669b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f4655be603ea1109fa208164026d376cce26be50 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b70d420cdffb87014e9fd9ef019ffdffddc58b56804ca2e611218f803cf28ebd +size 2458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..d624e6d584ff582a265185a7e5c00e6263171faa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10dce84b0bbee2494ea0aa43beaee9c88dfb5a403bffe74defa700d6c785999c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e4e13829933f8764d73215cddebec4a13a2bdc43 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ca465ee811e532a4c5bef81a989ec7d2f6244a5d4742d0c363f74400f207d533 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0553bd45d276e79f8b49d933bab6b0cf2932682d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:200ede2a5a9a98be57706e3fd0590aeae7ec160b4ac513f18623c24115764bc3 +size 574 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c071992f864790d496ae83ffbee48595a2ee851b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b6611f4f0149cc926920743e7476379b114acddd6afd49d1bf6d21f85071ca6 +size 470 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1aea951026ffb023621fece858640941afb21e9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:861abd015a5284bd3a0f736764f7da77b85787132d418ee479a80208c480e7be +size 2465 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/house/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..2c731f01b582631631de6dd5b69699a73dda7413 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82f4a7e5f3e84c7becbb90e602fb8b151e344a33b3f312e8e7387c05994688f0 +size 942 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db7dd19a68e8eaa1a90ac71139a334fb0687f77a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c9c1217f32b6b6726f227a57f803421e181ba4e35157f1db5f9ba914658f5b94 +size 532 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..82defe6d7f8b1ef7a378ca83226604cef31b6aef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd069f690164256d25dfbde0ad8790f77b5e232dd3f0adf64410b640bb54c231 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3cf46d58eca19c1941ec9ee42c919739cfd8e614 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4c846e7b87f5eb231776d149668781c3c940551ed2fa64ef6a5954b49fad91d +size 2460 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..82b2a87a76a82cf7e0f9098ff754cb6038329b13 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d7188e5d993b28be90477dda30d16dc4fd1492c0beb9938af03db9ac3093d8b +size 999 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3bfd8fc770eb00509cc2d7c43232a98b8dfd6cac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cb22042a278459b9fcb7136bbb89dfdb1f13ff0258629814005e0cffbcea145 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..59869ca6d0de7c94394c981e70dc95c0e1d77a48 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9de0fa18e75155189845e29cc0befcf4d490d93264d96daf62cf75a30c90266 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0676cea17ec67a31e17a9cce1fdf6d11fd3b227f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89bc8213e080f76469119ea5b91e606453193d49e4a866cc495b0a589a9a0c68 +size 4889 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f0ffcb99149d3510c70a5924f8c422c8a76150e5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:43b70402cda9d2dbe0bb5b51677c5c9882bedc445928c28a8c3d88f0a7722597 +size 261 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..6726199f5fc33e63365f3a27b1d556e34018d3ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:323963077416988f3290d9e3816e6550f872cd8744295396c19e5b6f5dfc9c14 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..2f84826ccac5e886b0d45f3c7c185c7f194576b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc777a785cb2c512f87e6116d47f4a3d9fa5260f629c979d6bbb23839473670 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..68c17c15294f2a17eefce1027bc156e07915aecc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a64ff8200cb6bb6f30ee4998d6aace8fc8066b3c66b8337b16a24f0b57f4c8de +size 956 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e68da611dd63a6d7d426532a1ebf0e81cf3b9ea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e8beb48203d2108f658644d5cb799fd535d800dde8c722ee8e5bfa2bc21e153 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f1e0cfac11b1db4108d81e074b24ee18d854dc1e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a8db2791e30a92cfd9d3fb5d6186b60cdd93fe10a154ad1d3f6c0d18c1f83e45 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5bb618075a1cd648a4818610f2382e789cd4864d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddbec95d017fd0f2afbfebfcb57b24d887f5f2878e4d732234866172e05cbb +size 304 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..96cf783f5a78a8b7ef0943912a1c8a4e7c1a9b04 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8325b46ce43140b516ff717a80827ea672bd68ac683a1d57bcdc8339d931fac +size 408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8e34e5dba6cc530710d3f1cf3202447d4f58bc69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9121c85b1e76356f3655e4188d9df2b4dcbb6da03d44803100e78f535ce1cc90 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..96a4fb49c1309ee79dbaf34b2b2bf4d72897937e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ad727af1046c6fda6ee582100b49c9a7ed67c1c0c833b1738d205d0fa7808a +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cde2235be891eb6caf968e73420ccb7e93804e79 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:21c2d26d84679802f8b4132dc40995239cd6f33e70767dd3bc120baa6823d895 +size 2451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1d8ea5d488d6df9d75a1923b24f3125b08db535a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e76cff7f9b4eb2fb998b889fc817cf39bb249629db4daa02bb446e67f07508b5 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8caac97df53e7631ff8245ffb7f93f77993cea33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a03e4df9aabb8171933be16412b46e6b923800570a38e64e5d4eb47678b24dbb +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..637a56dffa6df001c96821966fe51c863121f1f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30af5515640c2f6e99eb4c3c548da06f3655333620c97cfaa8cc8973d656b9b9 +size 613 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b2ffb33dd7f41e85f904227b5db70e908beb69b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:935545449f1a16d3bad494acb6696a8b7748aabad97ecd0ab08f8207d4720518 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ba59bcf12636686aec9d51472c29b53e312cda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93c7fd438e02f13da168a75942fa3f688fe5bcdea85fa36d0d3a7ea9a5166e60 +size 2453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/insurance/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..01b0c1903a668d152e59453c4e4825741590925f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2501990a6f1a9971d56afe74d8325eb72316b430eab61f47c20a4733816718e8 +size 915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..23caef05e9d2f190d9c86804e5aeae5964c0a74b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0410035c53684e65b6334f5656d05b0f07bea79dacd6572a2b4dd53997c8d9e1 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..84a7af1afc2b623f4a2d67bb18f87acbe786e635 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a52646d49fcab248f6444fd18ee3c49d18dc08626d7217040171f968fe3362e9 +size 474 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f946659046f385d36df7e50003affca94254b83c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5c540660e687338c470bc5aefa1e709ccd01c1670b59f7ecffd2787dd1afc2da +size 2494 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..89dc12ec8c39aba29a00ba8c25104fdbd2ba42ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0e482c20284d6d6000c0148e8d374cbdb418c41f2c1b3ade6319b328b1a6a02 +size 955 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e142ed3b2f59d2438094cbe8677e78e8c04f660 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9549ce6fe83ea01af03e88d8de5fb0005c92f42b572c47b8dee23d8dbfbb67c +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a73dca158c0ad485c1ddf5a609df587a5995ec9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a54c016ba583d3ef7edabe2b91352de11dba9ddbd0a62b7166ca2494c6277a18 +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..9d034d585ff4a822b9e63c222e54536ff12c2a57 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5972998ede37836bda6c5e6eeb12e20c861d3909c4b744f6dd58459495168f3 +size 4945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8705207de466575515cb19bb0881cda69d13280d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0087b68b0690a0d317050eab0c6368ce49c6798a84f7bfd43029c2b0cb9cf1aa +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..60be27b26835fa89f9ee4b9579363c81b641519d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f114df937a0945e54dc4283963aced75bcb1e5d5fbd416c5ff5e7e812cd3fe3 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ca413e55e34e5a914ca4b0ffecfd729517122e63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d0499695456bfd89bcbb3e16775dfbf3491afb98b31a6aef86406f485bc2165 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59ce7d1bc92bf414ea62fd8a190b32f3b8ac6c5e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc3ec78379ff2b32d2f5a96626e368cd86dd2f41195097f858a4c7df201405a7 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..77acc58bc044cc342c01f2499f0e486614a8f070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b185de1dadacab2591684c34b38139226160249070984909d5850f69e8be919b +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..7b1cff297b211e9d7fe781917de6cb1832d3ffaa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdd2ac1705b46fa74fd91bb9a9d298ed2c2619522583f2b04e6deec9507da733 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..eb3dcf1ba4fab107a4980cc00e2947dae446a951 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04e492ffe3461aaf60a3e057f86b7e53393d186e1056fa50eff7f58f79f10dc7 +size 398 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8a61230d936a15c4a41d014a7363aeba42516d47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5e598f7893e22d41860ceeafea212a0099f57d612b866a6712780c54f049539b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee911fbd3baabd3aa7892d4b0added38441098f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6611343af6c0bba0fe21919246a40ef932677f1a34a511cfccb5396c6298e73 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..68c9b9046264a2174c9961b75eff74206ed377de --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6857de43e22b45c9e4d371ad7c24ee19a913bd39e60cd16b1a2f3229cf5038a8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7926254c224b0a0f65174156f0fec386102bb541 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94644b28f3612e23555b0475725f1ad18f9620b7acee9348b501a40852bf5b3c +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..619c2e20cfed2e5293d150b872a5733e1f096c11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4fa9c2b6c9c0379e006e4490691f7ca47d95732a984433835017b5dc8c6a4bc +size 572 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..a96478c5ab30457034d6a7a0e1948a25dedbae3f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b221985167ba83bf9b2e8a913d0e683a9a71701aa8a918d674c292180dbd85b0 +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cbeb7697694fa8b8ca4812825c752ecb6083aa7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:194eeb00b693f9f992dc12f48d96eb1e99ce8fa94baaf7a28bd5ffc83657c390 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/king/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59217f5e124abdb29822b055764cb2336192324e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d27dd7c459b26f8da75d5d114d757d3504c4e2ff1fabc9145ff0163269268523 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..a21b74b88b43869b7621a6fa69ba3cee54f99782 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de9e1c2397774b4f140e72195d67299087201e8f7c3398f553a6ddbedc37dacb +size 548 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..dcb82579a446de24c76a01048e7ee8b45dc416ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dcf46d3c26fef0a4bd282a1dd5540c51306a6c6d27a7e021bdc3fa1f04aaba8d +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b964e2eca120d5390d8dfd54da9bca84a89b0964 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b1ecaf38c6e4e86723eca4b70df721230ea37325f3e31417136f680ab6d60eda +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..005f4532ca87e7bad99569be51c03d60c2e731bc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0873d39afcde743c203e38b936cf02263464359ed77ac9a4f897f4f0003ee8cc +size 543 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..95cec34a17bdc318a6f58a5142d836684ca8b741 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f94910601e7921ad016dccf2efd73b43f3ddcebe8222554c961020572046f8b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e263b0da0906813ed00fe2505223f178721e46da --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c0ff62cc7415bfa76cfb5f8675f03443908fd52539f49078ea10f6f78f6785e +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f75e316f0a7cdfa1d46f9089211b3bc1790045cb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e11ee201bd58bbd68ed03ac5c6e098db1691d6ba740612efd613d2e21a7eba5 +size 947 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ecb3c2934097a8b7eb1f1c2e8bfdcc1bb6c25cb9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c24ba2f25d79231cd18c84ab6b5505c3800302f52c60ea4c470761fa0664826 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..318516c152168e5aa47c6ec1b99f2de9abab8478 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f11aad0bf39ecbcdfd2e236f22f5686c5bf53941e2bf72066b650a0495bcfcee +size 6636 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..b877e61d6fccc1cf63a37573330494d8c250a097 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4f4ef7a360cd7c0246258ceccae40c700bff07b1c2450aaea29678ec997c8fb +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a4c5e18b0426ed2e74a44a403050bf1a5e2be397 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:156845e255990d64868edf68e6e94e4b630a35ef3703908d4658bb4205e6f520 +size 219 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..07359eb10ef90d970d2fd3da8589d23419ba30e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6eb570950be50161b508f032ab7b386834970b1b8320ea009df29b04fb4f59e4 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b71c94cdcd14cfc6ad2b5769feeb0e46b742b038 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d399bad7ab925769e8dfe3077fdab3bc853c456621aa535dbf11b13b649442bf +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e434db77ae4112e9c66a54159b515bcabbc35500 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:daca0ef299413efeb2fd8bc598c2884ea7fa8e31cce9f5b22453149824003a31 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..fe89340b3e1abd6c60af42955bdb945c8c73fd0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d264ff9ea11ec6a85605548a246318adf764036594d2487c6fcd011e0451f468 +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4e0b74e541216117ba45eadda4227de72b77a583 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86e468ac66b04c5880e87d36fa4a0d0f3a8ccab2d862ca9b2a087704161aaf5e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..8e31eabdede3c3151591a3355d35481bd467ce49 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4fdf1a753db96dd0306665a4fd7ff63d384e63c5e38427c3ea885cde8bc25758 +size 564 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..fc3508af285bfd1620c768ae0ce85d0aefcc3fed --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ee426c8141756e86ed8ce7d5e105d1696811c92fe3065d5f9a542fbcdb2cb41c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..65895fb508351e878a6f865720c80608c59f1419 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aae996fb7337a2dba7582f817f088044dd4fb6e356600663f63c85387a24adc +size 3333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/miniboone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..126909bc3023b69440daf8f5981671a32775db42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0a8bd128e8d1a59c0fd1a6bb71d659c72bb66d99d25b64a083055aa5ae633481 +size 903 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48207110d55524677f763b36f2ea6d082538c8e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df7a70b973fe406e3364c2b6674fc4be7e63a60edaf4bd81fb74939cca9fb1ea +size 526 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e47d814bd5c743b65a2e956899c1a85ec99c2971 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdc03d3794d9a6fd78252a8f39e39f6a821f2499675d821b05ff4512e594de7a +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0d59d5db6217391068a935e4eebbd36a7dfa9797 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c65acdf11e5ec81bcd0551c6ee0e1bb1da03acdbf8fd61ce8cc84b595e4eeac +size 3326 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..992ed273159fe044446338ef18d20b301c4389fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:abb13507a3bb052941db91eb54f82c61763476196c0f582cac37b54b205a63b7 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..113e4f8760a40e53ac65debb316e5334adfdb6dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14c54983a20fd19a7ba0656cb4ba0882dda6ded11e1a3be406d047acbebabc21 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee4457b8f96d7e9890ea1b76a6c65bde78330030 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c10fd9c09819253effcae1c1af19dbdf17bfdc061427e24047454e53e300f57e +size 3316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..fecfedfed0d23c1f5790b4d32fc72b2b927abf9c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61cceaf47946a5b94f37258fa4d53bdae5417731ec3cd7969824506746355ef7 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7040f0d2c1d564884b20d1aff4f998c352df6e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ec6bd6a69e0b83faae6acdbf6c0d22d33fa77f18fc9aa4dded05cee01d011c +size 958 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b1489b2408568ef856f9b7691a6de90395656d55 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6760aab482af996cbd94742720668a0a900919957db2413eeb1f18f047330ae3 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..360331f72e267548c985238e8dddb33ecf33efa7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df86c0b6c8fc0e216a53438e3f26bd9e46670c1f5b3dc77426259c971d210f3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..15b6cea0fb960e83bce61a19c94bef54ea0aaecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f8ca0f43e784616f459b84a576d98839d9abe41af934709640dc8e81efb4e98 +size 6621 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6e1b013baf19c0e01499e397492cadb90ffd0cf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04f31ef7049dee20af09577fe45fb41d805af0907e8e137ee3516d0e90d2554f +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1a8fd05bfd33b99eb361fba9b6bc1c00e7fa7d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f42ff2e01094cd2102a388e7fd6124eb7b7cbf899b465cacf0860127e4c99e78 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6c0fa171f2c97dde10256df4376995c3177a281e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c87fcede2165d9a1cc54de5f114c0cfdaa21c0dc8a1dbe6ed1232e8e930df025 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..533af56ce20919d8164fa0093972d0f1209ac88e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:636b5d5b2495c4c123f00fead30911369c615118fbffa66f12610fcfc4c730ba +size 936 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..88505d5882f86ee3507f9e953138a818dc57caa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:722b3ac7a315c79a1bc37fe46cec8ac815bef9599406c0734cb78c095698f0f8 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a718382837cf353aa21a2455e5519c638b6aeac8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e04b6d0b94b457eacd407d0338fa99146f6749339d4b64b48001287daa5b7b5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..a036f5707506ec7bfea76a21e2ee20a931c05065 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9cc24aa23a4db246ab5dfe17125252a50009917323d54e5677507aba6b7f0a38 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..66c9afda1050096fedb7688d56a9a03ea9926b47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e161c1def56ea993fc1e643c986456388df3cabfae0c4213cb15565a17e0dcd2 +size 400 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da1d999c49a6040603a6b508b4baa2b9a6719090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4712ec1d5d364761ad171d82d98b083e0e8b567649793dfa488478beef453c08 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..956bfdeffb7135603d0fabdaa6c8879918cb2384 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9063998cac822118a02b7b2d2a568d909c04fc994db129345a81a481a4fd0956 +size 1315 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..36dc119e8917134f5fe5bed0b6ea84ccba3c2ad8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61fe10a9440af4534e2826cbc566e5192f7ae8947c598d2e84fe619b37a359ac +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..188742f3a544abe1953ff5dbd12f1238d1b9ce41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a5b6a5e9214b8d7e50524a5e9177419661add5dc4d3b06ecffe68c7cb4c5f392 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f3e143c3c192cbda659bcd16a90b1d26c7f3d2e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aa03c0df6c8ca6742c1489e8e37ac08f68c342c863bddf7ca3143426920c576 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..cc8427f26ad1f9ca2dcb4cc6943fab932096ffc8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50edc7be21196e9e790fe8990bc332150d0550db1b2c46e60d19810e875a3ece +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..021c8067d431ea8362123e590cc238472e801ae5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36cf4c644fe1879a25693cfb68d88db11c3afb7a9c075e3f4d2d1ea201ca67c5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bd44eefcc1486f6bd4d79b60858ec5796da81e78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b55d374b6630709cb9d4c5814d856dd2520386b992937a3b24d80d71eb2e035c +size 3307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/exp/wilt/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..54d6f6bbd104c00418af09162967e1fde1dea4fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/__init__.py @@ -0,0 +1,12 @@ +import torch +from icecream import install + +torch.set_num_threads(1) +install() + +from . import env # noqa +from .data import * # noqa +from .deep import * # noqa +from .env import * # noqa +from .metrics import * # noqa +from .util import * # noqa diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/data.py new file mode 100644 index 0000000000000000000000000000000000000000..de47f283d607c411a23df48a364f19f43d2727d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/data.py @@ -0,0 +1,719 @@ +import hashlib +from collections import Counter +from copy import deepcopy +from dataclasses import astuple, dataclass, replace +from importlib.resources import path +from pathlib import Path +from typing import Any, Literal, Optional, Union, cast, Tuple, Dict, List + +import numpy as np +import pandas as pd +from sklearn.model_selection import train_test_split +from sklearn.pipeline import make_pipeline +import sklearn.preprocessing +import torch +import os +from category_encoders import LeaveOneOutEncoder +from sklearn.impute import SimpleImputer +from sklearn.preprocessing import StandardScaler +from scipy.spatial.distance import cdist + +from . import env, util +from .metrics import calculate_metrics as calculate_metrics_ +from .util import TaskType, load_json + +ArrayDict = Dict[str, np.ndarray] +TensorDict = Dict[str, torch.Tensor] + + +CAT_MISSING_VALUE = '__nan__' +CAT_RARE_VALUE = '__rare__' +Normalization = Literal['standard', 'quantile', 'minmax'] +NumNanPolicy = Literal['drop-rows', 'mean'] +CatNanPolicy = Literal['most_frequent'] +CatEncoding = Literal['one-hot', 'counter'] +YPolicy = Literal['default'] + + +class StandardScaler1d(StandardScaler): + def partial_fit(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().partial_fit(X[:, None], *args, **kwargs) + + def transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().transform(X[:, None], *args, **kwargs).squeeze(1) + + def inverse_transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().inverse_transform(X[:, None], *args, **kwargs).squeeze(1) + + +def get_category_sizes(X: Union[torch.Tensor, np.ndarray]) -> List[int]: + """Return K[i] s.t. F.one_hot(x[:,i], K[i]) is valid. Requires K[i] > max(x[:,i]).""" + XT = X.T.cpu().tolist() if isinstance(X, torch.Tensor) else X.T.tolist() + return [int(np.max(x)) + 1 if len(x) > 0 else 0 for x in XT] + + +@dataclass(frozen=False) +class Dataset: + X_num: Optional[ArrayDict] + X_cat: Optional[ArrayDict] + y: ArrayDict + y_info: Dict[str, Any] + task_type: TaskType + n_classes: Optional[int] + + @classmethod + def from_dir(cls, dir_: Union[Path, str]) -> 'Dataset': + dir_ = Path(dir_) + splits = [k for k in ['train', 'val', 'test'] if dir_.joinpath(f'y_{k}.npy').exists()] + + def load(item) -> ArrayDict: + return { + x: cast(np.ndarray, np.load(dir_ / f'{item}_{x}.npy', allow_pickle=True)) # type: ignore[code] + for x in splits + } + + if Path(dir_ / 'info.json').exists(): + info = util.load_json(dir_ / 'info.json') + else: + info = None + return Dataset( + load('X_num') if dir_.joinpath('X_num_train.npy').exists() else None, + load('X_cat') if dir_.joinpath('X_cat_train.npy').exists() else None, + load('y'), + {}, + TaskType(info['task_type']), + info.get('n_classes'), + ) + + @property + def is_binclass(self) -> bool: + return self.task_type == TaskType.BINCLASS + + @property + def is_multiclass(self) -> bool: + return self.task_type == TaskType.MULTICLASS + + @property + def is_regression(self) -> bool: + return self.task_type == TaskType.REGRESSION + + @property + def n_num_features(self) -> int: + return 0 if self.X_num is None else self.X_num['train'].shape[1] + + @property + def n_cat_features(self) -> int: + return 0 if self.X_cat is None else self.X_cat['train'].shape[1] + + @property + def n_features(self) -> int: + return self.n_num_features + self.n_cat_features + + def size(self, part: Optional[str]) -> int: + return sum(map(len, self.y.values())) if part is None else len(self.y[part]) + + @property + def nn_output_dim(self) -> int: + if self.is_multiclass: + assert self.n_classes is not None + return self.n_classes + else: + return 1 + + def get_category_sizes(self, part: str) -> List[int]: + return [] if self.X_cat is None else get_category_sizes(self.X_cat[part]) + + def calculate_metrics( + self, + predictions: Dict[str, np.ndarray], + prediction_type: Optional[str], + ) -> Dict[str, Any]: + metrics = { + x: calculate_metrics_( + self.y[x], predictions[x], self.task_type, prediction_type, self.y_info + ) + for x in predictions + } + if self.task_type == TaskType.REGRESSION: + score_key = 'rmse' + score_sign = -1 + else: + score_key = 'accuracy' + score_sign = 1 + for part_metrics in metrics.values(): + part_metrics['score'] = score_sign * part_metrics[score_key] + return metrics + +def change_val(dataset: Dataset, val_size: float = 0.2): + # should be done before transformations + + y = np.concatenate([dataset.y['train'], dataset.y['val']], axis=0) + + ixs = np.arange(y.shape[0]) + if dataset.is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + + dataset.y['train'] = y[train_ixs] + dataset.y['val'] = y[val_ixs] + + if dataset.X_num is not None: + X_num = np.concatenate([dataset.X_num['train'], dataset.X_num['val']], axis=0) + dataset.X_num['train'] = X_num[train_ixs] + dataset.X_num['val'] = X_num[val_ixs] + + if dataset.X_cat is not None: + X_cat = np.concatenate([dataset.X_cat['train'], dataset.X_cat['val']], axis=0) + dataset.X_cat['train'] = X_cat[train_ixs] + dataset.X_cat['val'] = X_cat[val_ixs] + + return dataset + +def num_process_nans(dataset: Dataset, policy: Optional[NumNanPolicy]) -> Dataset: + assert dataset.X_num is not None + nan_masks = {k: np.isnan(v) for k, v in dataset.X_num.items()} + if not any(x.any() for x in nan_masks.values()): # type: ignore[code] + assert policy is None + return dataset + + assert policy is not None + if policy == 'drop-rows': + valid_masks = {k: ~v.any(1) for k, v in nan_masks.items()} + assert valid_masks[ + 'test' + ].all(), 'Cannot drop test rows, since this will affect the final metrics.' + new_data = {} + for data_name in ['X_num', 'X_cat', 'y']: + data_dict = getattr(dataset, data_name) + if data_dict is not None: + new_data[data_name] = { + k: v[valid_masks[k]] for k, v in data_dict.items() + } + dataset = replace(dataset, **new_data) + elif policy == 'mean': + new_values = np.nanmean(dataset.X_num['train'], axis=0) + X_num = deepcopy(dataset.X_num) + for k, v in X_num.items(): + num_nan_indices = np.where(nan_masks[k]) + v[num_nan_indices] = np.take(new_values, num_nan_indices[1]) + dataset = replace(dataset, X_num=X_num) + else: + assert util.raise_unknown('policy', policy) + return dataset + + +# Inspired by: https://github.com/yandex-research/rtdl/blob/a4c93a32b334ef55d2a0559a4407c8306ffeeaee/lib/data.py#L20 +def normalize( + X: ArrayDict, normalization: Normalization, seed: Optional[int], return_normalizer : bool = False +) -> ArrayDict: + X_train = X['train'] + if normalization == 'standard': + normalizer = sklearn.preprocessing.StandardScaler() + elif normalization == 'minmax': + normalizer = sklearn.preprocessing.MinMaxScaler() + elif normalization == 'quantile': + normalizer = sklearn.preprocessing.QuantileTransformer( + output_distribution='normal', + n_quantiles=max(min(X['train'].shape[0] // 30, 1000), 10), + subsample=int(1e9), + random_state=seed, + ) + # noise = 1e-3 + # if noise > 0: + # assert seed is not None + # stds = np.std(X_train, axis=0, keepdims=True) + # noise_std = noise / np.maximum(stds, noise) # type: ignore[code] + # X_train = X_train + noise_std * np.random.default_rng(seed).standard_normal( + # X_train.shape + # ) + else: + util.raise_unknown('normalization', normalization) + normalizer.fit(X_train) + if return_normalizer: + return {k: normalizer.transform(v) for k, v in X.items()}, normalizer + return {k: normalizer.transform(v) for k, v in X.items()} + + +def cat_process_nans(X: ArrayDict, policy: Optional[CatNanPolicy]) -> ArrayDict: + assert X is not None + nan_masks = {k: np.asarray(v == CAT_MISSING_VALUE) for k, v in X.items()} + if any(np.asarray(x).any() for x in nan_masks.values()): # type: ignore[code] + if policy is None: + X_new = X + elif policy == 'most_frequent': + imputer = SimpleImputer(missing_values=CAT_MISSING_VALUE, strategy=policy) # type: ignore[code] + imputer.fit(X['train']) + X_new = {k: cast(np.ndarray, imputer.transform(v)) for k, v in X.items()} + else: + util.raise_unknown('categorical NaN policy', policy) + else: + assert policy is None + X_new = X + return X_new + + +def cat_drop_rare(X: ArrayDict, min_frequency: float) -> ArrayDict: + assert 0.0 < min_frequency < 1.0 + min_count = round(len(X['train']) * min_frequency) + X_new = {x: [] for x in X} + for column_idx in range(X['train'].shape[1]): + counter = Counter(X['train'][:, column_idx].tolist()) + popular_categories = {k for k, v in counter.items() if v >= min_count} + for part in X_new: + X_new[part].append( + [ + (x if x in popular_categories else CAT_RARE_VALUE) + for x in X[part][:, column_idx].tolist() + ] + ) + return {k: np.array(v).T for k, v in X_new.items()} + + +def cat_encode( + X: ArrayDict, + encoding: Optional[CatEncoding], + y_train: Optional[np.ndarray], + seed: Optional[int], + return_encoder : bool = False +) -> Tuple[ArrayDict, bool, Optional[Any]]: # (X, is_converted_to_numerical) + if encoding != 'counter': + y_train = None + + # Step 1. Map strings to 0-based ranges + + if encoding is None: + unknown_value = np.iinfo('int64').max - 3 + oe = sklearn.preprocessing.OrdinalEncoder( + handle_unknown='use_encoded_value', # type: ignore[code] + unknown_value=unknown_value, # type: ignore[code] + dtype='int64', # type: ignore[code] + ).fit(X['train']) + encoder = make_pipeline(oe) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + max_values = X['train'].max(axis=0) + for part in X.keys(): + if part == 'train': continue + for column_idx in range(X[part].shape[1]): + X[part][X[part][:, column_idx] == unknown_value, column_idx] = ( + max_values[column_idx] + 1 + ) + if return_encoder: + return (X, False, encoder) + return (X, False) + + # Step 2. Encode. + + elif encoding == 'one-hot': + ohe = sklearn.preprocessing.OneHotEncoder( + handle_unknown='ignore', sparse=False, dtype=np.float32 # type: ignore[code] + ) + encoder = make_pipeline(ohe) + + # encoder.steps.append(('ohe', ohe)) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + elif encoding == 'counter': + assert y_train is not None + assert seed is not None + loe = LeaveOneOutEncoder(sigma=0.1, random_state=seed, return_df=False) + encoder.steps.append(('loe', loe)) + encoder.fit(X['train'], y_train) + X = {k: encoder.transform(v).astype('float32') for k, v in X.items()} # type: ignore[code] + if not isinstance(X['train'], pd.DataFrame): + X = {k: v.values for k, v in X.items()} # type: ignore[code] + else: + util.raise_unknown('encoding', encoding) + + if return_encoder: + return X, True, encoder # type: ignore[code] + return (X, True) + + +def build_target( + y: ArrayDict, policy: Optional[YPolicy], task_type: TaskType +) -> Tuple[ArrayDict, Dict[str, Any]]: + info: Dict[str, Any] = {'policy': policy} + if policy is None: + pass + elif policy == 'default': + if task_type == TaskType.REGRESSION: + mean, std = float(y['train'].mean()), float(y['train'].std()) + y = {k: (v - mean) / std for k, v in y.items()} + info['mean'] = mean + info['std'] = std + else: + util.raise_unknown('policy', policy) + return y, info + + +@dataclass(frozen=True) +class Transformations: + seed: int = 0 + normalization: Optional[Normalization] = None + num_nan_policy: Optional[NumNanPolicy] = None + cat_nan_policy: Optional[CatNanPolicy] = None + cat_min_frequency: Optional[float] = None + cat_encoding: Optional[CatEncoding] = None + y_policy: Optional[YPolicy] = 'default' + + +def transform_dataset( + dataset: Dataset, + transformations: Transformations, + cache_dir: Optional[Path], + return_transforms: bool = False +) -> Dataset: + # WARNING: the order of transformations matters. Moreover, the current + # implementation is not ideal in that sense. + if cache_dir is not None: + transformations_md5 = hashlib.md5( + str(transformations).encode('utf-8') + ).hexdigest() + transformations_str = '__'.join(map(str, astuple(transformations))) + cache_path = ( + cache_dir / f'cache__{transformations_str}__{transformations_md5}.pickle' + ) + if cache_path.exists(): + cache_transformations, value = util.load_pickle(cache_path) + if transformations == cache_transformations: + print( + f"Using cached features: {cache_dir.name + '/' + cache_path.name}" + ) + return value + else: + raise RuntimeError(f'Hash collision for {cache_path}') + else: + cache_path = None + + if dataset.X_num is not None: + dataset = num_process_nans(dataset, transformations.num_nan_policy) + + num_transform = None + cat_transform = None + X_num = dataset.X_num + + if X_num is not None and transformations.normalization is not None: + X_num, num_transform = normalize( + X_num, + transformations.normalization, + transformations.seed, + return_normalizer=True + ) + num_transform = num_transform + + if dataset.X_cat is None: + assert transformations.cat_nan_policy is None + assert transformations.cat_min_frequency is None + # assert transformations.cat_encoding is None + X_cat = None + else: + X_cat = cat_process_nans(dataset.X_cat, transformations.cat_nan_policy) + if transformations.cat_min_frequency is not None: + X_cat = cat_drop_rare(X_cat, transformations.cat_min_frequency) + X_cat, is_num, cat_transform = cat_encode( + X_cat, + transformations.cat_encoding, + dataset.y['train'], + transformations.seed, + return_encoder=True + ) + if is_num: + X_num = ( + X_cat + if X_num is None + else {x: np.hstack([X_num[x], X_cat[x]]) for x in X_num} + ) + X_cat = None + + y, y_info = build_target(dataset.y, transformations.y_policy, dataset.task_type) + + dataset = replace(dataset, X_num=X_num, X_cat=X_cat, y=y, y_info=y_info) + dataset.num_transform = num_transform + dataset.cat_transform = cat_transform + + if cache_path is not None: + util.dump_pickle((transformations, dataset), cache_path) + # if return_transforms: + # return dataset, num_transform, cat_transform + return dataset + + +def build_dataset( + path: Union[str, Path], + transformations: Transformations, + cache: bool +) -> Dataset: + path = Path(path) + dataset = Dataset.from_dir(path) + return transform_dataset(dataset, transformations, path if cache else None) + + +def prepare_tensors( + dataset: Dataset, device: Union[str, torch.device] +) -> Tuple[Optional[TensorDict], Optional[TensorDict], TensorDict]: + X_num, X_cat, Y = ( + None if x is None else {k: torch.as_tensor(v) for k, v in x.items()} + for x in [dataset.X_num, dataset.X_cat, dataset.y] + ) + if device.type != 'cpu': + X_num, X_cat, Y = ( + None if x is None else {k: v.to(device) for k, v in x.items()} + for x in [X_num, X_cat, Y] + ) + assert X_num is not None + assert Y is not None + if not dataset.is_multiclass: + Y = {k: v.float() for k, v in Y.items()} + return X_num, X_cat, Y + +############### +## DataLoader## +############### + +class TabDataset(torch.utils.data.Dataset): + def __init__( + self, dataset : Dataset, split : Literal['train', 'val', 'test'] + ): + super().__init__() + + self.X_num = torch.from_numpy(dataset.X_num[split]) if dataset.X_num is not None else None + self.X_cat = torch.from_numpy(dataset.X_cat[split]) if dataset.X_cat is not None else None + self.y = torch.from_numpy(dataset.y[split]) + + assert self.y is not None + assert self.X_num is not None or self.X_cat is not None + + def __len__(self): + return len(self.y) + + def __getitem__(self, idx): + out_dict = { + 'y': self.y[idx].long() if self.y is not None else None, + } + + x = np.empty((0,)) + if self.X_num is not None: + x = self.X_num[idx] + if self.X_cat is not None: + x = torch.cat([x, self.X_cat[idx]], dim=0) + return x.float(), out_dict + +def prepare_dataloader( + dataset : Dataset, + split : str, + batch_size: int, +): + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader( + torch_dataset, + batch_size=batch_size, + shuffle=(split == 'train'), + num_workers=1, + ) + while True: + yield from loader + +def prepare_torch_dataloader( + dataset : Dataset, + split : str, + shuffle : bool, + batch_size: int, +) -> torch.utils.data.DataLoader: + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader(torch_dataset, batch_size=batch_size, shuffle=shuffle, num_workers=1) + + return loader + +def dataset_from_csv(paths : Dict[str, str], cat_features, target, T): + assert 'train' in paths + y = {} + X_num = {} + X_cat = {} if len(cat_features) else None + for split in paths.keys(): + df = pd.read_csv(paths[split]) + y[split] = df[target].to_numpy().astype(float) + if X_cat is not None: + X_cat[split] = df[cat_features].to_numpy().astype(str) + X_num[split] = df.drop(cat_features + [target], axis=1).to_numpy().astype(float) + + dataset = Dataset(X_num, X_cat, y, {}, None, len(np.unique(y['train']))) + return transform_dataset(dataset, T, None) + +class FastTensorDataLoader: + """ + A DataLoader-like object for a set of tensors that can be much faster than + TensorDataset + DataLoader because dataloader grabs individual indices of + the dataset and calls cat (slow). + Source: https://discuss.pytorch.org/t/dataloader-much-slower-than-manual-batching/27014/6 + """ + def __init__(self, *tensors, batch_size=32, shuffle=False): + """ + Initialize a FastTensorDataLoader. + :param *tensors: tensors to store. Must have the same length @ dim 0. + :param batch_size: batch size to load. + :param shuffle: if True, shuffle the data *in-place* whenever an + iterator is created out of this object. + :returns: A FastTensorDataLoader. + """ + assert all(t.shape[0] == tensors[0].shape[0] for t in tensors) + self.tensors = tensors + + self.dataset_len = self.tensors[0].shape[0] + self.batch_size = batch_size + self.shuffle = shuffle + + # Calculate # batches + n_batches, remainder = divmod(self.dataset_len, self.batch_size) + if remainder > 0: + n_batches += 1 + self.n_batches = n_batches + def __iter__(self): + if self.shuffle: + r = torch.randperm(self.dataset_len) + self.tensors = [t[r] for t in self.tensors] + self.i = 0 + return self + + def __next__(self): + if self.i >= self.dataset_len: + raise StopIteration + batch = tuple(t[self.i:self.i+self.batch_size] for t in self.tensors) + self.i += self.batch_size + return batch + + def __len__(self): + return self.n_batches + +def prepare_fast_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + if D.X_num is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_cat[split]).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + while True: + yield from dataloader + +def prepare_fast_torch_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + return dataloader + +def round_columns(X_real, X_synth, columns): + for col in columns: + uniq = np.unique(X_real[:,col]) + dist = cdist(X_synth[:, col][:, np.newaxis].astype(float), uniq[:, np.newaxis].astype(float)) + X_synth[:, col] = uniq[dist.argmin(axis=1)] + return X_synth + +def concat_features(D : Dataset): + if D.X_num is None: + assert D.X_cat is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_cat.items()} + elif D.X_cat is None: + assert D.X_num is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_num.items()} + else: + X = { + part: pd.concat( + [ + pd.DataFrame(D.X_num[part], columns=range(D.n_num_features)), + pd.DataFrame( + D.X_cat[part], + columns=range(D.n_num_features, D.n_features), + ), + ], + axis=1, + ) + for part in D.y.keys() + } + + return X + +def concat_to_pd(X_num, X_cat, y): + if X_num is None: + return pd.concat([ + pd.DataFrame(X_cat, columns=list(range(X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + if X_cat is not None: + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(X_cat, columns=list(range(X_num.shape[1], X_num.shape[1] + X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + +def read_pure_data(path, split='train'): + y = np.load(os.path.join(path, f'y_{split}.npy'), allow_pickle=True) + X_num = None + X_cat = None + if os.path.exists(os.path.join(path, f'X_num_{split}.npy')): + X_num = np.load(os.path.join(path, f'X_num_{split}.npy'), allow_pickle=True) + if os.path.exists(os.path.join(path, f'X_cat_{split}.npy')): + X_cat = np.load(os.path.join(path, f'X_cat_{split}.npy'), allow_pickle=True) + + return X_num, X_cat, y + +def read_changed_val(path, val_size=0.2): + path = Path(path) + X_num_train, X_cat_train, y_train = read_pure_data(path, 'train') + X_num_val, X_cat_val, y_val = read_pure_data(path, 'val') + is_regression = load_json(path / 'info.json')['task_type'] == 'regression' + + y = np.concatenate([y_train, y_val], axis=0) + + ixs = np.arange(y.shape[0]) + if is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + y_train = y[train_ixs] + y_val = y[val_ixs] + + if X_num_train is not None: + X_num = np.concatenate([X_num_train, X_num_val], axis=0) + X_num_train = X_num[train_ixs] + X_num_val = X_num[val_ixs] + + if X_cat_train is not None: + X_cat = np.concatenate([X_cat_train, X_cat_val], axis=0) + X_cat_train = X_cat[train_ixs] + X_cat_val = X_cat[val_ixs] + + return X_num_train, X_cat_train, y_train, X_num_val, X_cat_val, y_val + +############# + +def load_dataset_info(dataset_dir_name: str) -> Dict[str, Any]: + path = Path("data/" + dataset_dir_name) + info = util.load_json(path / 'info.json') + info['size'] = info['train_size'] + info['val_size'] + info['test_size'] + info['n_features'] = info['n_num_features'] + info['n_cat_features'] + info['path'] = path + return info diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/deep.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/deep.py new file mode 100644 index 0000000000000000000000000000000000000000..aeed3e2ada4f9d0ee1a6f86b7e5d1a35d486149f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/deep.py @@ -0,0 +1,168 @@ +import statistics +from dataclasses import dataclass +from typing import Any, Callable, Literal, cast + +import rtdl +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim as optim +import zero +from torch import Tensor + +from .util import TaskType + + +def cos_sin(x: Tensor) -> Tensor: + return torch.cat([torch.cos(x), torch.sin(x)], -1) + + +@dataclass +class PeriodicOptions: + n: int # the output size is 2 * n + sigma: float + trainable: bool + initialization: Literal['log-linear', 'normal'] + + +class Periodic(nn.Module): + def __init__(self, n_features: int, options: PeriodicOptions) -> None: + super().__init__() + if options.initialization == 'log-linear': + coefficients = options.sigma ** (torch.arange(options.n) / options.n) + coefficients = coefficients[None].repeat(n_features, 1) + else: + assert options.initialization == 'normal' + coefficients = torch.normal(0.0, options.sigma, (n_features, options.n)) + if options.trainable: + self.coefficients = nn.Parameter(coefficients) # type: ignore[code] + else: + self.register_buffer('coefficients', coefficients) + + def forward(self, x: Tensor) -> Tensor: + assert x.ndim == 2 + return cos_sin(2 * torch.pi * self.coefficients[None] * x[..., None]) + + +def get_n_parameters(m: nn.Module): + return sum(x.numel() for x in m.parameters() if x.requires_grad) + + +def get_loss_fn(task_type: TaskType) -> Callable[..., Tensor]: + return ( + F.binary_cross_entropy_with_logits + if task_type == TaskType.BINCLASS + else F.cross_entropy + if task_type == TaskType.MULTICLASS + else F.mse_loss + ) + + +def default_zero_weight_decay_condition(module_name, module, parameter_name, parameter): + del module_name, parameter + return parameter_name.endswith('bias') or isinstance( + module, + ( + nn.BatchNorm1d, + nn.LayerNorm, + nn.InstanceNorm1d, + rtdl.CLSToken, + rtdl.NumericalFeatureTokenizer, + rtdl.CategoricalFeatureTokenizer, + Periodic, + ), + ) + + +def split_parameters_by_weight_decay( + model: nn.Module, zero_weight_decay_condition=default_zero_weight_decay_condition +) -> list[dict[str, Any]]: + parameters_info = {} + for module_name, module in model.named_modules(): + for parameter_name, parameter in module.named_parameters(): + full_parameter_name = ( + f'{module_name}.{parameter_name}' if module_name else parameter_name + ) + parameters_info.setdefault(full_parameter_name, ([], parameter))[0].append( + zero_weight_decay_condition( + module_name, module, parameter_name, parameter + ) + ) + params_with_wd = {'params': []} + params_without_wd = {'params': [], 'weight_decay': 0.0} + for full_parameter_name, (results, parameter) in parameters_info.items(): + (params_without_wd if any(results) else params_with_wd)['params'].append( + parameter + ) + return [params_with_wd, params_without_wd] + + +def make_optimizer( + config: dict[str, Any], + parameter_groups, +) -> optim.Optimizer: + if config['optimizer'] == 'FT-Transformer-default': + return optim.AdamW(parameter_groups, lr=1e-4, weight_decay=1e-5) + return getattr(optim, config['optimizer'])( + parameter_groups, + **{x: config[x] for x in ['lr', 'weight_decay', 'momentum'] if x in config}, + ) + + +def get_lr(optimizer: optim.Optimizer) -> float: + return next(iter(optimizer.param_groups))['lr'] + + +def is_oom_exception(err: RuntimeError) -> bool: + return any( + x in str(err) + for x in [ + 'CUDA out of memory', + 'CUBLAS_STATUS_ALLOC_FAILED', + 'CUDA error: out of memory', + ] + ) + + +def train_with_auto_virtual_batch( + optimizer, + loss_fn, + step, + batch, + chunk_size: int, +) -> tuple[Tensor, int]: + batch_size = len(batch) + random_state = zero.random.get_state() + loss = None + while chunk_size != 0: + try: + zero.random.set_state(random_state) + optimizer.zero_grad() + if batch_size <= chunk_size: + loss = loss_fn(*step(batch)) + loss.backward() + else: + loss = None + for chunk in zero.iter_batches(batch, chunk_size): + chunk_loss = loss_fn(*step(chunk)) + chunk_loss = chunk_loss * (len(chunk) / batch_size) + chunk_loss.backward() + if loss is None: + loss = chunk_loss.detach() + else: + loss += chunk_loss.detach() + except RuntimeError as err: + if not is_oom_exception(err): + raise + chunk_size //= 2 + else: + break + if not chunk_size: + raise RuntimeError('Not enough memory even for batch_size=1') + optimizer.step() + return cast(Tensor, loss), chunk_size + + +def process_epoch_losses(losses: list[Tensor]) -> tuple[list[float], float]: + losses_ = torch.stack(losses).tolist() + return losses_, statistics.mean(losses_) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/env.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/env.py new file mode 100644 index 0000000000000000000000000000000000000000..64be89d7d72c70e2ed9c7e0ecbbe682c14da3517 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/env.py @@ -0,0 +1,39 @@ +""" +Have not used in TabDDPM project. +""" + +import datetime +import os +import shutil +import typing as ty +from pathlib import Path + +PROJ = Path('tab-ddpm/').absolute().resolve() +EXP = PROJ / 'exp' +DATA = PROJ / 'data' + + +def get_path(path: ty.Union[str, Path]) -> Path: + if isinstance(path, str): + path = Path(path) + if not path.is_absolute(): + path = PROJ / path + return path.resolve() + + +def get_relative_path(path: ty.Union[str, Path]) -> Path: + return get_path(path).relative_to(PROJ) + + +def duplicate_path( + src: ty.Union[str, Path], alternative_project_dir: ty.Union[str, Path] +) -> None: + src = get_path(src) + alternative_project_dir = get_path(alternative_project_dir) + dst = alternative_project_dir / src.relative_to(PROJ) + dst.parent.mkdir(parents=True, exist_ok=True) + if dst.exists(): + dst = dst.with_name( + dst.name + '_' + datetime.datetime.now().strftime('%Y%m%dT%H%M%S') + ) + (shutil.copytree if src.is_dir() else shutil.copyfile)(src, dst) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/metrics.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/metrics.py new file mode 100644 index 0000000000000000000000000000000000000000..bdcac8171208065da730e974024aae0dc32b4665 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/metrics.py @@ -0,0 +1,158 @@ +import enum +from typing import Any, Optional, Tuple, Dict, Union, cast +from functools import partial + +import numpy as np +import scipy.special +import sklearn.metrics as skm + +from . import util +from .util import TaskType + + +class PredictionType(enum.Enum): + LOGITS = 'logits' + PROBS = 'probs' + +class MetricsReport: + def __init__(self, report: dict, task_type: TaskType): + self._res = {k: {} for k in report.keys()} + if task_type in (TaskType.BINCLASS, TaskType.MULTICLASS): + self._metrics_names = ["acc", "f1"] + for k in report.keys(): + self._res[k]["acc"] = report[k]["accuracy"] + self._res[k]["f1"] = report[k]["macro avg"]["f1-score"] + if task_type == TaskType.BINCLASS: + self._res[k]["roc_auc"] = report[k]["roc_auc"] + self._metrics_names.append("roc_auc") + + elif task_type == TaskType.REGRESSION: + self._metrics_names = ["r2", "rmse"] + for k in report.keys(): + self._res[k]["r2"] = report[k]["r2"] + self._res[k]["rmse"] = report[k]["rmse"] + else: + raise "Unknown TaskType!" + + def get_splits_names(self) -> list[str]: + return self._res.keys() + + def get_metrics_names(self) -> list[str]: + return self._metrics_names + + def get_metric(self, split: str, metric: str) -> float: + return self._res[split][metric] + + def get_val_score(self) -> float: + return self._res["val"]["r2"] if "r2" in self._res["val"] else self._res["val"]["f1"] + + def get_test_score(self) -> float: + return self._res["test"]["r2"] if "r2" in self._res["test"] else self._res["test"]["f1"] + + def print_metrics(self) -> None: + res = { + "val": {k: np.around(self._res["val"][k], 4) for k in self._res["val"]}, + "test": {k: np.around(self._res["test"][k], 4) for k in self._res["test"]} + } + + print("*"*100) + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + + return res + +class SeedsMetricsReport: + def __init__(self): + self._reports = [] + + def add_report(self, report: MetricsReport) -> None: + self._reports.append(report) + + def get_mean_std(self) -> dict: + res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + res[split][metric] = [x.get_metric(split, metric) for x in self._reports] + + agg_res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + for k, f in [("count", len), ("mean", np.mean), ("std", np.std)]: + agg_res[split][f"{metric}-{k}"] = f(res[split][metric]) + self._res = res + self._agg_res = agg_res + + return agg_res + + def print_result(self) -> dict: + res = {split: {k: float(np.around(self._agg_res[split][k], 4)) for k in self._agg_res[split]} for split in ["val", "test"]} + print("="*100) + print("EVAL RESULTS:") + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + print("="*100) + return res + +def calculate_rmse( + y_true: np.ndarray, y_pred: np.ndarray, std: Optional[float] +) -> float: + rmse = skm.mean_squared_error(y_true, y_pred) ** 0.5 + if std is not None: + rmse *= std + return rmse + + +def _get_labels_and_probs( + y_pred: np.ndarray, task_type: TaskType, prediction_type: Optional[PredictionType] +) -> Tuple[np.ndarray, Optional[np.ndarray]]: + assert task_type in (TaskType.BINCLASS, TaskType.MULTICLASS) + + if prediction_type is None: + return y_pred, None + + if prediction_type == PredictionType.LOGITS: + probs = ( + scipy.special.expit(y_pred) + if task_type == TaskType.BINCLASS + else scipy.special.softmax(y_pred, axis=1) + ) + elif prediction_type == PredictionType.PROBS: + probs = y_pred + else: + util.raise_unknown('prediction_type', prediction_type) + + assert probs is not None + labels = np.round(probs) if task_type == TaskType.BINCLASS else probs.argmax(axis=1) + return labels.astype('int64'), probs + + +def calculate_metrics( + y_true: np.ndarray, + y_pred: np.ndarray, + task_type: Union[str, TaskType], + prediction_type: Optional[Union[str, PredictionType]], + y_info: Dict[str, Any], +) -> Dict[str, Any]: + # Example: calculate_metrics(y_true, y_pred, 'binclass', 'logits', {}) + task_type = TaskType(task_type) + if prediction_type is not None: + prediction_type = PredictionType(prediction_type) + + if task_type == TaskType.REGRESSION: + assert prediction_type is None + assert 'std' in y_info + rmse = calculate_rmse(y_true, y_pred, y_info['std']) + r2 = skm.r2_score(y_true, y_pred) + result = {'rmse': rmse, 'r2': r2} + else: + labels, probs = _get_labels_and_probs(y_pred, task_type, prediction_type) + result = cast( + Dict[str, Any], skm.classification_report(y_true, labels, output_dict=True) + ) + if task_type == TaskType.BINCLASS: + result['roc_auc'] = skm.roc_auc_score(y_true, probs) + return result diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/util.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/util.py new file mode 100644 index 0000000000000000000000000000000000000000..75e05c9c9d1f0f9d6687f6d5fe1e91cad1b4ea20 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/lib/util.py @@ -0,0 +1,433 @@ +import argparse +import atexit +import enum +import json +import os +import pickle +import shutil +import sys +import time +import uuid +from copy import deepcopy +from dataclasses import asdict, fields, is_dataclass +from pathlib import Path +from pprint import pprint +from typing import Any, Callable, List, Dict, Type, Optional, Tuple, TypeVar, Union, cast, get_args, get_origin + +import __main__ +import numpy as np +import tomli +import tomli_w +import torch +import zero + +from . import env + +RawConfig = Dict[str, Any] +Report = Dict[str, Any] +T = TypeVar('T') + + +class Part(enum.Enum): + TRAIN = 'train' + VAL = 'val' + TEST = 'test' + + def __str__(self) -> str: + return self.value + + +class TaskType(enum.Enum): + BINCLASS = 'binclass' + MULTICLASS = 'multiclass' + REGRESSION = 'regression' + + def __str__(self) -> str: + return self.value + + +class Timer(zero.Timer): + @classmethod + def launch(cls) -> 'Timer': + timer = cls() + timer.run() + return timer + + +def update_training_log(training_log, data, metrics): + def _update(log_part, data_part): + for k, v in data_part.items(): + if isinstance(v, dict): + _update(log_part.setdefault(k, {}), v) + elif isinstance(v, list): + log_part.setdefault(k, []).extend(v) + else: + log_part.setdefault(k, []).append(v) + + _update(training_log, data) + transposed_metrics = {} + for part, part_metrics in metrics.items(): + for metric_name, value in part_metrics.items(): + transposed_metrics.setdefault(metric_name, {})[part] = value + _update(training_log, transposed_metrics) + + +def raise_unknown(unknown_what: str, unknown_value: Any): + raise ValueError(f'Unknown {unknown_what}: {unknown_value}') + + +def _replace(data, condition, value): + def do(x): + if isinstance(x, dict): + return {k: do(v) for k, v in x.items()} + elif isinstance(x, list): + return [do(y) for y in x] + else: + return value if condition(x) else x + + return do(data) + + +_CONFIG_NONE = '__none__' + + +def unpack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x == _CONFIG_NONE, None)) + return config + + +def pack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x is None, _CONFIG_NONE)) + return config + + +def load_config(path: Union[Path, str]) -> Any: + with open(path, 'rb') as f: + return unpack_config(tomli.load(f)) + + +def dump_config(config: Any, path: Union[Path, str]) -> None: + with open(path, 'wb') as f: + tomli_w.dump(pack_config(config), f) + # check that there are no bugs in all these "pack/unpack" things + assert config == load_config(path) + + +def load_json(path: Union[Path, str], **kwargs) -> Any: + return json.loads(Path(path).read_text(), **kwargs) + + +def dump_json(x: Any, path: Union[Path, str], **kwargs) -> None: + kwargs.setdefault('indent', 4) + Path(path).write_text(json.dumps(x, **kwargs) + '\n') + + +def load_pickle(path: Union[Path, str], **kwargs) -> Any: + return pickle.loads(Path(path).read_bytes(), **kwargs) + + +def dump_pickle(x: Any, path: Union[Path, str], **kwargs) -> None: + Path(path).write_bytes(pickle.dumps(x, **kwargs)) + + +def load(path: Union[Path, str], **kwargs) -> Any: + return globals()[f'load_{Path(path).suffix[1:]}'](Path(path), **kwargs) + + +def dump(x: Any, path: Union[Path, str], **kwargs) -> Any: + return globals()[f'dump_{Path(path).suffix[1:]}'](x, Path(path), **kwargs) + + +def _get_output_item_path( + path: Union[str, Path], filename: str, must_exist: bool +) -> Path: + path = env.get_path(path) + if path.suffix == '.toml': + path = path.with_suffix('') + if path.is_dir(): + path = path / filename + else: + assert path.name == filename + assert path.parent.exists() + if must_exist: + assert path.exists() + return path + + +def load_report(path: Path) -> Report: + return load_json(_get_output_item_path(path, 'report.json', True)) + + +def dump_report(report: dict, path: Path) -> None: + dump_json(report, _get_output_item_path(path, 'report.json', False)) + + +def load_predictions(path: Path) -> Dict[str, np.ndarray]: + with np.load(_get_output_item_path(path, 'predictions.npz', True)) as predictions: + return {x: predictions[x] for x in predictions} + + +def dump_predictions(predictions: Dict[str, np.ndarray], path: Path) -> None: + np.savez(_get_output_item_path(path, 'predictions.npz', False), **predictions) + + +def dump_metrics(metrics: Dict[str, Any], path: Path) -> None: + dump_json(metrics, _get_output_item_path(path, 'metrics.json', False)) + + +def load_checkpoint(path: Path, *args, **kwargs) -> Dict[str, np.ndarray]: + return torch.load( + _get_output_item_path(path, 'checkpoint.pt', True), *args, **kwargs + ) + + +def get_device() -> torch.device: + if torch.cuda.is_available(): + assert os.environ.get('CUDA_VISIBLE_DEVICES') is not None + return torch.device('cuda:0') + else: + return torch.device('cpu') + + +def _print_sep(c, size=100): + print(c * size) + + +def start( + config_cls: Type[T] = RawConfig, + argv: Optional[List[str]] = None, + patch_raw_config: Optional[Callable[[RawConfig], None]] = None, +) -> Tuple[T, Path, Report]: # config # output dir # report + parser = argparse.ArgumentParser() + parser.add_argument('config', metavar='FILE') + parser.add_argument('--force', action='store_true') + parser.add_argument('--continue', action='store_true', dest='continue_') + if argv is None: + program = __main__.__file__ + args = parser.parse_args() + else: + program = argv[0] + try: + args = parser.parse_args(argv[1:]) + except Exception: + print( + 'Failed to parse `argv`.' + ' Remember that the first item of `argv` must be the path (relative to' + ' the project root) to the script/notebook.' + ) + raise + args = parser.parse_args(argv) + + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if snapshot_dir and Path(snapshot_dir).joinpath('CHECKPOINTS_RESTORED').exists(): + assert args.continue_ + + config_path = env.get_path(args.config) + output_dir = config_path.with_suffix('') + _print_sep('=') + print(f'[output] {output_dir}') + _print_sep('=') + + assert config_path.exists() + raw_config = load_config(config_path) + if patch_raw_config is not None: + patch_raw_config(raw_config) + if is_dataclass(config_cls): + config = from_dict(config_cls, raw_config) + full_raw_config = asdict(config) + else: + assert config_cls is dict + full_raw_config = config = raw_config + full_raw_config = asdict(config) + + if output_dir.exists(): + if args.force: + print('Removing the existing output and creating a new one...') + shutil.rmtree(output_dir) + output_dir.mkdir() + elif not args.continue_: + backup_output(output_dir) + print('The output directory already exists. Done!\n') + sys.exit() + elif output_dir.joinpath('DONE').exists(): + backup_output(output_dir) + print('The "DONE" file already exists. Done!') + sys.exit() + else: + print('Continuing with the existing output...') + else: + print('Creating the output...') + output_dir.mkdir() + + report = { + 'program': str(env.get_relative_path(program)), + 'environment': {}, + 'config': full_raw_config, + } + if torch.cuda.is_available(): # type: ignore[code] + report['environment'].update( + { + 'CUDA_VISIBLE_DEVICES': os.environ.get('CUDA_VISIBLE_DEVICES'), + 'gpus': zero.hardware.get_gpus_info(), + 'torch.version.cuda': torch.version.cuda, + 'torch.backends.cudnn.version()': torch.backends.cudnn.version(), # type: ignore[code] + 'torch.cuda.nccl.version()': torch.cuda.nccl.version(), # type: ignore[code] + } + ) + dump_report(report, output_dir) + dump_json(raw_config, output_dir / 'raw_config.json') + _print_sep('-') + pprint(full_raw_config, width=100) + _print_sep('-') + return cast(config_cls, config), output_dir, report + + +_LAST_SNAPSHOT_TIME = None + + +def backup_output(output_dir: Path) -> None: + backup_dir = os.environ.get('TMP_OUTPUT_PATH') + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if backup_dir is None: + assert snapshot_dir is None + return + assert snapshot_dir is not None + + try: + relative_output_dir = output_dir.relative_to(env.PROJ) + except ValueError: + return + + for dir_ in [backup_dir, snapshot_dir]: + new_output_dir = dir_ / relative_output_dir + prev_backup_output_dir = new_output_dir.with_name(new_output_dir.name + '_prev') + new_output_dir.parent.mkdir(exist_ok=True, parents=True) + if new_output_dir.exists(): + new_output_dir.rename(prev_backup_output_dir) + shutil.copytree(output_dir, new_output_dir) + # the case for evaluate.py which automatically creates configs + if output_dir.with_suffix('.toml').exists(): + shutil.copyfile( + output_dir.with_suffix('.toml'), new_output_dir.with_suffix('.toml') + ) + if prev_backup_output_dir.exists(): + shutil.rmtree(prev_backup_output_dir) + + global _LAST_SNAPSHOT_TIME + if _LAST_SNAPSHOT_TIME is None or time.time() - _LAST_SNAPSHOT_TIME > 10 * 60: + import nirvana_dl.snapshot # type: ignore[code] + + nirvana_dl.snapshot.dump_snapshot() + _LAST_SNAPSHOT_TIME = time.time() + print('The snapshot was saved!') + + +def _get_scores(metrics: Dict[str, Dict[str, Any]]) -> Optional[Dict[str, float]]: + return ( + {k: v['score'] for k, v in metrics.items()} + if 'score' in next(iter(metrics.values())) + else None + ) + + +def format_scores(metrics: Dict[str, Dict[str, Any]]) -> str: + return ' '.join( + f"[{x}] {metrics[x]['score']:.3f}" + for x in ['test', 'val', 'train'] + if x in metrics + ) + + +def finish(output_dir: Path, report: dict) -> None: + print() + _print_sep('=') + + metrics = report.get('metrics') + if metrics is not None: + scores = _get_scores(metrics) + if scores is not None: + dump_json(scores, output_dir / 'scores.json') + print(format_scores(metrics)) + _print_sep('-') + + dump_report(report, output_dir) + json_output_path = os.environ.get('JSON_OUTPUT_FILE') + if json_output_path: + try: + key = str(output_dir.relative_to(env.PROJ)) + except ValueError: + pass + else: + json_output_path = Path(json_output_path) + try: + json_data = json.loads(json_output_path.read_text()) + except (FileNotFoundError, json.decoder.JSONDecodeError): + json_data = {} + json_data[key] = load_json(output_dir / 'report.json') + json_output_path.write_text(json.dumps(json_data, indent=4)) + shutil.copyfile( + json_output_path, + os.path.join(os.environ['SNAPSHOT_PATH'], 'json_output.json'), + ) + + output_dir.joinpath('DONE').touch() + backup_output(output_dir) + print(f'Done! | {report.get("time")} | {output_dir}') + _print_sep('=') + print() + + +def from_dict(datacls: Type[T], data: dict) -> T: + assert is_dataclass(datacls) + data = deepcopy(data) + for field in fields(datacls): + if field.name not in data: + continue + if is_dataclass(field.type): + data[field.name] = from_dict(field.type, data[field.name]) + elif ( + get_origin(field.type) is Union + and len(get_args(field.type)) == 2 + and get_args(field.type)[1] is type(None) + and is_dataclass(get_args(field.type)[0]) + ): + if data[field.name] is not None: + data[field.name] = from_dict(get_args(field.type)[0], data[field.name]) + return datacls(**data) + + +def replace_factor_with_value( + config: RawConfig, + key: str, + reference_value: int, + bounds: Tuple[float, float], +) -> None: + factor_key = key + '_factor' + if factor_key not in config: + assert key in config + else: + assert key not in config + factor = config.pop(factor_key) + assert bounds[0] <= factor <= bounds[1] + config[key] = int(factor * reference_value) + + +def get_temporary_copy(path: Union[str, Path]) -> Path: + path = env.get_path(path) + assert not path.is_dir() and not path.is_symlink() + tmp_path = path.with_name( + path.stem + '___' + str(uuid.uuid4()).replace('-', '') + path.suffix + ) + shutil.copyfile(path, tmp_path) + atexit.register(lambda: tmp_path.unlink()) + return tmp_path + + +def get_python(): + python = Path('python3.9') + return str(python) if python.exists() else 'python' + +def get_catboost_config(real_data_path, is_cv=False): + ds_name = Path(real_data_path).name + C = load_json(f'tuned_models/catboost/{ds_name}_cv.json') + return C \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..0ce34ec62c2c3c306ad6b26213187ebdaedf8c60 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/requirements.txt @@ -0,0 +1,22 @@ +catboost==1.0.3 +category-encoders==2.3.0 +dython==0.5.1 +icecream==2.1.2 +libzero==0.0.8 +numpy==1.21.4 +optuna==2.10.1 +pandas==1.3.4 +pyarrow==6.0.0 +rtdl==0.0.9 +scikit-learn==1.0.2 +scipy==1.7.2 +skorch==0.11.0 +tomli-w==0.4.0 +tomli==1.2.2 +tqdm==4.62.3 + +# smote +imbalanced-learn==0.7.0 + +# tvae +rdt==0.6.4 \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_catboost.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_catboost.py new file mode 100644 index 0000000000000000000000000000000000000000..55066c2176c33c8fec14416d34736899e039a64f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_catboost.py @@ -0,0 +1,145 @@ +from catboost import CatBoostClassifier, CatBoostRegressor +from sklearn.metrics import classification_report, r2_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from pprint import pprint +from lib import concat_features, read_pure_data, get_catboost_config, read_changed_val + +def train_catboost( + parent_dir, + real_data_path, + eval_type, + T_dict, + seed = 0, + params = None, + change_val = True, + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + catboost_config = get_catboost_config(real_data_path, is_cv=True) + else: + catboost_config = params + + if 'cat_features' not in catboost_config: + catboost_config['cat_features'] = list(range(D.n_num_features, D.n_features)) + + for col in range(D.n_features): + for split in X.keys(): + if col in catboost_config['cat_features']: + X[split][col] = X[split][col].astype(str) + else: + X[split][col] = X[split][col].astype(float) + print(T_dict) + pprint(catboost_config, width=100) + print('-'*100) + + if D.is_regression: + model = CatBoostRegressor( + **catboost_config, + eval_metric='RMSE', + random_seed=seed + ) + predict = model.predict + else: + model = CatBoostClassifier( + loss_function="MultiClass" if D.is_multiclass else "Logloss", + **catboost_config, + eval_metric='TotalF1', + random_seed=seed, + class_names=[str(i) for i in range(D.n_classes)] if D.is_multiclass else ["0", "1"] + ) + predict = ( + model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit( + X['train'], D.y['train'], + eval_set=(X['val'], D.y['val']), + verbose=100 + ) + predictions = {k: predict(v) for k, v in X.items()} + print(predictions['train'].shape) + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_mlp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_mlp.py new file mode 100644 index 0000000000000000000000000000000000000000..396de4ef30589ff3c115b3bff7daa0bddeb9a57b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_mlp.py @@ -0,0 +1,176 @@ +from sklearn.metrics import classification_report, r2_score, f1_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from tab_ddpm.modules import MLP +from skorch.regressor import NeuralNetRegressor +from skorch.classifier import NeuralNetClassifier +from skorch.dataset import Dataset as SkDataset +from skorch.callbacks import EarlyStopping, EpochScoring +from skorch.helper import predefined_split +from torch.optim import AdamW +from torch.nn import MSELoss, BCEWithLogitsLoss, CrossEntropyLoss + +def train_mlp( + parent_dir, + real_data_path, + eval_type, + T_dict, + params = None, + change_val = False, + seed = 0, + device = "cuda:0" +): + zero.improve_reproducibility(seed) + synthetic_data_path = os.path.join(parent_dir) if parent_dir is not None else None + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = lib.read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(synthetic_data_path) + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print('loading synthetic data...') + X_num, X_cat, y = lib.read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = lib.read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = lib.read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = lib.read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = lib.concat_features(D) + + X["train"], D.y["train"] = shuffle(X["train"], D.y["train"], random_state=seed) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + params = lib.load_json(f"tuned_models/mlp/{Path(real_data_path).name}_cv.json") + + mlp_params = {} + if params is not None: + mlp_params["d_layers"] = params["d_layers"] + mlp_params["dropout"] = params["dropout"] + # mlp_params["n_blocks"] = params["n_blocks"] + # mlp_params["d_main"] = params["d_main"] + # mlp_params["d_hidden"] = params["d_hidden"] + # mlp_params["dropout_first"] = params["dropout_first"] + # mlp_params["dropout_second"] = params["dropout_second"] + mlp_params["d_in"] = X["train"].shape[1] + mlp_params["d_out"] = D.nn_output_dim + + model = MLP.make_baseline(**mlp_params) + + if D.is_regression: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + elif D.is_binclass: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + else: + y = {k: D.y[k].astype(np.int64) for k in D.y} + + train_ds = SkDataset(X = X["train"].to_numpy(), y = y["train"]) + val_ds = SkDataset(X = X["val"].to_numpy(), y = y["val"]) + es = EarlyStopping(monitor="valid_loss", patience=16) + + print('-'*100) + + def f1(net, X, y): + y_pred = net.predict(X) + return f1_score(y, y_pred, average="macro") + + def r2(net, X, y): + y_pred = net.predict(X) + return r2_score(y, y_pred) + + if D.is_regression: + net = NeuralNetRegressor( + model, + criterion=MSELoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(r2, lower_is_better=False)], + ) + + else: + net = NeuralNetClassifier( + model, + criterion=BCEWithLogitsLoss if D.is_binclass else CrossEntropyLoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(f1, lower_is_better=False)], + ) + + net.fit( + X=train_ds.X, + y=train_ds.y + ) + + print("LAST:", len(net.history)) + + predictions = {k: net.predict_proba(v.to_numpy())[:, 1] if D.is_binclass else + net.predict_proba(v.to_numpy()) if D.is_multiclass else + net.predict(v.to_numpy()) + for k, v in X.items() + } + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_mlp.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds.py new file mode 100644 index 0000000000000000000000000000000000000000..cc4970e2a7293234d9d08afba2798719499bfc75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds.py @@ -0,0 +1,121 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import shutil +from pathlib import Path +from copy import deepcopy +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabgan.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="catboost", + n_datasets=1, + dump=True, + change_val=False +): + + metrics_seeds_report = lib.SeedsMetricsReport() + parent_dir = Path(raw_config["parent_dir"]) + + if eval_type == 'real': + n_datasets = 1 + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real' and n_datasets > 1: + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + T_dict = deepcopy(raw_config['eval']['T']) + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + if model_type == "catboost": + T_dict["normalization"] = None + T_dict["cat_encoding"] = None + metric_report = train_catboost( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + elif model_type == "mlp": + T_dict["normalization"] = "quantile" + T_dict["cat_encoding"] = "one-hot" + metric_report = train_mlp( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report.add_report(metric_report) + + metrics_seeds_report.get_mean_std() + res = metrics_seeds_report.print_result() + if os.path.exists(parent_dir/ f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..187c88d31abc73efd4744bc1aa37bcc21d8c117f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_seeds_simple.py @@ -0,0 +1,130 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import pandas as pd +import numpy as np +from pathlib import Path +from eval_simple import train_simple +from copy import deepcopy +import shutil + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabganp.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="simple", + n_datasets=1, + dump=True, + change_val=False +): + parent_dir = Path(raw_config["parent_dir"]) + models = ["tree", "lr", "rf", "mlp"] + metrics_seeds_report = { + k: lib.SeedsMetricsReport() for k in models + } + + if eval_type == 'real': + n_datasets = 1 + + T_dict = deepcopy(raw_config['eval']['T']) + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real': + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + for model in models: + metric_report = train_simple( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + model_name=model, + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report[model].add_report(metric_report) + for k in models: + metrics_seeds_report[k].get_mean_std() + res = { + k: metrics_seeds_report[k].print_result() for k in models + } + + m1, m2 = ("r2-mean", "rmse-mean") if "r2-mean" in res["tree"]["val"] else ("f1-mean", "acc-mean") + res["avg"] = { + "val": { + m1: np.around(np.mean([res[k]["val"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["val"][m2] for k in models]), 4) + }, + "test": { + m1: np.around(np.mean([res[k]["test"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["test"][m2] for k in models]), 4) + }, + } + + if os.path.exists(parent_dir / f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..5e58199394b29839052de5abde1194530150abf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/eval_simple.py @@ -0,0 +1,141 @@ +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from lib import concat_features, read_pure_data, read_changed_val +from sklearn.utils import shuffle +import lib +from sklearn.tree import DecisionTreeClassifier, DecisionTreeRegressor +from sklearn.ensemble import RandomForestClassifier, RandomForestRegressor +from sklearn.linear_model import LogisticRegression, Ridge +from sklearn.neural_network import MLPClassifier, MLPRegressor + +def train_simple( + parent_dir, + real_data_path, + eval_type, + T_dict, + model_name = "tree", + seed = 0, + change_val = True, + params = None, # dummy + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + T = lib.Transformations(**T_dict) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + # ixs = np.random.choice(len(D.y["train"]), min(info["train_size"], len(D.y["train"])), replace=False) + # X["train"] = X["train"].iloc[ixs] + # D.y["train"] = D.y["train"][ixs] + + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + print(T_dict) + print('-'*100) + + if D.is_regression: + models = { + "tree": DecisionTreeRegressor(max_depth=28, random_state=seed), + "rf": RandomForestRegressor(max_depth=28, random_state=seed), + "lr": Ridge(max_iter=500, random_state=seed), + "mlp": MLPRegressor(max_iter=100, random_state=seed) + } + else: + models = { + "tree": DecisionTreeClassifier(max_depth=28, random_state=seed), + "rf": RandomForestClassifier(max_depth=28, random_state=seed), + "lr": LogisticRegression(max_iter=500, n_jobs=2, random_state=seed), + "mlp": MLPClassifier(max_iter=100, random_state=seed) + } + + model = models[model_name] + + predict = ( + model.predict + if D.is_regression + else model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit(X['train'], D.y['train']) + + predictions = {k: predict(v) for k, v in X.items()} + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + print(model.__class__.__name__) + metrics_report.print_metrics() + + # if parent_dir is not None: + # lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/pipeline.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/pipeline.py new file mode 100644 index 0000000000000000000000000000000000000000..64a297813fd582cb86438f00981939571b53c162 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/pipeline.py @@ -0,0 +1,112 @@ +import tomli +import shutil +import os +import argparse +from scripts.train import train +from scripts.sample import sample +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple +import pandas as pd +import matplotlib.pyplot as plt +import zero +import lib +import torch + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + if 'device' in raw_config: + device = torch.device(raw_config['device']) + else: + device = torch.device('cuda:1') + + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + + if args.train: + train( + **raw_config['train']['main'], + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + change_val=args.change_val + ) + if args.sample: + sample( + num_samples=raw_config['sample']['num_samples'], + batch_size=raw_config['sample']['batch_size'], + disbalance=raw_config['sample'].get('disbalance', None), + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_path=os.path.join(raw_config['parent_dir'], 'model.pt'), + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + seed=raw_config['sample'].get('seed', 0), + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + elif raw_config['eval']['type']['eval_model'] == 'mlp': + train_mlp( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val, + device=device + ) + elif raw_config['eval']['type']['eval_model'] == 'simple': + train_simple( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/resample_privacy.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/resample_privacy.py new file mode 100644 index 0000000000000000000000000000000000000000..54d320c3bb19ce5275d25704ad82f086601ee65d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/resample_privacy.py @@ -0,0 +1,257 @@ +""" +Adapted from https://github.com/Team-TUD/CTAB-GAN/tree/main/model/eval +""" + +import argparse +import lib +import os +import shutil +import zero +from sample import sample +from smote.sample_smote import sample_smote +from sklearn.preprocessing import MinMaxScaler, OneHotEncoder +from sklearn.metrics import pairwise_distances +from pathlib import Path +import tempfile +from eval_seeds import eval_seeds +import numpy as np +import subprocess +import warnings +import torch + +zero.improve_reproducibility(0) + +warnings.filterwarnings("ignore", category=FutureWarning) + + +def privacy_metrics(real_path,fake_path, data_percent=15): + + """ + Returns privacy metrics + + Inputs: + 1) real_path -> path to real data + 2) fake_path -> path to corresponding synthetic data + 3) data_percent -> percentage of data to be sampled from real and synthetic datasets for computing privacy metrics + Outputs: + 1) List containing the 5th percentile distance to closest record (DCR) between real and synthetic as well as within real and synthetic datasets + along with 5th percentile of nearest neighbour distance ratio (NNDR) between real and synthetic as well as within real and synthetic datasets + + """ + task_type = lib.load_json(real_path + "/info.json")["task_type"] + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_path, 'train') + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(fake_path, 'train') + + if task_type == 'regression': + X_num_real = np.concatenate([X_num_real, y_real[:, np.newaxis]], axis=1) + X_num_fake = np.concatenate([X_num_fake, y_fake[:, np.newaxis]], axis=1) + else: + if X_cat_fake is None: + X_cat_real = y_real[:, np.newaxis].astype(int).astype(str) + X_cat_fake = y_fake[:, np.newaxis].astype(int).astype(str) + else: + X_cat_real = np.concatenate([X_cat_real, y_real[:, np.newaxis].astype(int).astype(str)], axis=1) + X_cat_fake = np.concatenate([X_cat_fake, y_fake[:, np.newaxis].astype(int).astype(str)], axis=1) + + if len(y_real) > 50000: + ixs = np.random.choice(len(y_real), 50000, replace=False) + X_num_real = X_num_real[ixs] + X_cat_real = X_cat_real[ixs] if X_cat_real is not None else None + + if len(y_fake) > 50000: + ixs = np.random.choice(len(y_fake), 50000, replace=False) + X_num_fake = X_num_fake[ixs] + X_cat_fake = X_cat_fake[ixs] if X_cat_fake is not None else None + + + mm = MinMaxScaler().fit(X_num_real) + X_real = mm.transform(X_num_real) + X_fake = mm.transform(X_num_fake) + if X_cat_real is not None: + ohe = OneHotEncoder().fit(X_cat_real) + X_cat_real = ohe.transform(X_cat_real) / np.sqrt(2) + X_cat_fake = ohe.transform(X_cat_fake) / np.sqrt(2) + + X_real = np.concatenate([X_real, X_cat_real.todense()], axis=1) + X_fake = np.concatenate([X_fake, X_cat_fake.todense()], axis=1) + + # X_real = np.unique(X_real, axis=0) + # X_fake = np.unique(X_fake, axis=0) + + # Computing pair-wise distances between real and synthetic + dist_rf = pairwise_distances(X_fake, Y=X_real, metric='l2', n_jobs=-1) + # Computing pair-wise distances within real + # dist_rr = pairwise_distances(X_real, Y=None, metric='l2', n_jobs=-1) + # Computing pair-wise distances within synthetic + # dist_ff = pairwise_distances(X_fake, Y=None, metric='l2', n_jobs=-1) + + + # Removes distances of data points to themselves to avoid 0s within real and synthetic + # rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + # rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + + # Computing first and second smallest nearest neighbour distances between real and synthetic + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + # Computing first and second smallest nearest neighbour distances within real + # smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + # smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + # Computing first and second smallest nearest neighbour distances within synthetic + # smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + # smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + + + # Computing 5th percentiles for DCR and NNDR between and within real and synthetic datasets + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + # min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + # fifth_perc_rr = np.percentile(min_dist_rr,5) + # min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + # fifth_perc_ff = np.percentile(min_dist_ff,5) + # nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + # nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + # nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + # nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + # nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + # nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + + # return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) + return min_dist_rf # , min_dist_rr + +def sample_wrapper(method, config, num_samples=None, seed=0): + if method == "ddpm": + sample( + num_samples=num_samples, + batch_size=config['sample']['batch_size'], + disbalance=config['sample'].get('disbalance', None), + **config['diffusion_params'], + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + model_path=os.path.join(config['parent_dir'], 'model.pt'), + model_type=config['model_type'], + model_params=config['model_params'], + T_dict=config['train']['T'], + num_numerical_features=config['num_numerical_features'], + seed=seed, + change_val=False, + device=torch.device(config["device"]) + ) + elif method == "smote": + sample_smote( + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + **config['smote_params'], + seed=seed, + change_val=False + ) + +def resample_privacy(config_path, method, q): + with tempfile.TemporaryDirectory() as dir_: + config = lib.load_config(config_path) + if method == "ddpm": + shutil.copy2(os.path.join(config['parent_dir'], 'model.pt'), os.path.join(dir_, 'model.pt')) + config["parent_dir"] = str(dir_) + parent_dir = config["parent_dir"] + + sample_wrapper(method, config, num_samples=config["sample"].get("num_samples", 0)) + + dists = privacy_metrics(config["real_data_path"], parent_dir) + old_privacy = np.median(dists) + + q10 = np.quantile(dists, q=q) + print(f"Q: {q10}") + to_drop = np.where(dists < q10) + + X_num, X_cat, y = lib.read_pure_data(parent_dir) + num_samples = len(y) + X_num = np.delete(X_num, to_drop, axis=0) + X_cat = np.delete(X_cat, to_drop, axis=0) if X_cat is not None else None + y = np.delete(y, to_drop, axis=0) + i = 1 + + while len(y) < num_samples and i <= 10: + print(f"{len(y)}/{num_samples}") + + sample_wrapper(method, config, num_samples=config["sample"].get("batch_size", 0), seed=i) + + i += 1 + + X_num_t, X_cat_t, y_t = lib.read_pure_data(parent_dir) + dists = privacy_metrics(config["real_data_path"], parent_dir) + to_drop = np.where(dists < q10) + X_num_t = np.delete(X_num_t, to_drop, axis=0) + X_cat_t = np.delete(X_cat_t, to_drop, axis=0) if X_cat is not None else None + y_t = np.delete(y_t, to_drop, axis=0) + + X_num = np.concatenate([X_num, X_num_t], axis=0)[:num_samples] + X_cat = np.concatenate([X_cat, X_cat_t], axis=0)[:num_samples] if X_cat is not None else None + y = np.concatenate([y, y_t], axis=0)[:num_samples] + + # np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + # if X_cat is not None: + # np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + # np.save(os.path.join(parent_dir, 'y_train'), y) + + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if X_cat is not None: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y) + + new_dists = privacy_metrics(config["real_data_path"], parent_dir) + + res = eval_seeds( + config, + n_seeds=10, + eval_type="synthetic", + model_type="catboost", + n_datasets=1, + dump=False + ) + print(f"Old: {old_privacy:.4f}, New: {np.median(new_dists):.4f}") + + metric = "r2-mean" if "r2-mean" in res["test"] else "f1-mean" + return res["test"][metric], np.around(np.median(new_dists), 4) + +def resample_privacy_qs(config_path, method): + config = lib.load_config(config_path) + scores = [] + privacies = [] + + eval_res = lib.load_json(Path(config["parent_dir"]) / "eval_catboost.json")["synthetic"]["test"] + metric = "r2-mean" if "r2-mean" in eval_res else "f1-mean" + scores.append(eval_res[metric]) + privacies.append(np.median(privacy_metrics(config["real_data_path"], config["parent_dir"]))) + + for q in [0.1, 0.2, 0.3, 0.4]: + score, privacy = resample_privacy(config_path, method, q) + scores.append(score) + privacies.append(privacy) + + lib.dump_json( + {"scores": scores, "privacies": privacies}, + Path(config["parent_dir"]) / "privacies.json" + ) + +def calc_privacy(config_path, method, seed=0): + config = lib.load_config(config_path) + sample_wrapper(method, config, num_samples=config["sample"]["num_samples"], seed=seed) + timer = zero.Timer() + timer.run() + dists = privacy_metrics(config["real_data_path"], config["parent_dir"]) + privacy_val = np.median(dists) + lib.dump_json({"privacy": privacy_val}, os.path.join(config["parent_dir"], "privacy.json")) + print(f"Elapsed tine:{str(timer)}") + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('method', type=str) + args = parser.parse_args() + + calc_privacy( + args.config, + args.method + ) + +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/sample.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/sample.py new file mode 100644 index 0000000000000000000000000000000000000000..118592f7979bde1047cafcd90b555fbd826060d4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/sample.py @@ -0,0 +1,161 @@ +import torch +import numpy as np +import zero +import os +from tab_ddpm.gaussian_multinomial_diffsuion import GaussianMultinomialDiffusion +from tab_ddpm.utils import FoundNANsError +from scripts.utils_train import get_model, make_dataset +from lib import round_columns +import lib + +def to_good_ohe(ohe, X): + indices = np.cumsum([0] + ohe._n_features_outs) + Xres = [] + for i in range(1, len(indices)): + x_ = np.max(X[:, indices[i - 1]:indices[i]], axis=1) + t = X[:, indices[i - 1]:indices[i]] - x_.reshape(-1, 1) + Xres.append(np.where(t >= 0, 1, 0)) + return np.hstack(Xres) + +def sample( + parent_dir, + real_data_path = 'data/higgs-small', + batch_size = 2000, + num_samples = 0, + model_type = 'mlp', + model_params = None, + model_path = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + disbalance = None, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + zero.improve_reproducibility(seed) + use_ddim = os.environ.get('TABDDPM_SAMPLE_DDIM', '').strip().lower() in ('1', 'true', 'yes') + + T = lib.Transformations(**T_dict) + D = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(D.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + + num_numerical_features_ = D.X_num['train'].shape[1] if D.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features_ + model_params['d_in'] = int(d_in) + model = get_model( + model_type, + model_params, + num_numerical_features_, + category_sizes=D.get_category_sizes('train') + ) + + model.load_state_dict( + torch.load(model_path, map_location="cpu") + ) + + diffusion = GaussianMultinomialDiffusion( + K, + num_numerical_features=num_numerical_features_, + denoise_fn=model, num_timesteps=num_timesteps, + gaussian_loss_type=gaussian_loss_type, scheduler=scheduler, device=device + ) + + diffusion.to(device) + diffusion.eval() + + _, empirical_class_dist = torch.unique(torch.from_numpy(D.y['train']), return_counts=True) + # empirical_class_dist = empirical_class_dist.float() + torch.tensor([-5000., 10000.]).float() + if disbalance == 'fix': + empirical_class_dist[0], empirical_class_dist[1] = empirical_class_dist[1], empirical_class_dist[0] + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim) + + elif disbalance == 'fill': + ix_major = empirical_class_dist.argmax().item() + val_major = empirical_class_dist[ix_major].item() + x_gen, y_gen = [], [] + for i in range(empirical_class_dist.shape[0]): + if i == ix_major: + continue + distrib = torch.zeros_like(empirical_class_dist) + distrib[i] = 1 + num_samples = val_major - empirical_class_dist[i].item() + x_temp, y_temp = diffusion.sample_all(num_samples, batch_size, distrib.float(), ddim=use_ddim) + x_gen.append(x_temp) + y_gen.append(y_temp) + + x_gen = torch.cat(x_gen, dim=0) + y_gen = torch.cat(y_gen, dim=0) + + else: + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim) + + + # try: + # except FoundNANsError as ex: + # print("Found NaNs during sampling!") + # loader = lib.prepare_fast_dataloader(D, 'train', 8) + # x_gen = next(loader)[0] + # y_gen = torch.multinomial( + # empirical_class_dist.float(), + # num_samples=8, + # replacement=True + # ) + X_gen, y_gen = x_gen.numpy(), y_gen.numpy() + + ### + # X_num_unnorm = X_gen[:, :num_numerical_features] + # lo = np.percentile(X_num_unnorm, 2.5, axis=0) + # hi = np.percentile(X_num_unnorm, 97.5, axis=0) + # idx = (lo < X_num_unnorm) & (hi > X_num_unnorm) + # X_gen = X_gen[np.all(idx, axis=1)] + # y_gen = y_gen[np.all(idx, axis=1)] + ### + + num_numerical_features = num_numerical_features + int(D.is_regression and not model_params["is_y_cond"]) + + X_num_ = X_gen + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_unnorm'), X_gen[:, num_numerical_features:]) + # _, _, cat_encoder = lib.cat_encode({'train': X_cat_real}, T_dict['cat_encoding'], y_real, T_dict['seed'], True) + if T_dict['cat_encoding'] == 'one-hot': + X_gen[:, num_numerical_features:] = to_good_ohe(D.cat_transform.steps[0][1], X_num_[:, num_numerical_features:]) + X_cat = D.cat_transform.inverse_transform(X_gen[:, num_numerical_features:]) + + if num_numerical_features_ != 0: + # _, normalize = lib.normalize({'train' : X_num_real}, T_dict['normalization'], T_dict['seed'], True) + np.save(os.path.join(parent_dir, 'X_num_unnorm'), X_gen[:, :num_numerical_features]) + X_num_ = D.num_transform.inverse_transform(X_gen[:, :num_numerical_features]) + X_num = X_num_[:, :num_numerical_features] + + X_num_real = np.load(os.path.join(real_data_path, "X_num_train.npy"), allow_pickle=True) + disc_cols = [] + for col in range(X_num_real.shape[1]): + uniq_vals = np.unique(X_num_real[:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + print("Discrete cols:", disc_cols) + # 仅当 regression 且 y 在 X_num 中(非 is_y_cond)时才提取 y;否则 y_gen 已由 sample_all 返回 + if model_params['num_classes'] == 0 and not model_params.get('is_y_cond', True): + y_gen = X_num[:, 0] + X_num = X_num[:, 1:] + if len(disc_cols): + X_num = round_columns(X_num_real, X_num, disc_cols) + + if num_numerical_features != 0: + print("Num shape: ", X_num.shape) + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y_gen) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/train.py new file mode 100644 index 0000000000000000000000000000000000000000..84a4eef3c97b080d1cf1b122c7d4117b74a1cefd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/train.py @@ -0,0 +1,158 @@ +from copy import deepcopy +import torch +import os +import numpy as np +import zero +from tab_ddpm import GaussianMultinomialDiffusion +from scripts.utils_train import get_model, make_dataset, update_ema +import lib +import pandas as pd + +class Trainer: + def __init__(self, diffusion, train_iter, lr, weight_decay, steps, device=torch.device('cuda:1')): + self.diffusion = diffusion + self.ema_model = deepcopy(self.diffusion._denoise_fn) + for param in self.ema_model.parameters(): + param.detach_() + + self.train_iter = train_iter + self.steps = steps + self.init_lr = lr + self.optimizer = torch.optim.AdamW(self.diffusion.parameters(), lr=lr, weight_decay=weight_decay) + self.device = device + self.loss_history = pd.DataFrame(columns=['step', 'mloss', 'gloss', 'loss']) + self.log_every = 100 + self.print_every = 500 + self.ema_every = 1000 + + def _anneal_lr(self, step): + frac_done = step / self.steps + lr = self.init_lr * (1 - frac_done) + for param_group in self.optimizer.param_groups: + param_group["lr"] = lr + + def _run_step(self, x, out_dict): + x = x.to(self.device) + for k in out_dict: + out_dict[k] = out_dict[k].long().to(self.device) + self.optimizer.zero_grad() + loss_multi, loss_gauss = self.diffusion.mixed_loss(x, out_dict) + loss = loss_multi + loss_gauss + loss.backward() + self.optimizer.step() + + return loss_multi, loss_gauss + + def run_loop(self): + step = 0 + curr_loss_multi = 0.0 + curr_loss_gauss = 0.0 + + curr_count = 0 + while step < self.steps: + x, out_dict = next(self.train_iter) + out_dict = {'y': out_dict} + batch_loss_multi, batch_loss_gauss = self._run_step(x, out_dict) + + self._anneal_lr(step) + + curr_count += len(x) + curr_loss_multi += batch_loss_multi.item() * len(x) + curr_loss_gauss += batch_loss_gauss.item() * len(x) + + if (step + 1) % self.log_every == 0: + mloss = np.around(curr_loss_multi / curr_count, 4) + gloss = np.around(curr_loss_gauss / curr_count, 4) + if (step + 1) % self.print_every == 0: + print(f'Step {(step + 1)}/{self.steps} MLoss: {mloss} GLoss: {gloss} Sum: {mloss + gloss}') + self.loss_history.loc[len(self.loss_history)] =[step + 1, mloss, gloss, mloss + gloss] + curr_count = 0 + curr_loss_gauss = 0.0 + curr_loss_multi = 0.0 + + update_ema(self.ema_model.parameters(), self.diffusion._denoise_fn.parameters()) + + step += 1 + +def train( + parent_dir, + real_data_path = 'data/higgs-small', + steps = 1000, + lr = 0.002, + weight_decay = 1e-4, + batch_size = 1024, + model_type = 'mlp', + model_params = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + real_data_path = os.path.normpath(real_data_path) + parent_dir = os.path.normpath(parent_dir) + + zero.improve_reproducibility(seed) + + T = lib.Transformations(**T_dict) + + dataset = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(dataset.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + print(K) + + num_numerical_features = dataset.X_num['train'].shape[1] if dataset.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features + model_params['d_in'] = d_in + print(d_in) + + print(model_params) + model = get_model( + model_type, + model_params, + num_numerical_features, + category_sizes=dataset.get_category_sizes('train') + ) + model.to(device) + + # train_loader = lib.prepare_beton_loader(dataset, split='train', batch_size=batch_size) + train_loader = lib.prepare_fast_dataloader(dataset, split='train', batch_size=batch_size) + + + + diffusion = GaussianMultinomialDiffusion( + num_classes=K, + num_numerical_features=num_numerical_features, + denoise_fn=model, + gaussian_loss_type=gaussian_loss_type, + num_timesteps=num_timesteps, + scheduler=scheduler, + device=device + ) + diffusion.to(device) + diffusion.train() + + trainer = Trainer( + diffusion, + train_loader, + lr=lr, + weight_decay=weight_decay, + steps=steps, + device=device + ) + trainer.run_loop() + + trainer.loss_history.to_csv(os.path.join(parent_dir, 'loss.csv'), index=False) + torch.save(diffusion._denoise_fn.state_dict(), os.path.join(parent_dir, 'model.pt')) + torch.save(trainer.ema_model.state_dict(), os.path.join(parent_dir, 'model_ema.pt')) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_ddpm.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_ddpm.py new file mode 100644 index 0000000000000000000000000000000000000000..5a95dc23cab775a9ca7b7eb496bcefef58691dce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_ddpm.py @@ -0,0 +1,127 @@ +import subprocess +import lib +import os +import optuna +from copy import deepcopy +import shutil +import argparse +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('eval_model', type=str) +parser.add_argument('prefix', type=str) +parser.add_argument('--eval_seeds', action='store_true', default=False) + +args = parser.parse_args() +train_size = args.train_size +ds_name = args.ds_name +eval_type = args.eval_type +assert eval_type in ('merged', 'synthetic') +prefix = str(args.prefix) + +pipeline = f'scripts/pipeline.py' +base_config_path = f'exp/{ds_name}/config.toml' +parent_path = Path(f'exp/{ds_name}/') +exps_path = Path(f'exp/{ds_name}/many-exps/') # temporary dir. maybe will be replaced with tempdiвdr +eval_seeds = f'scripts/eval_seeds.py' + +os.makedirs(exps_path, exist_ok=True) + +def _suggest_mlp_layers(trial): + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 7, 10 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + return d_layers + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + d_layers = _suggest_mlp_layers(trial) + weight_decay = 0.0 + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [500]) # for debug + gaussian_loss_type = 'mse' + # scheduler = trial.suggest_categorical('scheduler', ['cosine', 'linear']) + num_timesteps = trial.suggest_categorical('num_timesteps', [100, 1000]) + num_samples = int(train_size * (2 ** trial.suggest_int('num_samples', -2, 1))) + + base_config = lib.load_config(base_config_path) + + base_config['train']['main']['lr'] = lr + base_config['train']['main']['steps'] = steps + base_config['train']['main']['batch_size'] = batch_size + base_config['train']['main']['weight_decay'] = weight_decay + base_config['model_params']['rtdl_params']['d_layers'] = d_layers + base_config['eval']['type']['eval_type'] = eval_type + base_config['sample']['num_samples'] = num_samples + base_config['diffusion_params']['gaussian_loss_type'] = gaussian_loss_type + base_config['diffusion_params']['num_timesteps'] = num_timesteps + # base_config['diffusion_params']['scheduler'] = scheduler + + base_config['parent_dir'] = str(exps_path / f"{trial.number}") + base_config['eval']['type']['eval_model'] = args.eval_model + if args.eval_model == "mlp": + base_config['eval']['T']['normalization'] = "quantile" + base_config['eval']['T']['cat_encoding'] = "one-hot" + + trial.set_user_attr("config", base_config) + + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--train', '--change_val'], check=True) + + n_datasets = 5 + score = 0.0 + + for sample_seed in range(n_datasets): + base_config['sample']['seed'] = sample_seed + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--sample', '--eval', '--change_val'], check=True) + + report_path = str(Path(base_config['parent_dir']) / f'results_{args.eval_model}.json') + report = lib.load_json(report_path) + + if 'r2' in report['metrics']['val']: + score += report['metrics']['val']['r2'] + else: + score += report['metrics']['val']['macro avg']['f1-score'] + + shutil.rmtree(exps_path / f"{trial.number}") + + return score / n_datasets + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +best_config_path = parent_path / f'{prefix}_best/config.toml' +best_config = study.best_trial.user_attrs['config'] +best_config["parent_dir"] = str(parent_path / f'{prefix}_best/') + +os.makedirs(parent_path / f'{prefix}_best', exist_ok=True) +lib.dump_config(best_config, best_config_path) +lib.dump_json(optuna.importance.get_param_importances(study), parent_path / f'{prefix}_best/importance.json') + +subprocess.run(['python3.9', f'{pipeline}', '--config', f'{best_config_path}', '--train', '--sample'], check=True) + +if args.eval_seeds: + best_exp = str(parent_path / f'{prefix}_best/config.toml') + subprocess.run(['python3.9', f'{eval_seeds}', '--config', f'{best_exp}', '10', "ddpm", eval_type, args.eval_model, '5'], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_evaluation_model.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_evaluation_model.py new file mode 100644 index 0000000000000000000000000000000000000000..8def5fd6cd1f609893e4de5f5c9708edb0a2efb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/tune_evaluation_model.py @@ -0,0 +1,145 @@ +import optuna +import lib +import argparse +from eval_catboost import train_catboost +from eval_mlp import train_mlp +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('model', type=str) +parser.add_argument('tune_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +data_path = Path(f"data/{args.ds_name}") +best_params = None + +assert args.tune_type in ("cv", "val") + +def _suggest(trial: optuna.trial.Trial, distribution: str, label: str, *args): + return getattr(trial, f'suggest_{distribution}')(label, *args) + +def _suggest_optional(trial: optuna.trial.Trial, distribution: str, label: str, *args): + if trial.suggest_categorical(f"optional_{label}", [True, False]): + return _suggest(trial, distribution, label, *args) + else: + return 0.0 + +def _suggest_mlp_layers(trial: optuna.trial.Trial, mlp_d_layers: list[int]): + + min_n_layers, max_n_layers = mlp_d_layers[0], mlp_d_layers[1] + d_min, d_max = mlp_d_layers[2], mlp_d_layers[3] + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + + return d_layers + +def suggest_mlp_params(trial): + params = {} + params["lr"] = trial.suggest_loguniform("lr", 5e-5, 0.005) + params["dropout"] = _suggest_optional(trial, "uniform", "dropout", 0.0, 0.5) + params["weight_decay"] = _suggest_optional(trial, "loguniform", "weight_decay", 1e-6, 1e-2) + params["d_layers"] = _suggest_mlp_layers(trial, [1, 8, 6, 10]) + + return params + +def suggest_catboost_params(trial): + params = {} + params["learning_rate"] = trial.suggest_loguniform("learning_rate", 0.001, 1.0) + params["depth"] = trial.suggest_int("depth", 3, 10) + params["l2_leaf_reg"] = trial.suggest_uniform("l2_leaf_reg", 0.1, 10.0) + params["bagging_temperature"] = trial.suggest_uniform("bagging_temperature", 0.0, 1.0) + params["leaf_estimation_iterations"] = trial.suggest_int("leaf_estimation_iterations", 1, 10) + + params = params | { + "iterations": 2000, + "early_stopping_rounds": 50, + "od_pval": 0.001, + "task_type": "CPU", # "GPU", may affect performance + "thread_count": 4, + # "devices": "0", # for GPU + } + + return params + +def objective(trial): + if args.model == "mlp": + params = suggest_mlp_params(trial) + train_func = train_mlp + T_dict = { + "seed": 0, + "normalization": "quantile", + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": "one-hot", + "y_policy": "default" + } + else: + params = suggest_catboost_params(trial) + train_func = train_catboost + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + trial.set_user_attr("params", params) + if args.tune_type == "cv": + score = 0.0 + for fold in range(5): + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path / f"kfolds/{fold}", + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score += metrics_report.get_val_score() + score /= 5 + + elif args.tune_type == "val": + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path, + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score = metrics_report.get_val_score() + + return score + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=100, show_progress_bar=True) + +bets_params = study.best_trial.user_attrs['params'] + +best_params_path = f"tuned_models/{args.model}/{args.ds_name}_{args.tune_type}.json" + +lib.dump_json(bets_params, best_params_path) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/utils_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/utils_train.py new file mode 100644 index 0000000000000000000000000000000000000000..4132ca56fb8e063111f916f903ef4e99206486e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/scripts/utils_train.py @@ -0,0 +1,89 @@ +import numpy as np +import os +import lib +from tab_ddpm.modules import MLPDiffusion, ResNetDiffusion + +def get_model( + model_name, + model_params, + n_num_features, + category_sizes +): + print(model_name) + if model_name == 'mlp': + model = MLPDiffusion(**model_params) + elif model_name == 'resnet': + model = ResNetDiffusion(**model_params) + else: + raise "Unknown model!" + return model + +def update_ema(target_params, source_params, rate=0.999): + """ + Update target parameters to be closer to those of source parameters using + an exponential moving average. + :param target_params: the target parameter sequence. + :param source_params: the source parameter sequence. + :param rate: the EMA rate (closer to 1 means slower). + """ + for targ, src in zip(target_params, source_params): + targ.detach().mul_(rate).add_(src.detach(), alpha=1 - rate) + +def concat_y_to_X(X, y): + if X is None: + return y.reshape(-1, 1) + return np.concatenate([y.reshape(-1, 1), X], axis=1) + +def make_dataset( + data_path: str, + T: lib.Transformations, + num_classes: int, + is_y_cond: bool, + change_val: bool +): + # classification + if num_classes > 0: + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) or not is_y_cond else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if X_num is not None: + X_num[split] = X_num_t + if not is_y_cond: + X_cat_t = concat_y_to_X(X_cat_t, y_t) + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + else: + # regression + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) or not is_y_cond else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if not is_y_cond: + X_num_t = concat_y_to_X(X_num_t, y_t) + if X_num is not None: + X_num[split] = X_num_t + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + + info = lib.load_json(os.path.join(data_path, 'info.json')) + + D = lib.Dataset( + X_num, + X_cat, + y, + y_info={}, + task_type=lib.TaskType(info['task_type']), + n_classes=info.get('n_classes') + ) + + if change_val: + D = lib.change_val(D) + + return lib.transform_dataset(D, T, None) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/pipeline_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/pipeline_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..4a6775493e975104c268a2cd177f953ea9589d0a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/pipeline_smote.py @@ -0,0 +1,68 @@ +import tomli +import shutil +import os +import argparse +from sample_smote import sample_smote +from scripts.eval_catboost import train_catboost +# from scripts.eval_mlp import train_mlp +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + if args.sample: + sample_smote( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + **raw_config['smote_params'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/sample_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/sample_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..63674186c3f1524d57bb4882f0c3dd432147230f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/sample_smote.py @@ -0,0 +1,210 @@ +import os +import lib +import argparse +import numpy as np +from pathlib import Path +from typing import Union, Any +from imblearn.over_sampling import SMOTE, SMOTENC +from sklearn.model_selection import train_test_split +from sklearn.preprocessing import MinMaxScaler +from sklearn.utils import check_random_state + +class MySMOTE(SMOTE): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None, + ): + super().__init__( + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=lam1 + self.lam2=lam2 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +class MySMOTENC(SMOTENC): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + categorical_features, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None + ): + super().__init__( + categorical_features=categorical_features, + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=0.0 + self.lam2=1.0 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0, lam1=0.0, lam2=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +def save_data(X, y, path, n_cat_features=0): + if n_cat_features > 0: + X_num = X[:, :-n_cat_features] + X_cat = X[:, -n_cat_features:] + else: + X_num = X + X_cat = None + + + np.save(path / "X_num_train", X_num.astype(float), allow_pickle=True) + np.save(path / "y_train", y, allow_pickle=True) + if X_cat is not None: + np.save(path / "X_cat_train", X_cat, allow_pickle=True) + +def sample_smote( + parent_dir, + real_data_path, + eval_type = "synthetic", + k_neighbours = 5, + frac_samples = 1.0, + frac_lam_del = 0.0, + change_val = False, + save = True, + seed = 0 +): + lam1 = 0.0 + frac_lam_del / 2 + lam2 = 1.0 - frac_lam_del / 2 + + real_data_path = Path(real_data_path) + info = lib.load_json(real_data_path / 'info.json') + is_regression = info['task_type'] == 'regression' + + X_num = {} + X_cat = {} + y = {} + + if change_val: + X_num['train'], X_cat['train'], y['train'], X_num['val'], X_cat['val'], y['val'] = lib.read_changed_val(real_data_path) + else: + X_num['train'], X_cat['train'], y['train'] = lib.read_pure_data(real_data_path, 'train') + X_num['val'], X_cat['val'], y['val'] = lib.read_pure_data(real_data_path, 'val') + X_num['test'], X_cat['test'], y['test'] = lib.read_pure_data(real_data_path, 'test') + + + X = {k: X_num[k] for k in X_num.keys()} + + if is_regression: + X['train'] = np.concatenate([X["train"], y["train"].reshape(-1, 1)], axis=1, dtype=object) + y['train'] = np.where(y["train"] > np.median(y["train"]), 1, 0) + + n_num_features = X['train'].shape[1] + n_cat_features = X_cat['train'].shape[1] if X_cat['train'] is not None else 0 + cat_features = list(range(n_num_features, n_num_features+n_cat_features)) + print(cat_features) + + scaler = MinMaxScaler().fit(X["train"]) + X["train"] = scaler.transform(X["train"]).astype(object) + + if X_cat['train'] is not None: + for k in X_num.keys(): + X[k] = np.concatenate([X[k], X_cat[k]], axis=1, dtype=object) + + print("Before:", X['train'].shape) + + if eval_type != 'real': + strat = {k: int((1 + frac_samples) * np.sum(y['train'] == k)) for k in np.unique(y['train'])} + print(strat) + if n_cat_features > 0: + sm = MySMOTENC( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + categorical_features=cat_features, + sampling_strategy=strat + ) + else: + sm = MySMOTE( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + sampling_strategy=strat + ) + + X_res, y_res = sm.fit_resample(X['train'], y['train']) + if is_regression: + X_res[:, :X_num["train"].shape[1]+1] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]+1]) + y_res = X_res[:, X_num["train"].shape[1]] + X_res = np.delete(X_res, [X_num["train"].shape[1]], axis=1) + else: + X_res[:, :X_num["train"].shape[1]] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]]) + y_res = y_res.astype(int) + + if eval_type == "synthetic": + X_res = X_res[X['train'].shape[0]:] + y_res = y_res[X['train'].shape[0]:] + + disc_cols = [] + for col in range(X_num["train"].shape[1]): + uniq_vals = np.unique(X_num["train"][:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + if len(disc_cols): + X_res[:, :X_num["train"].shape[1]] = lib.round_columns(X_num["train"], X_res[:, :X_num["train"].shape[1]], disc_cols) + + if save: + save_data(X_res, y_res, Path(parent_dir), n_cat_features) + + X['train'] = X_res + y['train'] = y_res + + return X, y + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('data_path', type=str) + parser.add_argument('method', type=str) + + args = parser.parse_args() + + sample_smote(args.data_path, args.method, save=False) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/tune_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/tune_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..9c98e205150bd02fee9ce399280714101bd427c3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/smote/tune_smote.py @@ -0,0 +1,98 @@ +import optuna +import lib +from copy import deepcopy +import argparse +import tempfile +from pathlib import Path +import os +from scripts.eval_catboost import train_catboost +from sample_smote import sample_smote +import subprocess + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('eval_type', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type + +def objective(trial): + + k_neighbours = trial.suggest_int("k_neighbours", 5, 20) + frac_samples = 2 ** trial.suggest_int('frac_samples', -2, 3) + + # z = \lam*x + (1 - \lam)*y, \lam ~ U[frac_lam_del/2, 1-frac_lam_del/2] + frac_lam_del = trial.suggest_float("frac_lam_del", 0.0, 0.95, step=0.05) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + for seed in range(5): + sample_smote( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + frac_samples=frac_samples, + frac_lam_del=frac_lam_del, + k_neighbours=k_neighbours, + change_val=True, + seed=seed + ) + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + + return score / 5 + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=5, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/smote/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/smote/", + "real_data_path": real_data_path, + "seed": 0, + "smote_params": {}, + "sample": {"seed": 0}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +config["smote_params"] = study.best_params +config["smote_params"]["frac_samples"] = 2 ** config["smote_params"]["frac_samples"] + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "smote", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8ad340c806b61da5a372186d04f2e7ab88a74daa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/__init__.py @@ -0,0 +1,2 @@ +from .gaussian_multinomial_diffsuion import * # noqa +from .modules import * # noqa \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py new file mode 100644 index 0000000000000000000000000000000000000000..5e3cb1c3086b2fa5862552e91e648677bb673dd9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py @@ -0,0 +1,993 @@ +""" +Based on https://github.com/openai/guided-diffusion/blob/main/guided_diffusion +and https://github.com/ehoogeboom/multinomial_diffusion +""" + +import torch.nn.functional as F +import torch +import math + +import numpy as np +from .utils import * + +""" +Based in part on: https://github.com/lucidrains/denoising-diffusion-pytorch/blob/5989f4c77eafcdc6be0fb4739f0f277a6dd7f7d8/denoising_diffusion_pytorch/denoising_diffusion_pytorch.py#L281 +""" +eps = 1e-8 + +def get_named_beta_schedule(schedule_name, num_diffusion_timesteps): + """ + Get a pre-defined beta schedule for the given name. + The beta schedule library consists of beta schedules which remain similar + in the limit of num_diffusion_timesteps. + Beta schedules may be added, but should not be removed or changed once + they are committed to maintain backwards compatibility. + """ + if schedule_name == "linear": + # Linear schedule from Ho et al, extended to work for any number of + # diffusion steps. + scale = 1000 / num_diffusion_timesteps + beta_start = scale * 0.0001 + beta_end = scale * 0.02 + return np.linspace( + beta_start, beta_end, num_diffusion_timesteps, dtype=np.float64 + ) + elif schedule_name == "cosine": + return betas_for_alpha_bar( + num_diffusion_timesteps, + lambda t: math.cos((t + 0.008) / 1.008 * math.pi / 2) ** 2, + ) + else: + raise NotImplementedError(f"unknown beta schedule: {schedule_name}") + + +def betas_for_alpha_bar(num_diffusion_timesteps, alpha_bar, max_beta=0.999): + """ + Create a beta schedule that discretizes the given alpha_t_bar function, + which defines the cumulative product of (1-beta) over time from t = [0,1]. + :param num_diffusion_timesteps: the number of betas to produce. + :param alpha_bar: a lambda that takes an argument t from 0 to 1 and + produces the cumulative product of (1-beta) up to that + part of the diffusion process. + :param max_beta: the maximum beta to use; use values lower than 1 to + prevent singularities. + """ + betas = [] + for i in range(num_diffusion_timesteps): + t1 = i / num_diffusion_timesteps + t2 = (i + 1) / num_diffusion_timesteps + betas.append(min(1 - alpha_bar(t2) / alpha_bar(t1), max_beta)) + return np.array(betas) + +class GaussianMultinomialDiffusion(torch.nn.Module): + def __init__( + self, + num_classes: np.array, + num_numerical_features: int, + denoise_fn, + num_timesteps=1000, + gaussian_loss_type='mse', + gaussian_parametrization='eps', + multinomial_loss_type='vb_stochastic', + parametrization='x0', + scheduler='cosine', + device=torch.device('cpu') + ): + + super(GaussianMultinomialDiffusion, self).__init__() + assert multinomial_loss_type in ('vb_stochastic', 'vb_all') + assert parametrization in ('x0', 'direct') + + if multinomial_loss_type == 'vb_all': + print('Computing the loss using the bound on _all_ timesteps.' + ' This is expensive both in terms of memory and computation.') + + self.num_numerical_features = num_numerical_features + self.num_classes = num_classes # it as a vector [K1, K2, ..., Km] + self.num_classes_expanded = torch.from_numpy( + np.concatenate([num_classes[i].repeat(num_classes[i]) for i in range(len(num_classes))]) + ).to(device) + + self.slices_for_classes = [np.arange(self.num_classes[0])] + offsets = np.cumsum(self.num_classes) + for i in range(1, len(offsets)): + self.slices_for_classes.append(np.arange(offsets[i - 1], offsets[i])) + self.offsets = torch.from_numpy(np.append([0], offsets)).to(device) + + self._denoise_fn = denoise_fn + self.gaussian_loss_type = gaussian_loss_type + self.gaussian_parametrization = gaussian_parametrization + self.multinomial_loss_type = multinomial_loss_type + self.num_timesteps = num_timesteps + self.parametrization = parametrization + self.scheduler = scheduler + + alphas = 1. - get_named_beta_schedule(scheduler, num_timesteps) + alphas = torch.tensor(alphas.astype('float64')) + betas = 1. - alphas + + log_alpha = np.log(alphas) + log_cumprod_alpha = np.cumsum(log_alpha) + + log_1_min_alpha = log_1_min_a(log_alpha) + log_1_min_cumprod_alpha = log_1_min_a(log_cumprod_alpha) + + alphas_cumprod = np.cumprod(alphas, axis=0) + alphas_cumprod_prev = torch.tensor(np.append(1.0, alphas_cumprod[:-1])) + alphas_cumprod_next = torch.tensor(np.append(alphas_cumprod[1:], 0.0)) + sqrt_alphas_cumprod = np.sqrt(alphas_cumprod) + sqrt_one_minus_alphas_cumprod = np.sqrt(1.0 - alphas_cumprod) + sqrt_recip_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod) + sqrt_recipm1_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod - 1) + + # Gaussian diffusion + + self.posterior_variance = ( + betas * (1.0 - alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ) + self.posterior_log_variance_clipped = torch.from_numpy( + np.log(np.append(self.posterior_variance[1], self.posterior_variance[1:])) + ).float().to(device) + self.posterior_mean_coef1 = ( + betas * np.sqrt(alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ).float().to(device) + self.posterior_mean_coef2 = ( + (1.0 - alphas_cumprod_prev) + * np.sqrt(alphas.numpy()) + / (1.0 - alphas_cumprod) + ).float().to(device) + + assert log_add_exp(log_alpha, log_1_min_alpha).abs().sum().item() < 1.e-5 + assert log_add_exp(log_cumprod_alpha, log_1_min_cumprod_alpha).abs().sum().item() < 1e-5 + assert (np.cumsum(log_alpha) - log_cumprod_alpha).abs().sum().item() < 1.e-5 + + # Convert to float32 and register buffers. + self.register_buffer('alphas', alphas.float().to(device)) + self.register_buffer('log_alpha', log_alpha.float().to(device)) + self.register_buffer('log_1_min_alpha', log_1_min_alpha.float().to(device)) + self.register_buffer('log_1_min_cumprod_alpha', log_1_min_cumprod_alpha.float().to(device)) + self.register_buffer('log_cumprod_alpha', log_cumprod_alpha.float().to(device)) + self.register_buffer('alphas_cumprod', alphas_cumprod.float().to(device)) + self.register_buffer('alphas_cumprod_prev', alphas_cumprod_prev.float().to(device)) + self.register_buffer('alphas_cumprod_next', alphas_cumprod_next.float().to(device)) + self.register_buffer('sqrt_alphas_cumprod', sqrt_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_one_minus_alphas_cumprod', sqrt_one_minus_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recip_alphas_cumprod', sqrt_recip_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recipm1_alphas_cumprod', sqrt_recipm1_alphas_cumprod.float().to(device)) + + self.register_buffer('Lt_history', torch.zeros(num_timesteps)) + self.register_buffer('Lt_count', torch.zeros(num_timesteps)) + + # Gaussian part + def gaussian_q_mean_variance(self, x_start, t): + mean = ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + ) + variance = extract(1.0 - self.alphas_cumprod, t, x_start.shape) + log_variance = extract( + self.log_1_min_cumprod_alpha, t, x_start.shape + ) + return mean, variance, log_variance + + def gaussian_q_sample(self, x_start, t, noise=None): + if noise is None: + noise = torch.randn_like(x_start) + assert noise.shape == x_start.shape + return ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + + extract(self.sqrt_one_minus_alphas_cumprod, t, x_start.shape) + * noise + ) + + def gaussian_q_posterior_mean_variance(self, x_start, x_t, t): + assert x_start.shape == x_t.shape + posterior_mean = ( + extract(self.posterior_mean_coef1, t, x_t.shape) * x_start + + extract(self.posterior_mean_coef2, t, x_t.shape) * x_t + ) + posterior_variance = extract(self.posterior_variance, t, x_t.shape) + posterior_log_variance_clipped = extract( + self.posterior_log_variance_clipped, t, x_t.shape + ) + assert ( + posterior_mean.shape[0] + == posterior_variance.shape[0] + == posterior_log_variance_clipped.shape[0] + == x_start.shape[0] + ) + return posterior_mean, posterior_variance, posterior_log_variance_clipped + + def gaussian_p_mean_variance( + self, model_output, x, t, clip_denoised=False, denoised_fn=None, model_kwargs=None + ): + if model_kwargs is None: + model_kwargs = {} + + B, C = x.shape[:2] + assert t.shape == (B,) + + model_variance = torch.cat([self.posterior_variance[1].unsqueeze(0).to(x.device), (1. - self.alphas)[1:]], dim=0) + # model_variance = self.posterior_variance.to(x.device) + model_log_variance = torch.log(model_variance) + + model_variance = extract(model_variance, t, x.shape) + model_log_variance = extract(model_log_variance, t, x.shape) + + + if self.gaussian_parametrization == 'eps': + pred_xstart = self._predict_xstart_from_eps(x_t=x, t=t, eps=model_output) + elif self.gaussian_parametrization == 'x0': + pred_xstart = model_output + else: + raise NotImplementedError + + model_mean, _, _ = self.gaussian_q_posterior_mean_variance( + x_start=pred_xstart, x_t=x, t=t + ) + + assert ( + model_mean.shape == model_log_variance.shape == pred_xstart.shape == x.shape + ), f'{model_mean.shape}, {model_log_variance.shape}, {pred_xstart.shape}, {x.shape}' + + return { + "mean": model_mean, + "variance": model_variance, + "log_variance": model_log_variance, + "pred_xstart": pred_xstart, + } + + def _vb_terms_bpd( + self, model_output, x_start, x_t, t, clip_denoised=False, model_kwargs=None + ): + true_mean, _, true_log_variance_clipped = self.gaussian_q_posterior_mean_variance( + x_start=x_start, x_t=x_t, t=t + ) + out = self.gaussian_p_mean_variance( + model_output, x_t, t, clip_denoised=clip_denoised, model_kwargs=model_kwargs + ) + kl = normal_kl( + true_mean, true_log_variance_clipped, out["mean"], out["log_variance"] + ) + kl = mean_flat(kl) / np.log(2.0) + + decoder_nll = -discretized_gaussian_log_likelihood( + x_start, means=out["mean"], log_scales=0.5 * out["log_variance"] + ) + assert decoder_nll.shape == x_start.shape + decoder_nll = mean_flat(decoder_nll) / np.log(2.0) + + # At the first timestep return the decoder NLL, + # otherwise return KL(q(x_{t-1}|x_t,x_0) || p(x_{t-1}|x_t)) + output = torch.where((t == 0), decoder_nll, kl) + return {"output": output, "pred_xstart": out["pred_xstart"], "out_mean": out["mean"], "true_mean": true_mean} + + def _prior_gaussian(self, x_start): + """ + Get the prior KL term for the variational lower-bound, measured in + bits-per-dim. + + This term can't be optimized, as it only depends on the encoder. + + :param x_start: the [N x C x ...] tensor of inputs. + :return: a batch of [N] KL values (in bits), one per batch element. + """ + batch_size = x_start.shape[0] + t = torch.tensor([self.num_timesteps - 1] * batch_size, device=x_start.device) + qt_mean, _, qt_log_variance = self.gaussian_q_mean_variance(x_start, t) + kl_prior = normal_kl( + mean1=qt_mean, logvar1=qt_log_variance, mean2=0.0, logvar2=0.0 + ) + return mean_flat(kl_prior) / np.log(2.0) + + def _gaussian_loss(self, model_out, x_start, x_t, t, noise, model_kwargs=None): + if model_kwargs is None: + model_kwargs = {} + + terms = {} + if self.gaussian_loss_type == 'mse': + terms["loss"] = mean_flat((noise - model_out) ** 2) + elif self.gaussian_loss_type == 'kl': + terms["loss"] = self._vb_terms_bpd( + model_output=model_out, + x_start=x_start, + x_t=x_t, + t=t, + clip_denoised=False, + model_kwargs=model_kwargs, + )["output"] + + + return terms['loss'] + + def _predict_xstart_from_eps(self, x_t, t, eps): + assert x_t.shape == eps.shape + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) * eps + ) + + def _predict_eps_from_xstart(self, x_t, t, pred_xstart): + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - pred_xstart + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) + + def gaussian_p_sample( + self, + model_out, + x, + t, + clip_denoised=False, + denoised_fn=None, + model_kwargs=None, + ): + out = self.gaussian_p_mean_variance( + model_out, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=model_kwargs, + ) + noise = torch.randn_like(x) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + + sample = out["mean"] + nonzero_mask * torch.exp(0.5 * out["log_variance"]) * noise + return {"sample": sample, "pred_xstart": out["pred_xstart"]} + + # Multinomial part + + def multinomial_kl(self, log_prob1, log_prob2): + kl = (log_prob1.exp() * (log_prob1 - log_prob2)).sum(dim=1) + return kl + + def q_pred_one_timestep(self, log_x_t, t): + log_alpha_t = extract(self.log_alpha, t, log_x_t.shape) + log_1_min_alpha_t = extract(self.log_1_min_alpha, t, log_x_t.shape) + + # alpha_t * E[xt] + (1 - alpha_t) 1 / K + log_probs = log_add_exp( + log_x_t + log_alpha_t, + log_1_min_alpha_t - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def q_pred(self, log_x_start, t): + log_cumprod_alpha_t = extract(self.log_cumprod_alpha, t, log_x_start.shape) + log_1_min_cumprod_alpha = extract(self.log_1_min_cumprod_alpha, t, log_x_start.shape) + + log_probs = log_add_exp( + log_x_start + log_cumprod_alpha_t, + log_1_min_cumprod_alpha - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def predict_start(self, model_out, log_x_t, t, out_dict): + + # model_out = self._denoise_fn(x_t, t.to(x_t.device), **out_dict) + + assert model_out.size(0) == log_x_t.size(0) + assert model_out.size(1) == self.num_classes.sum(), f'{model_out.size()}' + + log_pred = torch.empty_like(model_out) + for ix in self.slices_for_classes: + log_pred[:, ix] = F.log_softmax(model_out[:, ix], dim=1) + return log_pred + + def q_posterior(self, log_x_start, log_x_t, t): + # q(xt-1 | xt, x0) = q(xt | xt-1, x0) * q(xt-1 | x0) / q(xt | x0) + # where q(xt | xt-1, x0) = q(xt | xt-1). + + # EV_log_qxt_x0 = self.q_pred(log_x_start, t) + + # print('sum exp', EV_log_qxt_x0.exp().sum(1).mean()) + # assert False + + # log_qxt_x0 = (log_x_t.exp() * EV_log_qxt_x0).sum(dim=1) + t_minus_1 = t - 1 + # Remove negative values, will not be used anyway for final decoder + t_minus_1 = torch.where(t_minus_1 < 0, torch.zeros_like(t_minus_1), t_minus_1) + log_EV_qxtmin_x0 = self.q_pred(log_x_start, t_minus_1) + + num_axes = (1,) * (len(log_x_start.size()) - 1) + t_broadcast = t.to(log_x_start.device).view(-1, *num_axes) * torch.ones_like(log_x_start) + log_EV_qxtmin_x0 = torch.where(t_broadcast == 0, log_x_start, log_EV_qxtmin_x0.to(torch.float32)) + + # unnormed_logprobs = log_EV_qxtmin_x0 + + # log q_pred_one_timestep(x_t, t) + # Note: _NOT_ x_tmin1, which is how the formula is typically used!!! + # Not very easy to see why this is true. But it is :) + unnormed_logprobs = log_EV_qxtmin_x0 + self.q_pred_one_timestep(log_x_t, t) + + log_EV_xtmin_given_xt_given_xstart = \ + unnormed_logprobs \ + - sliced_logsumexp(unnormed_logprobs, self.offsets) + + return log_EV_xtmin_given_xt_given_xstart + + def p_pred(self, model_out, log_x, t, out_dict): + if self.parametrization == 'x0': + log_x_recon = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + log_model_pred = self.q_posterior( + log_x_start=log_x_recon, log_x_t=log_x, t=t) + elif self.parametrization == 'direct': + log_model_pred = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + else: + raise ValueError + return log_model_pred + + @torch.no_grad() + def p_sample(self, model_out, log_x, t, out_dict): + model_log_prob = self.p_pred(model_out, log_x=log_x, t=t, out_dict=out_dict) + out = self.log_sample_categorical(model_log_prob) + return out + + @torch.no_grad() + def p_sample_loop(self, shape, out_dict): + device = self.log_alpha.device + + b = shape[0] + # start with random normal image. + img = torch.randn(shape, device=device) + + for i in reversed(range(1, self.num_timesteps)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long), out_dict) + return img + + @torch.no_grad() + def _sample(self, image_size, out_dict, batch_size = 16): + return self.p_sample_loop((batch_size, 3, image_size, image_size), out_dict) + + @torch.no_grad() + def interpolate(self, x1, x2, t = None, lam = 0.5): + b, *_, device = *x1.shape, x1.device + t = default(t, self.num_timesteps - 1) + + assert x1.shape == x2.shape + + t_batched = torch.stack([torch.tensor(t, device=device)] * b) + xt1, xt2 = map(lambda x: self.q_sample(x, t=t_batched), (x1, x2)) + + img = (1 - lam) * xt1 + lam * xt2 + for i in reversed(range(0, t)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long)) + + return img + + def log_sample_categorical(self, logits): + full_sample = [] + for i in range(len(self.num_classes)): + one_class_logits = logits[:, self.slices_for_classes[i]] + uniform = torch.rand_like(one_class_logits) + gumbel_noise = -torch.log(-torch.log(uniform + 1e-30) + 1e-30) + sample = (gumbel_noise + one_class_logits).argmax(dim=1) + full_sample.append(sample.unsqueeze(1)) + full_sample = torch.cat(full_sample, dim=1) + log_sample = index_to_log_onehot(full_sample, self.num_classes) + return log_sample + + def q_sample(self, log_x_start, t): + log_EV_qxt_x0 = self.q_pred(log_x_start, t) + + log_sample = self.log_sample_categorical(log_EV_qxt_x0) + + return log_sample + + def nll(self, log_x_start, out_dict): + b = log_x_start.size(0) + device = log_x_start.device + loss = 0 + for t in range(0, self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + + kl = self.compute_Lt( + log_x_start=log_x_start, + log_x_t=self.q_sample(log_x_start=log_x_start, t=t_array), + t=t_array, + out_dict=out_dict) + + loss += kl + + loss += self.kl_prior(log_x_start) + + return loss + + def kl_prior(self, log_x_start): + b = log_x_start.size(0) + device = log_x_start.device + ones = torch.ones(b, device=device).long() + + log_qxT_prob = self.q_pred(log_x_start, t=(self.num_timesteps - 1) * ones) + log_half_prob = -torch.log(self.num_classes_expanded * torch.ones_like(log_qxT_prob)) + + kl_prior = self.multinomial_kl(log_qxT_prob, log_half_prob) + return sum_except_batch(kl_prior) + + def compute_Lt(self, model_out, log_x_start, log_x_t, t, out_dict, detach_mean=False): + log_true_prob = self.q_posterior( + log_x_start=log_x_start, log_x_t=log_x_t, t=t) + log_model_prob = self.p_pred(model_out, log_x=log_x_t, t=t, out_dict=out_dict) + + if detach_mean: + log_model_prob = log_model_prob.detach() + + kl = self.multinomial_kl(log_true_prob, log_model_prob) + kl = sum_except_batch(kl) + + decoder_nll = -log_categorical(log_x_start, log_model_prob) + decoder_nll = sum_except_batch(decoder_nll) + + mask = (t == torch.zeros_like(t)).float() + loss = mask * decoder_nll + (1. - mask) * kl + + return loss + + def sample_time(self, b, device, method='uniform'): + if method == 'importance': + if not (self.Lt_count > 10).all(): + return self.sample_time(b, device, method='uniform') + + Lt_sqrt = torch.sqrt(self.Lt_history + 1e-10) + 0.0001 + Lt_sqrt[0] = Lt_sqrt[1] # Overwrite decoder term with L1. + pt_all = (Lt_sqrt / Lt_sqrt.sum()).to(device) + + t = torch.multinomial(pt_all, num_samples=b, replacement=True).to(device) + + pt = pt_all.gather(dim=0, index=t) + + return t, pt + + elif method == 'uniform': + t = torch.randint(0, self.num_timesteps, (b,), device=device).long() + + pt = torch.ones_like(t).float() / self.num_timesteps + return t, pt + else: + raise ValueError + + def _multinomial_loss(self, model_out, log_x_start, log_x_t, t, pt, out_dict): + + if self.multinomial_loss_type == 'vb_stochastic': + kl = self.compute_Lt( + model_out, log_x_start, log_x_t, t, out_dict + ) + kl_prior = self.kl_prior(log_x_start) + # Upweigh loss term of the kl + vb_loss = kl / pt + kl_prior + + return vb_loss + + elif self.multinomial_loss_type == 'vb_all': + # Expensive, dont do it ;). + # DEPRECATED + return -self.nll(log_x_start) + else: + raise ValueError() + + def log_prob(self, x, out_dict): + b, device = x.size(0), x.device + if self.training: + return self._multinomial_loss(x, out_dict) + + else: + log_x_start = index_to_log_onehot(x, self.num_classes) + + t, pt = self.sample_time(b, device, 'importance') + + kl = self.compute_Lt( + log_x_start, self.q_sample(log_x_start=log_x_start, t=t), t, out_dict) + + kl_prior = self.kl_prior(log_x_start) + + # Upweigh loss term of the kl + loss = kl / pt + kl_prior + + return -loss + + def mixed_loss(self, x, out_dict): + b = x.shape[0] + device = x.device + t, pt = self.sample_time(b, device, 'uniform') + + x_num = x[:, :self.num_numerical_features] + x_cat = x[:, self.num_numerical_features:] + + x_num_t = x_num + log_x_cat_t = x_cat + if x_num.shape[1] > 0: + noise = torch.randn_like(x_num) + x_num_t = self.gaussian_q_sample(x_num, t, noise=noise) + if x_cat.shape[1] > 0: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes) + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t) + + x_in = torch.cat([x_num_t, log_x_cat_t], dim=1) + + model_out = self._denoise_fn( + x_in, + t, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + loss_multi = torch.zeros((1,)).float() + loss_gauss = torch.zeros((1,)).float() + if x_cat.shape[1] > 0: + loss_multi = self._multinomial_loss(model_out_cat, log_x_cat, log_x_cat_t, t, pt, out_dict) / len(self.num_classes) + + if x_num.shape[1] > 0: + loss_gauss = self._gaussian_loss(model_out_num, x_num, x_num_t, t, noise) + + # loss_multi = torch.where(out_dict['y'] == 1, loss_multi, 2 * loss_multi) + # loss_gauss = torch.where(out_dict['y'] == 1, loss_gauss, 2 * loss_gauss) + + return loss_multi.mean(), loss_gauss.mean() + + @torch.no_grad() + def mixed_elbo(self, x0, out_dict): + b = x0.size(0) + device = x0.device + + x_num = x0[:, :self.num_numerical_features] + x_cat = x0[:, self.num_numerical_features:] + has_cat = x_cat.shape[1] > 0 + if has_cat: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes).to(device) + + gaussian_loss = [] + xstart_mse = [] + mse = [] + mu_mse = [] + out_mean = [] + true_mean = [] + multinomial_loss = [] + for t in range(self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + noise = torch.randn_like(x_num) + + x_num_t = self.gaussian_q_sample(x_start=x_num, t=t_array, noise=noise) + if has_cat: + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t_array) + else: + log_x_cat_t = x_cat + + model_out = self._denoise_fn( + torch.cat([x_num_t, log_x_cat_t], dim=1), + t_array, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + kl = torch.tensor([0.0]) + if has_cat: + kl = self.compute_Lt( + model_out=model_out_cat, + log_x_start=log_x_cat, + log_x_t=log_x_cat_t, + t=t_array, + out_dict=out_dict + ) + + out = self._vb_terms_bpd( + model_out_num, + x_start=x_num, + x_t=x_num_t, + t=t_array, + clip_denoised=False + ) + + multinomial_loss.append(kl) + gaussian_loss.append(out["output"]) + xstart_mse.append(mean_flat((out["pred_xstart"] - x_num) ** 2)) + # mu_mse.append(mean_flat(out["mean_mse"])) + out_mean.append(mean_flat(out["out_mean"])) + true_mean.append(mean_flat(out["true_mean"])) + + eps = self._predict_eps_from_xstart(x_num_t, t_array, out["pred_xstart"]) + mse.append(mean_flat((eps - noise) ** 2)) + + gaussian_loss = torch.stack(gaussian_loss, dim=1) + multinomial_loss = torch.stack(multinomial_loss, dim=1) + xstart_mse = torch.stack(xstart_mse, dim=1) + mse = torch.stack(mse, dim=1) + # mu_mse = torch.stack(mu_mse, dim=1) + out_mean = torch.stack(out_mean, dim=1) + true_mean = torch.stack(true_mean, dim=1) + + + + prior_gauss = self._prior_gaussian(x_num) + + prior_multin = torch.tensor([0.0]) + if has_cat: + prior_multin = self.kl_prior(log_x_cat) + + total_gauss = gaussian_loss.sum(dim=1) + prior_gauss + total_multin = multinomial_loss.sum(dim=1) + prior_multin + return { + "total_gaussian": total_gauss, + "total_multinomial": total_multin, + "losses_gaussian": gaussian_loss, + "losses_multinimial": multinomial_loss, + "xstart_mse": xstart_mse, + "mse": mse, + # "mu_mse": mu_mse + "out_mean": out_mean, + "true_mean": true_mean + } + + @torch.no_grad() + def gaussian_ddim_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + denoised_fn=None, + eta=0.0 + ): + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=None, + ) + + eps = self._predict_eps_from_xstart(x, t, out["pred_xstart"]) + + alpha_bar = extract(self.alphas_cumprod, t, x.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, x.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + noise = torch.randn_like(x) + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_prev) + + torch.sqrt(1 - alpha_bar_prev - sigma ** 2) * eps + ) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + sample = mean_pred + nonzero_mask * sigma * noise + + return sample + + @torch.no_grad() + def gaussian_ddim_sample( + self, + noise, + T, + out_dict, + eta=0.0 + ): + x = noise + b = x.shape[0] + device = x.device + for t in reversed(range(T)): + print(f'Sample timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_step( + out_num, + x, + t_array + ) + print() + return x + + + @torch.no_grad() + def gaussian_ddim_reverse_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + eta=0.0 + ): + assert eta == 0.0, "Eta must be zero." + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=None, + model_kwargs=None, + ) + + eps = ( + extract(self.sqrt_recip_alphas_cumprod, t, x.shape) * x + - out["pred_xstart"] + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x.shape) + alpha_bar_next = extract(self.alphas_cumprod_next, t, x.shape) + + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_next) + + torch.sqrt(1 - alpha_bar_next) * eps + ) + + return mean_pred + + @torch.no_grad() + def gaussian_ddim_reverse_sample( + self, + x, + T, + out_dict, + ): + b = x.shape[0] + device = x.device + for t in range(T): + print(f'Reverse timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_reverse_step( + out_num, + x, + t_array, + eta=0.0 + ) + print() + + return x + + + @torch.no_grad() + def multinomial_ddim_step( + self, + model_out_cat, + log_x_t, + t, + out_dict, + eta=0.0 + ): + # not ddim, essentially + log_x0 = self.predict_start(model_out_cat, log_x_t=log_x_t, t=t, out_dict=out_dict) + + alpha_bar = extract(self.alphas_cumprod, t, log_x_t.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, log_x_t.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + coef1 = sigma + coef2 = alpha_bar_prev - sigma * alpha_bar + coef3 = 1 - coef1 - coef2 + + + log_ps = torch.stack([ + torch.log(coef1) + log_x_t, + torch.log(coef2) + log_x0, + torch.log(coef3) - torch.log(self.num_classes_expanded) + ], dim=2) + + log_prob = torch.logsumexp(log_ps, dim=2) + + out = self.log_sample_categorical(log_prob) + + return out + + @torch.no_grad() + def sample_ddim(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_ddim_step(model_out_num, z_norm, t, clip_denoised=False) + if has_cat: + log_z = self.multinomial_ddim_step(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + + @torch.no_grad() + def sample(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_p_sample(model_out_num, z_norm, t, clip_denoised=False)['sample'] + if has_cat: + log_z = self.p_sample(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + def sample_all(self, num_samples, batch_size, y_dist, ddim=False): + if ddim: + print('Sample using DDIM.') + sample_fn = self.sample_ddim + else: + sample_fn = self.sample + + b = batch_size + + all_y = [] + all_samples = [] + num_generated = 0 + while num_generated < num_samples: + sample, out_dict = sample_fn(b, y_dist) + mask_nan = torch.any(sample.isnan(), dim=1) + sample = sample[~mask_nan] + out_dict['y'] = out_dict['y'][~mask_nan] + + all_samples.append(sample) + all_y.append(out_dict['y'].cpu()) + if sample.shape[0] != b: + raise FoundNANsError + num_generated += sample.shape[0] + + x_gen = torch.cat(all_samples, dim=0)[:num_samples] + y_gen = torch.cat(all_y, dim=0)[:num_samples] + + return x_gen, y_gen \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/modules.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/modules.py new file mode 100644 index 0000000000000000000000000000000000000000..472ba5b5f44b646e83d429f0d6272a8fe6d7130d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/modules.py @@ -0,0 +1,486 @@ +""" +Code was adapted from https://github.com/Yura52/rtdl +""" + +import math +from typing import Any, Callable, Dict, List, Optional, Tuple, Type, Union, cast + +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim +from torch import Tensor + +ModuleType = Union[str, Callable[..., nn.Module]] + +class SiLU(nn.Module): + def forward(self, x): + return x * torch.sigmoid(x) + +def timestep_embedding(timesteps, dim, max_period=10000): + """ + Create sinusoidal timestep embeddings. + + :param timesteps: a 1-D Tensor of N indices, one per batch element. + These may be fractional. + :param dim: the dimension of the output. + :param max_period: controls the minimum frequency of the embeddings. + :return: an [N x dim] Tensor of positional embeddings. + """ + half = dim // 2 + freqs = torch.exp( + -math.log(max_period) * torch.arange(start=0, end=half, dtype=torch.float32) / half + ).to(device=timesteps.device) + args = timesteps[:, None].float() * freqs[None] + embedding = torch.cat([torch.cos(args), torch.sin(args)], dim=-1) + if dim % 2: + embedding = torch.cat([embedding, torch.zeros_like(embedding[:, :1])], dim=-1) + return embedding + +def _is_glu_activation(activation: ModuleType): + return ( + isinstance(activation, str) + and activation.endswith('GLU') + or activation in [ReGLU, GEGLU] + ) + + +def _all_or_none(values): + assert all(x is None for x in values) or all(x is not None for x in values) + +def reglu(x: Tensor) -> Tensor: + """The ReGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.relu(b) + + +def geglu(x: Tensor) -> Tensor: + """The GEGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.gelu(b) + +class ReGLU(nn.Module): + """The ReGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = ReGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return reglu(x) + + +class GEGLU(nn.Module): + """The GEGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = GEGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return geglu(x) + +def _make_nn_module(module_type: ModuleType, *args) -> nn.Module: + return ( + ( + ReGLU() + if module_type == 'ReGLU' + else GEGLU() + if module_type == 'GEGLU' + else getattr(nn, module_type)(*args) + ) + if isinstance(module_type, str) + else module_type(*args) + ) + + +class MLP(nn.Module): + """The MLP model used in [gorishniy2021revisiting]. + + The following scheme describes the architecture: + + .. code-block:: text + + MLP: (in) -> Block -> ... -> Block -> Linear -> (out) + Block: (in) -> Linear -> Activation -> Dropout -> (out) + + Examples: + .. testcode:: + + x = torch.randn(4, 2) + module = MLP.make_baseline(x.shape[1], [3, 5], 0.1, 1) + assert module(x).shape == (len(x), 1) + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `MLP`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + activation: ModuleType, + dropout: float, + ) -> None: + super().__init__() + self.linear = nn.Linear(d_in, d_out, bias) + self.activation = _make_nn_module(activation) + self.dropout = nn.Dropout(dropout) + + def forward(self, x: Tensor) -> Tensor: + return self.dropout(self.activation(self.linear(x))) + + def __init__( + self, + *, + d_in: int, + d_layers: List[int], + dropouts: Union[float, List[float]], + activation: Union[str, Callable[[], nn.Module]], + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + if isinstance(dropouts, float): + dropouts = [dropouts] * len(d_layers) + assert len(d_layers) == len(dropouts) + assert activation not in ['ReGLU', 'GEGLU'] + + self.blocks = nn.ModuleList( + [ + MLP.Block( + d_in=d_layers[i - 1] if i else d_in, + d_out=d, + bias=True, + activation=activation, + dropout=dropout, + ) + for i, (d, dropout) in enumerate(zip(d_layers, dropouts)) + ] + ) + self.head = nn.Linear(d_layers[-1] if d_layers else d_in, d_out) + + @classmethod + def make_baseline( + cls: Type['MLP'], + d_in: int, + d_layers: List[int], + dropout: float, + d_out: int, + ) -> 'MLP': + """Create a "baseline" `MLP`. + + This variation of MLP was used in [gorishniy2021revisiting]. Features: + + * :code:`Activation` = :code:`ReLU` + * all linear layers except for the first one and the last one are of the same dimension + * the dropout rate is the same for all dropout layers + + Args: + d_in: the input size + d_layers: the dimensions of the linear layers. If there are more than two + layers, then all of them except for the first and the last ones must + have the same dimension. Valid examples: :code:`[]`, :code:`[8]`, + :code:`[8, 16]`, :code:`[2, 2, 2, 2]`, :code:`[1, 2, 2, 4]`. Invalid + example: :code:`[1, 2, 3, 4]`. + dropout: the dropout rate for all hidden layers + d_out: the output size + Returns: + MLP + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + assert isinstance(dropout, float) + if len(d_layers) > 2: + assert len(set(d_layers[1:-1])) == 1, ( + 'if d_layers contains more than two elements, then' + ' all elements except for the first and the last ones must be equal.' + ) + return MLP( + d_in=d_in, + d_layers=d_layers, # type: ignore + dropouts=dropout, + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + for block in self.blocks: + x = block(x) + x = self.head(x) + return x + + +class ResNet(nn.Module): + """The ResNet model used in [gorishniy2021revisiting]. + The following scheme describes the architecture: + .. code-block:: text + ResNet: (in) -> Linear -> Block -> ... -> Block -> Head -> (out) + |-> Norm -> Linear -> Activation -> Dropout -> Linear -> Dropout ->| + | | + Block: (in) ------------------------------------------------------------> Add -> (out) + Head: (in) -> Norm -> Activation -> Linear -> (out) + Examples: + .. testcode:: + x = torch.randn(4, 2) + module = ResNet.make_baseline( + d_in=x.shape[1], + n_blocks=2, + d_main=3, + d_hidden=4, + dropout_first=0.25, + dropout_second=0.0, + d_out=1 + ) + assert module(x).shape == (len(x), 1) + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `ResNet`.""" + + def __init__( + self, + *, + d_main: int, + d_hidden: int, + bias_first: bool, + bias_second: bool, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + skip_connection: bool, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_main) + self.linear_first = nn.Linear(d_main, d_hidden, bias_first) + self.activation = _make_nn_module(activation) + self.dropout_first = nn.Dropout(dropout_first) + self.linear_second = nn.Linear(d_hidden, d_main, bias_second) + self.dropout_second = nn.Dropout(dropout_second) + self.skip_connection = skip_connection + + def forward(self, x: Tensor) -> Tensor: + x_input = x + x = self.normalization(x) + x = self.linear_first(x) + x = self.activation(x) + x = self.dropout_first(x) + x = self.linear_second(x) + x = self.dropout_second(x) + if self.skip_connection: + x = x_input + x + return x + + class Head(nn.Module): + """The final module of `ResNet`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + normalization: ModuleType, + activation: ModuleType, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_in) + self.activation = _make_nn_module(activation) + self.linear = nn.Linear(d_in, d_out, bias) + + def forward(self, x: Tensor) -> Tensor: + if self.normalization is not None: + x = self.normalization(x) + x = self.activation(x) + x = self.linear(x) + return x + + def __init__( + self, + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + + self.first_layer = nn.Linear(d_in, d_main) + if d_main is None: + d_main = d_in + self.blocks = nn.Sequential( + *[ + ResNet.Block( + d_main=d_main, + d_hidden=d_hidden, + bias_first=True, + bias_second=True, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization=normalization, + activation=activation, + skip_connection=True, + ) + for _ in range(n_blocks) + ] + ) + self.head = ResNet.Head( + d_in=d_main, + d_out=d_out, + bias=True, + normalization=normalization, + activation=activation, + ) + + @classmethod + def make_baseline( + cls: Type['ResNet'], + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + d_out: int, + ) -> 'ResNet': + """Create a "baseline" `ResNet`. + This variation of ResNet was used in [gorishniy2021revisiting]. Features: + * :code:`Activation` = :code:`ReLU` + * :code:`Norm` = :code:`BatchNorm1d` + Args: + d_in: the input size + n_blocks: the number of Blocks + d_main: the input size (or, equivalently, the output size) of each Block + d_hidden: the output size of the first linear layer in each Block + dropout_first: the dropout rate of the first dropout layer in each Block. + dropout_second: the dropout rate of the second dropout layer in each Block. + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + return cls( + d_in=d_in, + n_blocks=n_blocks, + d_main=d_main, + d_hidden=d_hidden, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization='BatchNorm1d', + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + x = self.first_layer(x) + x = self.blocks(x) + x = self.head(x) + return x +#### For diffusion + +class MLPDiffusion(nn.Module): + def __init__(self, d_in, num_classes, is_y_cond, rtdl_params, dim_t = 128): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + self.is_y_cond = is_y_cond + + # d0 = rtdl_params['d_layers'][0] + + rtdl_params['d_in'] = dim_t + rtdl_params['d_out'] = d_in + + self.mlp = MLP.make_baseline(**rtdl_params) + + if self.num_classes > 0 and is_y_cond: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + elif self.num_classes == 0 and is_y_cond: + self.label_emb = nn.Linear(1, dim_t) + + self.proj = nn.Linear(d_in, dim_t) + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if self.is_y_cond and y is not None: + if self.num_classes > 0: + y = y.squeeze() + else: + y = y.resize(y.size(0), 1).float() + emb += F.silu(self.label_emb(y)) + x = self.proj(x) + emb + return self.mlp(x) + +class ResNetDiffusion(nn.Module): + def __init__(self, d_in, num_classes, rtdl_params, dim_t = 256): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + + rtdl_params['d_in'] = d_in + rtdl_params['d_out'] = d_in + rtdl_params['emb_d'] = dim_t + self.resnet = ResNet.make_baseline(**rtdl_params) + + if self.num_classes > 0: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if y is not None and self.num_classes > 0: + emb += self.label_emb(y.squeeze()) + return self.resnet(x, emb) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/utils.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/utils.py new file mode 100644 index 0000000000000000000000000000000000000000..6376bfbfb6971c3e465fafe9d56320d92a5f508a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tab_ddpm/utils.py @@ -0,0 +1,174 @@ +import torch +import numpy as np +import torch.nn.functional as F +from torch.profiler import record_function +from inspect import isfunction + +def normal_kl(mean1, logvar1, mean2, logvar2): + """ + Compute the KL divergence between two gaussians. + + Shapes are automatically broadcasted, so batches can be compared to + scalars, among other use cases. + """ + tensor = None + for obj in (mean1, logvar1, mean2, logvar2): + if isinstance(obj, torch.Tensor): + tensor = obj + break + assert tensor is not None, "at least one argument must be a Tensor" + + # Force variances to be Tensors. Broadcasting helps convert scalars to + # Tensors, but it does not work for torch.exp(). + logvar1, logvar2 = [ + x if isinstance(x, torch.Tensor) else torch.tensor(x).to(tensor) + for x in (logvar1, logvar2) + ] + + return 0.5 * ( + -1.0 + + logvar2 + - logvar1 + + torch.exp(logvar1 - logvar2) + + ((mean1 - mean2) ** 2) * torch.exp(-logvar2) + ) + +def approx_standard_normal_cdf(x): + """ + A fast approximation of the cumulative distribution function of the + standard normal. + """ + return 0.5 * (1.0 + torch.tanh(np.sqrt(2.0 / np.pi) * (x + 0.044715 * torch.pow(x, 3)))) + + +def discretized_gaussian_log_likelihood(x, *, means, log_scales): + """ + Compute the log-likelihood of a Gaussian distribution discretizing to a + given image. + + :param x: the target images. It is assumed that this was uint8 values, + rescaled to the range [-1, 1]. + :param means: the Gaussian mean Tensor. + :param log_scales: the Gaussian log stddev Tensor. + :return: a tensor like x of log probabilities (in nats). + """ + assert x.shape == means.shape == log_scales.shape + centered_x = x - means + inv_stdv = torch.exp(-log_scales) + plus_in = inv_stdv * (centered_x + 1.0 / 255.0) + cdf_plus = approx_standard_normal_cdf(plus_in) + min_in = inv_stdv * (centered_x - 1.0 / 255.0) + cdf_min = approx_standard_normal_cdf(min_in) + log_cdf_plus = torch.log(cdf_plus.clamp(min=1e-12)) + log_one_minus_cdf_min = torch.log((1.0 - cdf_min).clamp(min=1e-12)) + cdf_delta = cdf_plus - cdf_min + log_probs = torch.where( + x < -0.999, + log_cdf_plus, + torch.where(x > 0.999, log_one_minus_cdf_min, torch.log(cdf_delta.clamp(min=1e-12))), + ) + assert log_probs.shape == x.shape + return log_probs + +def sum_except_batch(x, num_dims=1): + ''' + Sums all dimensions except the first. + + Args: + x: Tensor, shape (batch_size, ...) + num_dims: int, number of batch dims (default=1) + + Returns: + x_sum: Tensor, shape (batch_size,) + ''' + return x.reshape(*x.shape[:num_dims], -1).sum(-1) + +def mean_flat(tensor): + """ + Take the mean over all non-batch dimensions. + """ + return tensor.mean(dim=list(range(1, len(tensor.shape)))) + +def ohe_to_categories(ohe, K): + K = torch.from_numpy(K) + indices = torch.cat([torch.zeros((1,)), K.cumsum(dim=0)], dim=0).int().tolist() + res = [] + for i in range(len(indices) - 1): + res.append(ohe[:, indices[i]:indices[i+1]].argmax(dim=1)) + return torch.stack(res, dim=1) + +def log_1_min_a(a): + return torch.log(1 - a.exp() + 1e-40) + + +def log_add_exp(a, b): + maximum = torch.max(a, b) + return maximum + torch.log(torch.exp(a - maximum) + torch.exp(b - maximum)) + +def exists(x): + return x is not None + +def extract(a, t, x_shape): + b, *_ = t.shape + t = t.to(a.device) + out = a.gather(-1, t) + while len(out.shape) < len(x_shape): + out = out[..., None] + return out.expand(x_shape) + +def default(val, d): + if exists(val): + return val + return d() if isfunction(d) else d + +def log_categorical(log_x_start, log_prob): + return (log_x_start.exp() * log_prob).sum(dim=1) + +def index_to_log_onehot(x, num_classes): + onehots = [] + for i in range(len(num_classes)): + onehots.append(F.one_hot(x[:, i], num_classes[i])) + + x_onehot = torch.cat(onehots, dim=1) + log_onehot = torch.log(x_onehot.float().clamp(min=1e-30)) + return log_onehot + +def log_sum_exp_by_classes(x, slices): + device = x.device + res = torch.zeros_like(x) + for ixs in slices: + res[:, ixs] = torch.logsumexp(x[:, ixs], dim=1, keepdim=True) + + assert x.size() == res.size() + + return res + +@torch.jit.script +def log_sub_exp(a: torch.Tensor, b: torch.Tensor) -> torch.Tensor: + m = torch.maximum(a, b) + return torch.log(torch.exp(a - m) - torch.exp(b - m)) + m + +@torch.jit.script +def sliced_logsumexp(x, slices): + lse = torch.logcumsumexp( + torch.nn.functional.pad(x, [1, 0, 0, 0], value=-float('inf')), + dim=-1) + + slice_starts = slices[:-1] + slice_ends = slices[1:] + + slice_lse = log_sub_exp(lse[:, slice_ends], lse[:, slice_starts]) + slice_lse_repeated = torch.repeat_interleave( + slice_lse, + slice_ends - slice_starts, + dim=-1 + ) + return slice_lse_repeated + +def log_onehot_to_index(log_x): + return log_x.argmax(1) + +class FoundNANsError(BaseException): + """Found NANs during sampling""" + def __init__(self, message='Found NANs during sampling.'): + super(FoundNANsError, self).__init__(message) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/convert_synth_to_csv.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/convert_synth_to_csv.py new file mode 100644 index 0000000000000000000000000000000000000000..be1bb6180758714a938e9c5c73a51029523e20f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/convert_synth_to_csv.py @@ -0,0 +1,89 @@ +#!/usr/bin/env python3 +""" +Convert generated synthetic data from npy files to CSV format. +""" +import os +import sys +import numpy as np +import pandas as pd +import argparse + +def convert_to_csv(parent_dir, output_path=None): + """ + Convert generated synthetic data to CSV. + + Args: + parent_dir: Directory containing X_num_train.npy, X_cat_train.npy, y_train.npy + output_path: Output CSV file path (default: parent_dir/synth_train.csv) + """ + parent_dir = os.path.abspath(parent_dir) + + # Load npy files + x_num_path = os.path.join(parent_dir, 'X_num_train.npy') + x_cat_path = os.path.join(parent_dir, 'X_cat_train.npy') + y_path = os.path.join(parent_dir, 'y_train.npy') + + data_parts = [] + column_names = [] + + # Load numerical features + if os.path.exists(x_num_path): + X_num = np.load(x_num_path, allow_pickle=True) + print(f"Loaded X_num: shape {X_num.shape}") + data_parts.append(X_num) + # Create column names for numerical features + for i in range(X_num.shape[1]): + column_names.append(f'num_{i}') + + # Load categorical features + if os.path.exists(x_cat_path): + X_cat = np.load(x_cat_path, allow_pickle=True) + print(f"Loaded X_cat: shape {X_cat.shape}") + data_parts.append(X_cat) + # Create column names for categorical features + for i in range(X_cat.shape[1]): + column_names.append(f'cat_{i}') + + # Load target + if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + print(f"Loaded y: shape {y.shape}") + # Reshape if needed + if y.ndim == 1: + y = y.reshape(-1, 1) + data_parts.append(y) + column_names.append('y') + + if not data_parts: + raise ValueError(f"No data files found in {parent_dir}") + + # Concatenate all parts + data = np.hstack(data_parts) + print(f"Combined data shape: {data.shape}") + print(f"Number of columns: {len(column_names)}") + + # Create DataFrame + df = pd.DataFrame(data, columns=column_names) + + # Determine output path + if output_path is None: + output_path = os.path.join(parent_dir, 'synth_train.csv') + + # Save to CSV + df.to_csv(output_path, index=False) + print(f"[OK] Saved synthetic data to: {output_path}") + print(f"[OK] Total samples: {len(df)}, Total columns: {len(df.columns)}") + + # Print summary statistics + print("\n=== Data Summary ===") + print(df.describe()) + + return output_path + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description='Convert synthetic npy files to CSV') + parser.add_argument('parent_dir', type=str, help='Directory containing generated npy files') + parser.add_argument('--output', '-o', type=str, default=None, help='Output CSV file path (default: parent_dir/synth_train.csv)') + + args = parser.parse_args() + convert_to_csv(args.parent_dir, args.output) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/make_tabddpm_info.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/make_tabddpm_info.py new file mode 100644 index 0000000000000000000000000000000000000000..30acf64d04521bfa8fc1810c893395eed5bd57a4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tools/make_tabddpm_info.py @@ -0,0 +1,97 @@ +import os, json +import numpy as np + +def load(path): + return np.load(path, allow_pickle=True) + +def main(data_dir: str): + # required files + req = [ + "X_num_train.npy","X_num_val.npy","X_num_test.npy", + "X_cat_train.npy","X_cat_val.npy","X_cat_test.npy", + "y_train.npy","y_val.npy","y_test.npy" + ] + for f in req: + p = os.path.join(data_dir, f) + if not os.path.exists(p): + raise FileNotFoundError(p) + + Xn_tr = load(os.path.join(data_dir,"X_num_train.npy")) + Xc_tr = load(os.path.join(data_dir,"X_cat_train.npy")) + y_tr = load(os.path.join(data_dir,"y_train.npy")) + + # basic dims + n_num = 0 if Xn_tr.ndim < 2 else int(Xn_tr.shape[1]) + n_cat = 0 if Xc_tr.ndim < 2 else int(Xc_tr.shape[1]) + + # infer task / y info + y_flat = y_tr.reshape(-1) + uniq = np.unique(y_flat) + # if y is integer and has few unique values, could be classification + is_int = np.issubdtype(y_flat.dtype, np.integer) + num_classes = int(len(uniq)) if is_int else 0 + + # determine task_type + if is_int and num_classes == 2: + task_type = "binclass" + elif is_int and num_classes > 2 and num_classes <= 100: + task_type = "multiclass" + else: + task_type = "regression" + + # cat sizes (per categorical column) + cat_sizes = [] + if n_cat > 0: + # compute max+1 per column (assume categories encoded 0..K-1) + for j in range(n_cat): + col = Xc_tr[:, j].reshape(-1) + if col.size == 0: + cat_sizes.append(0) + else: + mx = int(np.max(col)) + cat_sizes.append(mx + 1) + + # numeric stats (optional but useful) + num_stats = {} + if n_num > 0: + # mean/std/min/max over train numeric + num_stats = { + "mean": np.mean(Xn_tr, axis=0).tolist(), + "std": (np.std(Xn_tr, axis=0) + 1e-12).tolist(), + "min": np.min(Xn_tr, axis=0).tolist(), + "max": np.max(Xn_tr, axis=0).tolist(), + } + + # This repo expects info.json. Keep fields simple & robust. + info = { + "task_type": task_type, + "n_num_features": n_num, + "n_cat_features": n_cat, + "cat_sizes": cat_sizes, + "y_dtype": str(y_flat.dtype), + "y_unique_count": int(len(uniq)), + "y_unique_head": uniq[:20].tolist(), + # heuristics: user can override in config.toml + "is_classification_like": bool(is_int and len(uniq) <= 100), + "num_classes_like": num_classes, + } + + # write files + with open(os.path.join(data_dir, "info.json"), "w", encoding="utf-8") as f: + json.dump(info, f, ensure_ascii=False, indent=2) + + # some codepaths may look for these (harmless if unused) + with open(os.path.join(data_dir, "cat_sizes.json"), "w", encoding="utf-8") as f: + json.dump({"cat_sizes": cat_sizes}, f, ensure_ascii=False, indent=2) + + with open(os.path.join(data_dir, "num_stats.json"), "w", encoding="utf-8") as f: + json.dump(num_stats, f, ensure_ascii=False, indent=2) + + print("[OK] wrote:", os.path.join(data_dir,"info.json")) + print("[OK] n_num =", n_num, "n_cat =", n_cat, "cat_sizes =", cat_sizes) + print("[OK] y unique count =", len(uniq), "head =", uniq[:20]) + +if __name__ == "__main__": + data_dir = "data/Tab-Cate-1" + main(data_dir) + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7641bbf14b10338ac870e2a999866a64a3e119fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aad08aabbf726ab65389e42c3a524f407e6bc791edcb5af304c31ba9037f6c10 +size 351 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..51f7cdde4deeb5adf383c063ca60fe69af2092a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:956a488f34e502db9975d86ef25b75cf5c01c08a3e5a47c7ade4f72cbf11374c +size 432 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bc1fcb92e6fb025976224ef2fbf1335d1b1518a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4577f6d2af34360bff6faf7a01af5501463e8b13ff0fc0c18bf2bfa67c6c63b +size 393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19e1861532e4b5e50495f5444496fb558f45e875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0508cdc40c02386321976c9537fbe54a5f2b0fa0e8e7dde72a6d4d289ced862c +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7fc8cd71e630bcadef6c582f458d3e328dfc7024 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a411285e39c4cb685233ec73375cfd023fb834897dd6b5a8f99cf7a7ec1c6656 +size 403 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d646aac53ef0d8ad9f508fb14f561739d52441a9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4dea09bdea9006ce44f71eef0e1740f639eceff44dd021c351ece84a428a00a +size 380 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..53328b6729355daaba91f378caca2944b08dfb82 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb7ad47bb5b1c9fbe54cf14cc854581b22ed72f9dbc47f0a022e48fa572b5ffc +size 372 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..91aa99b5999ba8561744b73f036584956aa27735 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1265117a3d8688b7878c62656b6d85bb543e723b1f5f01a2ed5bd4b12878dc +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..8b118aadedc57bcea9ed8af0ac0318b17bd3850d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:18ccbc230cd0959834d3155e67c29d259af90720d29bc4284b3209df5374886e +size 519 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..39add46e4bb47ed0bb1e451e680788465aefa231 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:efa67605a7699adf3cd46bb7d7d5512516ab3e5da3e01451004aadf9ee4f9d62 +size 333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6d0379ccd1631f30b7983ee0ed809a88c422aed2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4c67d2f9937dc5548b3c3a1ae71846e5fccc66853b8067670b979ff2a4f0201 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..9d636369299b13991976af26b6337be2c6c88494 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852eea0c2f88f7032cebc5dc7c9422be385d231f1ce8b5c9364a534d64fdf4f3 +size 332 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..0951c97fd762261760bf64abeee35635ac8b3277 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2201078a643eb78c649a3d4a9e897ecf39c2d7f35c5a9fdb055c91251694b808 +size 369 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..b95d7e8aecc468014085b8c0959aa9e7be64812c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a94473811e28035ef4781122c3da6e4f81b232b68a0042b64c30a1df648e02d3 +size 374 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19ec2cc100638b21b99c87f453a4d6d356803ecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14dcf192aa15f491f147b30e2312b55889a146c546d72d89ee2d07ff26cc2103 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..ea8143610c6a60053cbac687cb32b2c7b203ebc7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f6989397bf0029ee07b2ca9ab9335645ea3402bd6b782f2cec4cb40ad70b2ed +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..f497e044f1e3a1ffd35f852d285ab43b841e7fc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f99f28009311b8bb5413fbdbf72af25d1d384eec3c079c156e6a6eafa93e46bb +size 157 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..db818565ea71189907985b9a9424a41dec1b5261 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d4d4e1b062e420ce1838117b872e1794a632ea7f1dd8220eb640b71f793cd3a +size 229 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d12f3fe28d7b352a4bb737f24abf65feb094b39a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfe610df17eb46233b0dbba7fb71ea6117e9992763ae8ccd789159c296f3cc43 +size 165 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cb7256f2b264df6ee73bb260e84d4cafd983c2ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9970d5c42859dce6fded5b3fb285bba98181076d8db75b8ef78e5e0167c7b0c +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cfa75fad250058c3798cb53873aaef3e60289b3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc9642d070f056675cd4d004c0b446576eb162e2819dec052325fe7da59ce85d +size 148 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..3e15732f32083afa27c5290d88430aab1fadf294 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebea18b44a2d33a6643f283adf68961099d44d7e4f11e29148b501ddabb5894a +size 152 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..45eb9feca3f3f48f560a1c136037e0e83e9acda7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2d6082a82af0fb59906d778c57e4229eeff861066c1e24bea9c5e721f804214c +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..69cfdc546559ac76088c0ce9e2abea88323bcd09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:243a914fe90215cab4867d415cb82078366b5d2472264c91ea46d3e0e3291534 +size 147 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..27781e4df360af0c233babc28485990447ee59e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3a819ad5093581e1b94eeddb0655b99cccce3bb121f405b0b7e3b230c3c1a11 +size 190 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..826c0e4d0b890d21ac21a2b6b9015d2e80b88b1f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3520fe130d4570aa07a79031b6016f31a4f36cd5fdc9ff7167f0c7e1768a6697 +size 230 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..5f13b453f1c8978346138fbfae950bc48f8f419a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22f1903d9a59e6cc1df1a643b9bc216392fbb3549cb6555482898d4a7ac936aa +size 164 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..00d8f78622f81428c7c94021982ae59c8890fa84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:381e76611b072a0fb5fa41a7c640740453293a6d0cda8210697d4b9833d715e4 +size 171 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7c7fcaf8ef05cdad5022fb1430047318c48d2107 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:afbbb1a2be60833c9468ded47ba78228e5a00c42bed93681e4e2aa0c6b68278d +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6a2fa20fe823c8adf1023a889e918326997a7b8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:896a60d6ce4628cacdf5a3ec5a4c70b9fcff7944e373082ca34a6b55d7c6871a +size 175 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bfd0c2cc0dc2b572be260a3ec20b74139efd885c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1489c33a341492905b3145370808bd2201a18fe8a1ae604df8917408821f57de +size 144 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r0.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r0.py new file mode 100644 index 0000000000000000000000000000000000000000..08375865034330b03aa12affdb97f5fdfa485a21 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r0.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r0.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r1.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r1.py new file mode 100644 index 0000000000000000000000000000000000000000..d71f1a29d26841697c7ecd851efbfb20566d949c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r1.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r1.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r2.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r2.py new file mode 100644 index 0000000000000000000000000000000000000000..77173268f4cf9c16d8c9574deaf405f213be3e2d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r2.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r2.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r3.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r3.py new file mode 100644 index 0000000000000000000000000000000000000000..d8fda0c0d6f1854b90279f204f834bc1eb6df389 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r3.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r3.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r4.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r4.py new file mode 100644 index 0000000000000000000000000000000000000000..92c2bb511f562351d0ef778ccad393560655f782 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r4.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r4.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r5.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r5.py new file mode 100644 index 0000000000000000000000000000000000000000..51b6470d77e6a3d564e0f841bb0f08092d6fdc56 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_sample_r5.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r5.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/tabddpm-c12-2623-20260511_032110.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_train.py new file mode 100644 index 0000000000000000000000000000000000000000..4e315ab71a2b463205721a11dcc1f9a147bb19fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_train.py @@ -0,0 +1,42 @@ +import os, sys, subprocess + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + +import shutil +shutil.rmtree(runtime_root, ignore_errors=True) +shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Write a wrapper that patches collections.Sequence (removed in Python 3.10+) +# before running pipeline.py - needed because skorch uses old API +wrapper = os.path.join(runtime_root, "_compat_run.py") +with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Training, config=/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config.toml") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/config.toml", + "--train"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) +print("[TabDDPM] Training complete") diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7452e74fae2ca0d23136a0d6ef2ed831320a3d23 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cf09e9c30d9a5a4863c520c150c6a5d342f48160e9047a469b920640e54154a3 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r0.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r0.toml new file mode 100644 index 0000000000000000000000000000000000000000..e19ba9a67f99364845b4d6e4df55993809e812e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r0.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:001fd92e3fad55f01625b0f6d0af5cd79031f64a768599ff896f45bd3bced9a5 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r1.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r1.toml new file mode 100644 index 0000000000000000000000000000000000000000..5858b4bf79b5b4ba5f16d74205186ddb086f6902 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r1.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:31a08674aca42d8ab4eeed367a5c6620aa284001364379bf738eca478d6f7ca5 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r2.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r2.toml new file mode 100644 index 0000000000000000000000000000000000000000..639e08511ab70c7db0d080d959962ead688597b1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r2.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:110f135f9f2892d78f816b646ad601fb52fdf1b4cad3b51eacc36c0322563bfc +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r3.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r3.toml new file mode 100644 index 0000000000000000000000000000000000000000..b0da6460241e5f226703acc66e9aa5c6417f9571 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r3.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df543f4a87e7911c8adf783df22fcc8954cc3184f2b12390f02c5bf9785e7061 +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r4.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r4.toml new file mode 100644 index 0000000000000000000000000000000000000000..9b8566e644fac2abf23c8880138d1f59424074f5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r4.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f931a868b70b28db729ea38286e598003f4c12bbca26604b2463ddd06e305c1e +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r5.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r5.toml new file mode 100644 index 0000000000000000000000000000000000000000..e6360ac7cc9463cfed1251cc990a4946bf2ead53 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/config_sample_20260511_032110_r5.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a37361fc02da200b8638d1c6367c4a46e9271d5a56af710781fab806bdaa3a7e +size 771 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_cat_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_num_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d81ab6d13ff8932c1b47822a5508c046d9fd6f6b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce0d1648e7f4633f3c9aa6e2f8c5460ec86f01d4bfa155e977a71e9640744427 +size 51619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/y_train.npy b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/data/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r0.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r0.log new file mode 100644 index 0000000000000000000000000000000000000000..55bf01f0077917c208460300b706be121b12a20d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r0.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:432009cc96cdc84c002f82f7441bbd792cc28e22f9f6c8a05b928404d5669a01 +size 3512 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r1.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r1.log new file mode 100644 index 0000000000000000000000000000000000000000..33758cf8b69b0808a277bc5557a8ff018d6a054c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r1.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ff0c7369309dc717a2025601f326f2cd2fca5a762124686db9080aad2a69b06f +size 3512 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r2.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r2.log new file mode 100644 index 0000000000000000000000000000000000000000..dfca629e3cfd700d7f191214883333a741c6f554 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r2.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:38aa7831fabb7d7a17a9e2cd9ca0a63a27762e2568d51d3e71bd0833d2a32844 +size 3511 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r3.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r3.log new file mode 100644 index 0000000000000000000000000000000000000000..6f26c517b26e9adec1e04dec545754e7066f9ce8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r3.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:38a9f8204746c8f77dc5d2a576921d8fd2941a95f88644142da0c7f5841d29a3 +size 3531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r4.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r4.log new file mode 100644 index 0000000000000000000000000000000000000000..1abc73e12a129d89a2ee70637141c683ec051a81 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r4.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5ddad075cea8b1692bdd37894add1a2376abb5f759e481b15e142d05e05b5808 +size 3531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r5.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r5.log new file mode 100644 index 0000000000000000000000000000000000000000..f4367edb66a264b53bbdf4023e4c58bf5c838961 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/gen_20260511_032110_r5.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c4a00f23086527b01e28e1562b92aad3b98f5d2db00d3a983b5a743d78009a4 +size 3531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/input_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..ea0c7955c35965e09281e7ad72e7f9722a3d793b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:754197615fcbb84d31c0a54a0fd62ded7a78578807874b50d4c73f62b7e80ef5 +size 1367 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/._data b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/._data new file mode 100755 index 0000000000000000000000000000000000000000..89e52d9d55eea94a37ca2bfdd186b4b892b24643 Binary files /dev/null and b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/._data differ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..9b148cde6e315b01b30652b19f39a11f211dff1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitignore @@ -0,0 +1,22 @@ +.DS_Store +__pycache__/ +catboost_info/ +**/**.pt +**/**.ipynb +!agg_results.ipynb +**/**.npy +**/**.gz +**/**.sh +**/**.obj +**/**.png +**/**.tar +**/**.code-workspace +**/**.csv +exp/**/**/results_catboost.json +exp/**/**/results_mlp.json + +configs/ +data/ +junk/ +RF/ +exps/ \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitmodules b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitmodules new file mode 100644 index 0000000000000000000000000000000000000000..8c677ab737cbbdbc5c806cf58d27960efefcb11a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/.gitmodules @@ -0,0 +1,9 @@ +[submodule "ctgan"] + # path = CTGAN/CTGAN + url = https://github.com/sdv-dev/CTGAN +[submodule "ctabgan"] + # path = CTAB-GAN + url = https://github.com/Team-TUD/CTAB-GAN +[submodule "ctabgan+"] + # path = CTAB-GAN-Plus + url = https://github.com/Team-TUD/CTAB-GAN-Plus \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CONFIG_DESCRIPTION.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CONFIG_DESCRIPTION.md new file mode 100644 index 0000000000000000000000000000000000000000..646a0c00f329b55bc736d5cdbd1e797d1143cd1c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CONFIG_DESCRIPTION.md @@ -0,0 +1,78 @@ +# Description of .toml config for TabDDPM +First of all, `train.T` and `eval.T` denote preprocessing for training and for evaluation, respectively. + +Here we list non-obvious parameters. + +Main part: +- `seed = 0` -- evaluation seed (and training, but for training it is fixed to 0) +- `parent_dir = "exp/abalone/check"` -- exp folder +- `real_data_path = "data/abalone/"` +- `model_type = "mlp"` -- model type that approximates the reverse process +- `num_numerical_features ` -- a number of numerical features in dataset +- `device = "cuda:0"` + +Model params: +- `is_y_cond` -- false for regression, true for classification +- `d_in` -- input dimension (not necessary, since scripts calculate it automatically) +- `num_calsses` -- zero for regression, a number of classes for classification +- `rtdl_params` -- MLP parameters + +```toml +seed = 0 +parent_dir = "exp/abalone/check" +real_data_path = "data/abalone/" +model_type = "mlp" +num_numerical_features = 7 +device = "cuda:0" + +[model_params] +is_y_cond = false +d_in = 11 +num_classes = 0 + +[model_params.rtdl_params] +d_layers = [ + 256, + 256, +] +dropout = 0.0 + +[diffusion_params] +num_timesteps = 1000 +gaussian_loss_type = "mse" +scheduler = "cosine" + +[train.main] +steps = 1000 +lr = 0.001 +weight_decay = 1e-05 +batch_size = 4096 + +[train.T] +seed = 0 +normalization = "quantile" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +[sample] +num_samples = 20800 +batch_size = 10000 +seed = 0 + +[eval.type] +eval_model = "catboost" +eval_type = "synthetic" + +[eval.T] +seed = 0 +normalization = "__none__" +num_nan_policy = "__none__" +cat_nan_policy = "__none__" +cat_min_frequency = "__none__" +cat_encoding = "__none__" +y_policy = "default" + +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/README.md new file mode 100644 index 0000000000000000000000000000000000000000..e873924cc56b6603669d17e6ab3badd4aba0657a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/README.md @@ -0,0 +1,49 @@ +# CTAB-GAN+ +This is the official git paper [CTAB-GAN+: Enhancing Tabular Data Synthesis](https://arxiv.org/abs/2204.00401). Current code is without differential privacy part. +If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` +The sklean package in newer version has updated its function for `sklearn.mixture.BayesianGaussianMixture`. Therefore, user should use this proposed sklearn version to successfully run the code! + +## Example +`Experiment_Script_Adult.ipynb` `Experiment_Script_king.ipynb` are two example notebooks for training CTAB-GAN+ with Adult (classification) and king (regression) datasets. The datasets are alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## Problem type + +You can either indicate your dataset problem type as Classification, Regression. If there is no problem type, you can leave the problem type as None as follows: +``` +problem_type= {None: None} +``` + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN+ will wrap the encoded data into an image-like format. What you can do is changing the line 378 and 385 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@article{zhao2022ctab, + title={CTAB-GAN+: Enhancing Tabular Data Synthesis}, + author={Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y}, + journal={arXiv preprint arXiv:2204.00401}, + year={2022} +} +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..ac695958cb0fb057fa024d712d065588e43e5279 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0d9e05a1c251995561cb1f4b2688be2c332a4971a0513d15645089efc0e236a +size 4355 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..81782dcde9f07f3d8178c29ba08ceb129c40f58f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/ctabgan.py @@ -0,0 +1,70 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + general_columns = ["age"], + non_categorical_columns = [], + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": "income"}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, seed=0): + + sample = self.synthesizer.sample(len(self.raw_df), seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..abe1f725f7d09f7284abef0dd9c1187f0e3c96bf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/pipeline/data_preparation.py @@ -0,0 +1,130 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..9fd6845ffaf8f3a991acceba92af143941e5c11f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,601 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 64] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 64] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=2e-4, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + while len(result) < n: + data_resample = [] + steps_left = resample// self.batch_size + 1 + + for i in range(steps_left): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(self.batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model copy/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a99b5d587da5f3e49b3923e43975e02e9c11e6e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/ctabgan.py @@ -0,0 +1,72 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [], + log_columns = [], + mixed_columns= {}, + general_columns = [], + non_categorical_columns = [], + integer_columns = [], + problem_type= {}, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer( + class_dim=class_dim, + random_dim=random_dim, + num_channels=num_channels, + l2scale=l2scale, + lr=lr, + batch_size=batch_size, + epochs=epochs, + device=device + ) + self.raw_df = df + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.general_columns = general_columns + self.non_categorical_columns = non_categorical_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self): + + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.general_columns,self.non_categorical_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], mixed = self.data_prep.column_types["mixed"], + general = self.data_prep.column_types["general"], non_categorical = self.data_prep.column_types["non_categorical"], type=self.problem_type) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..1492fcf80cfb907f95b3844e4c0f38f15effbdb0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/eval/evaluation.py @@ -0,0 +1,193 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(data_real_X) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..3f4b7293d63db51bc7c9da6c38b84c6c033d779b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/pipeline/data_preparation.py @@ -0,0 +1,131 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, general:list, non_categorical:list, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.general_columns = general + self.non_categorical_columns = non_categorical + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.column_types["general"] = [] + self.column_types["non_categorical"] = [] + self.lower_bounds = {} + self.label_encoder_list = [] + + target_col = list(type.values())[0] + if target_col is not None: + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + + X_train_real[target_col]= y_train_real + + self.df = X_train_real + else: + self.df = raw_df + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + if column in self.general_columns: + self.column_types["general"].append(column_index) + + if column in self.non_categorical_columns: + self.column_types["non_categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + elif column in self.general_columns: + self.column_types["general"].append(column_index) + + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py new file mode 100644 index 0000000000000000000000000000000000000000..5e225cbb0994fa6b9e9726f38d873754bbfe82cf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/privacy_utils/rdp_accountant.py @@ -0,0 +1,280 @@ +from __future__ import absolute_import +from __future__ import division +from __future__ import print_function + +import math +import sys + +import numpy as np +from scipy import special +import six + +######################## +# LOG-SPACE ARITHMETIC # +######################## + + +def _log_add(logx, logy): + """Add two numbers in the log space.""" + a, b = min(logx, logy), max(logx, logy) + if a == -np.inf: # adding 0 + return b + # Use exp(a) + exp(b) = (exp(a - b) + 1) * exp(b) + return math.log1p(math.exp(a - b)) + b # log1p(x) = log(x + 1) + + +def _log_sub(logx, logy): + """Subtract two numbers in the log space. Answer must be non-negative.""" + if logx < logy: + raise ValueError("The result of subtraction must be non-negative.") + if logy == -np.inf: # subtracting 0 + return logx + if logx == logy: + return -np.inf # 0 is represented as -np.inf in the log space. + + try: + # Use exp(x) - exp(y) = (exp(x - y) - 1) * exp(y). + return math.log(math.expm1(logx - logy)) + logy # expm1(x) = exp(x) - 1 + except OverflowError: + return logx + + +def _log_print(logx): + """Pretty print.""" + if logx < math.log(sys.float_info.max): + return "{}".format(math.exp(logx)) + else: + return "exp({})".format(logx) + + +def _compute_log_a_int(q, sigma, alpha): + """Compute log(A_alpha) for integer alpha. 0 < q < 1.""" + assert isinstance(alpha, six.integer_types) + + # Initialize with 0 in the log space. + log_a = -np.inf + + for i in range(alpha + 1): + log_coef_i = ( + math.log(special.binom(alpha, i)) + i * math.log(q) + + (alpha - i) * math.log(1 - q)) + + s = log_coef_i + (i * i - i) / (2 * (sigma**2)) + log_a = _log_add(log_a, s) + + return float(log_a) + + +def _compute_log_a_frac(q, sigma, alpha): + """Compute log(A_alpha) for fractional alpha. 0 < q < 1.""" + # The two parts of A_alpha, integrals over (-inf,z0] and [z0, +inf), are + # initialized to 0 in the log space: + log_a0, log_a1 = -np.inf, -np.inf + i = 0 + + z0 = sigma**2 * math.log(1 / q - 1) + .5 + + while True: # do ... until loop + coef = special.binom(alpha, i) + log_coef = math.log(abs(coef)) + j = alpha - i + + log_t0 = log_coef + i * math.log(q) + j * math.log(1 - q) + log_t1 = log_coef + j * math.log(q) + i * math.log(1 - q) + + log_e0 = math.log(.5) + _log_erfc((i - z0) / (math.sqrt(2) * sigma)) + log_e1 = math.log(.5) + _log_erfc((z0 - j) / (math.sqrt(2) * sigma)) + + log_s0 = log_t0 + (i * i - i) / (2 * (sigma**2)) + log_e0 + log_s1 = log_t1 + (j * j - j) / (2 * (sigma**2)) + log_e1 + + if coef > 0: + log_a0 = _log_add(log_a0, log_s0) + log_a1 = _log_add(log_a1, log_s1) + else: + log_a0 = _log_sub(log_a0, log_s0) + log_a1 = _log_sub(log_a1, log_s1) + + i += 1 + if max(log_s0, log_s1) < -30: + break + + return _log_add(log_a0, log_a1) + + +def _compute_log_a(q, sigma, alpha): + """Compute log(A_alpha) for any positive finite alpha.""" + if float(alpha).is_integer(): + return _compute_log_a_int(q, sigma, int(alpha)) + else: + return _compute_log_a_frac(q, sigma, alpha) + + +def _log_erfc(x): + """Compute log(erfc(x)) with high accuracy for large x.""" + try: + return math.log(2) + special.log_ndtr(-x * 2**.5) + except NameError: + # If log_ndtr is not available, approximate as follows: + r = special.erfc(x) + if r == 0.0: + # Using the Laurent series at infinity for the tail of the erfc function: + # erfc(x) ~ exp(-x^2-.5/x^2+.625/x^4)/(x*pi^.5) + # To verify in Mathematica: + # Series[Log[Erfc[x]] + Log[x] + Log[Pi]/2 + x^2, {x, Infinity, 6}] + return (-math.log(math.pi) / 2 - math.log(x) - x**2 - .5 * x**-2 + + .625 * x**-4 - 37. / 24. * x**-6 + 353. / 64. * x**-8) + else: + return math.log(r) + + +def _compute_delta(orders, rdp, eps): + """Compute delta given a list of RDP values and target epsilon. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + eps: The target epsilon. + + Returns: + Pair of (delta, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + deltas = np.exp((rdp_vec - eps) * (orders_vec - 1)) + idx_opt = np.argmin(deltas) + return min(deltas[idx_opt], 1.), orders_vec[idx_opt] + + +def _compute_eps(orders, rdp, delta): + """Compute epsilon given a list of RDP values and target delta. + + Args: + orders: An array (or a scalar) of orders. + rdp: A list (or a scalar) of RDP guarantees. + delta: The target delta. + + Returns: + Pair of (eps, optimal_order). + + Raises: + ValueError: If input is malformed. + + """ + orders_vec = np.atleast_1d(orders) + rdp_vec = np.atleast_1d(rdp) + + if len(orders_vec) != len(rdp_vec): + raise ValueError("Input lists must have the same length.") + + eps = rdp_vec - math.log(delta) / (orders_vec - 1) + + idx_opt = np.nanargmin(eps) # Ignore NaNs + return eps[idx_opt], orders_vec[idx_opt] + + +def _compute_rdp(q, sigma, alpha): + """Compute RDP of the Sampled Gaussian mechanism at order alpha. + + Args: + q: The sampling rate. + sigma: The std of the additive Gaussian noise. + alpha: The order at which RDP is computed. + + Returns: + RDP at alpha, can be np.inf. + """ + if q == 0: + return 0 + + if q == 1.: + return alpha / (2 * sigma**2) + + if np.isinf(alpha): + return np.inf + + return _compute_log_a(q, sigma, alpha) / (alpha - 1) + + +def compute_rdp(q, noise_multiplier, steps, orders): + """Compute RDP of the Sampled Gaussian Mechanism. + + Args: + q: The sampling rate. + noise_multiplier: The ratio of the standard deviation of the Gaussian noise + to the l2-sensitivity of the function to which it is added. + steps: The number of steps. + orders: An array (or a scalar) of RDP orders. + + Returns: + The RDPs at all orders, can be np.inf. + """ + if np.isscalar(orders): + rdp = _compute_rdp(q, noise_multiplier, orders) + else: + rdp = np.array([_compute_rdp(q, noise_multiplier, order) + for order in orders]) + + return rdp * steps + + +def get_privacy_spent(orders, rdp, target_eps=None, target_delta=None): + """Compute delta (or eps) for given eps (or delta) from RDP values. + + Args: + orders: An array (or a scalar) of RDP orders. + rdp: An array of RDP values. Must be of the same length as the orders list. + target_eps: If not None, the epsilon for which we compute the corresponding + delta. + target_delta: If not None, the delta for which we compute the corresponding + epsilon. Exactly one of target_eps and target_delta must be None. + + Returns: + eps, delta, opt_order. + + Raises: + ValueError: If target_eps and target_delta are messed up. + """ + if target_eps is None and target_delta is None: + raise ValueError( + "Exactly one out of eps and delta must be None. (Both are).") + + if target_eps is not None and target_delta is not None: + raise ValueError( + "Exactly one out of eps and delta must be None. (None is).") + + if target_eps is not None: + delta, opt_order = _compute_delta(orders, rdp, target_eps) + return target_eps, delta, opt_order + else: + eps, opt_order = _compute_eps(orders, rdp, target_delta) + return eps, target_delta, opt_order + + +def compute_rdp_from_ledger(ledger, orders): + """Compute RDP of Sampled Gaussian Mechanism from ledger. + + Args: + ledger: A formatted privacy ledger. + orders: An array (or a scalar) of RDP orders. + + Returns: + RDP at all orders, can be np.inf. + """ + total_rdp = np.zeros_like(orders, dtype=float) + for sample in ledger: + # Compute equivalent z from l2_clip_bounds and noise stddevs in sample. + # See https://arxiv.org/pdf/1812.06210.pdf for derivation of this formula. + effective_z = sum([ + (q.noise_stddev / q.l2_norm_bound)**-2 for q in sample.queries])**-0.5 + total_rdp += compute_rdp( + sample.selection_probability, effective_z, 1, orders) + return total_rdp \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..521a29aff4e8db1d45c7c3be98d593892c65c8d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,605 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss,LayerNorm) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from model.privacy_utils.rdp_accountant import compute_rdp, get_privacy_spent +from tqdm import tqdm, trange +import time + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + if item[2] == 'yes_g': + c+=1 + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + + ed= st+output_info[tc][0] + + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + num_c = num_channels + num_s = side / 2 + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c * 2 + num_s = num_s / 2 + + layers_D = [] + + for prev, curr, ln in zip(layer_dims, layer_dims[1:], layerNorms): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + LayerNorm(ln), + LeakyReLU(0.2, inplace=True), + ] + + layers_D += [Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), ReLU(True)] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 64 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layerNorms = [] + + num_c = num_channels * (2 ** (len(layer_dims) - 2)) + num_s = int(side / (2 ** (len(layer_dims) - 1))) + for l in range(len(layer_dims) - 1): + layerNorms.append([int(num_c), int(num_s), int(num_s)]) + num_c = num_c / 2 + num_s = num_s * 2 + + layers_G = [ConvTranspose2d(random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False)] + + for prev, curr, ln in zip(reversed(layer_dims), reversed(layer_dims[:-1]), layerNorms): + layers_G += [LayerNorm(ln), ReLU(True), ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True)] + return layers_G + +def slerp(val, low, high): + low_norm = low/torch.norm(low, dim=1, keepdim=True) + high_norm = high/torch.norm(high, dim=1, keepdim=True) + omega = torch.acos((low_norm*high_norm).sum(1)).view(val.size(0), 1) + so = torch.sin(omega) + res = (torch.sin((1.0-val)*omega)/so)*low + (torch.sin(val*omega)/so) * high + + return res + +def calc_gradient_penalty_slerp(netD, real_data, fake_data, transformer, device='cpu', lambda_=10): + batchsize = real_data.shape[0] + alpha = torch.rand(batchsize, 1, device=device) + interpolates = slerp(alpha, real_data, fake_data) + interpolates = interpolates.to(device) + interpolates = transformer.transform(interpolates) + interpolates = torch.autograd.Variable(interpolates, requires_grad=True) + disc_interpolates,_ = netD(interpolates) + + gradients = torch.autograd.grad(outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size()).to(device), + create_graph=True, retain_graph=True, only_inputs=True)[0] + + gradients_norm = gradients.norm(2, dim=1) + gradient_penalty = ((gradients_norm - 1) ** 2).mean() * lambda_ + + return gradient_penalty + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + class_dim=(256, 256, 256, 256), + random_dim=100, + num_channels=64, + l2scale=1e-5, + batch_size=500, + epochs=150, + lr=2e-4, + device="cpu"): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = torch.device(device) + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, general=[], non_categorical=[], type={}): + + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed, general_list=general, non_categorical_list=non_categorical) + self.transformer.fit() + train_data = self.transformer.transform(train_data.values) + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + epsilon = 0 + epoch = 0 + steps = 0 + ci = 1 + + for i in tqdm(range(self.epochs)): + + + for _ in range(ci): + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + + d_real,_ = discriminator(real_cat_d) + + + d_real = -torch.mean(d_real) + d_real.backward() + + + d_fake,_ = discriminator(fake_cat_d) + + d_fake = torch.mean(d_fake) + + d_fake.backward() + + pen = calc_gradient_penalty_slerp(discriminator, real_cat, fake_cat, self.Dtransformer , self.device) + + pen.backward() + + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + + g = -torch.mean(y_fake) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + + + + @torch.no_grad() + def sample(self, n, seed=0): + print(n) + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result,resample = self.transformer.inverse_transform(data) + + t0 = time.time() + while len(result) < n and (time.time() - t0) <= 600: + data_resample = [] + steps_left = resample// sample_batch_size + 1 + # print(f"Sampling: {len(result)}/{n}") + for i in range(steps_left): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, output_info) + data_resample.append(fakeact.detach().cpu().numpy()) + + data_resample = np.concatenate(data_resample, axis=0) + + res,resample = self.transformer.inverse_transform(data_resample) + result = np.concatenate([result,res],axis=0) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..ddad92266dc6d8b47e9ea1f4b4528795b9126e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/model/synthesizer/transformer.py @@ -0,0 +1,429 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, general_list=[], non_categorical_list=[], n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + self.general_columns = general_list + self.non_categorical_columns= non_categorical_list + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + if index in self.non_categorical_columns: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + else: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + gm = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh','no_g'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + else: + model.append(None) + self.components.append(None) + self.output_info += [(1, 'tanh','yes_g')] + self.output_dim += 1 + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture( + n_components = self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh',"no_g"), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + if id_ not in self.general_columns: + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + else: + + self.ordering.append(None) + + if id_ in self.non_categorical_columns: + info['min'] = -1e-3 + info['max'] = info['max'] + 1e-3 + + current = (current - (info['min'])) / (info['max'] - info['min']) + current = current * 2 - 1 + current = current.reshape([-1, 1]) + values.append(current) + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + invalid_ids = [] + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + if id_ not in self.general_columns: + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + + for idx,val in enumerate(tmp): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + if id_ in self.non_categorical_columns: + + tmp = np.round(tmp) + + data_t[:, id_] = tmp + + else: + u = data[:, st] + u = (u + 1) / 2 + u = np.clip(u, 0, 1) + u = u * (info['max'] - info['min']) + info['min'] + if id_ in self.non_categorical_columns: + data_t[:, id_] = np.round(u) + else: data_t[:, id_] = u + + st += 1 + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + + + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + for idx,val in enumerate(result): + if (val < info["min"]) | (val > info['max']): + invalid_ids.append(idx) + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + + invalid_ids = np.unique(np.array(invalid_ids)) + all_ids = np.arange(0,len(data)) + valid_ids = list(set(all_ids) - set(invalid_ids)) + + return data_t[valid_ids],len(invalid_ids) + + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..a584f91844e866d04f3c59297ca66017f1e7dd6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/pipeline_ctabganp.py @@ -0,0 +1,81 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib +from model.ctabgan import CTABGAN + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py new file mode 100644 index 0000000000000000000000000000000000000000..c1f668fe5b5d3d5255a3587982e968276e60273d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/train_sample_ctabganp.py @@ -0,0 +1,110 @@ +import lib +import os +import numpy as np +import argparse +from model.ctabgan import CTABGAN +from pathlib import Path +import torch +import pickle + + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN-Plus/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..ed19426b03246e546e234a2501a7c06f173d9f03 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN-Plus/tune_ctabgan.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +from random import random +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabganp import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + # steps = trial.suggest_categorical('steps', [1000]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan-plus/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan-plus/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan-plus/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan-plus", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..2473a164760acb3c77f225f094e19e2e0f523912 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/.gitignore @@ -0,0 +1 @@ +**/**.csv \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..261eeb9e9f8b2b4b0d119366dda99c6fd7d35c64 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/License.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/License.txt new file mode 100644 index 0000000000000000000000000000000000000000..5404b6f9e08e11c3a28a214518830c963060c885 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/License.txt @@ -0,0 +1,15 @@ +Distributed learning systems Lab at TU Delft & Generatrix, hereby disclaims all copyright interest in the program "CTAB-GAN" (which synthesizes tabular data) + +Copyright 2020-2022 Distributed learning systems Lab at TU Delft & Generatrix. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + https://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..7fd4f2ac92abf9b244313a9ecf7d8328932cfc8c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/README.md @@ -0,0 +1,50 @@ +# CTAB-GAN +This is the official git paper [CTAB-GAN: Effective Table Data Synthesizing](https://proceedings.mlr.press/v157/zhao21a.html). The paper is published on Asian Conference on Machine Learning (ACML 2021), please check our pdf on PMLR website for our newest version of [paper](https://proceedings.mlr.press/v157/zhao21a.html), it adds more content on time consumption analysis of training CTAB-GAN. If you have any question, please contact `z.zhao-8@tudelft.nl` for more information. + + +## Prerequisite + +The required package version +``` +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 +``` + +## Example +`Experiment_Script_Adult.ipynb` is an example notebook for training CTAB-GAN with Adult dataset. The dataset is alread under `Real_Datasets` folder. +The evaluation code is also provided. + +## For large dataset + +If your dataset has large number of column, you may encounter the problem that our currnet code cannot encode all of your data since CTAB-GAN will wrap the encoded data into an image-like format. What you can do is changing the line 341 and 348 in `model/synthesizer/ctabgan_synthesizer.py`. The number in the `slide` list +``` +sides = [4, 8, 16, 24, 32] +``` +is the side size of image. You can enlarge the list to [4, 8, 16, 24, 32, 64] or [4, 8, 16, 24, 32, 64, 128] for accepting larger dataset. + +## Bibtex + +To cite this paper, you could use this bibtex + +``` +@InProceedings{zhao21, + title = {CTAB-GAN: Effective Table Data Synthesizing}, + author = {Zhao, Zilong and Kunar, Aditya and Birke, Robert and Chen, Lydia Y.}, + booktitle = {Proceedings of The 13th Asian Conference on Machine Learning}, + pages = {97--112}, + year = {2021}, + editor = {Balasubramanian, Vineeth N. and Tsang, Ivor}, + volume = {157}, + series = {Proceedings of Machine Learning Research}, + month = {17--19 Nov}, + publisher = {PMLR}, + pdf = {https://proceedings.mlr.press/v157/zhao21a/zhao21a.pdf}, + url = {https://proceedings.mlr.press/v157/zhao21a.html} +} + + +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/columns.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/columns.json new file mode 100644 index 0000000000000000000000000000000000000000..5acd6bbcc72f8df4869e43a9e55e4dca4b32c616 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/columns.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c59fb02cb7f4a153aecb9e18dd81bbbb6946e55c3e6928c748811fcf5a85ad79 +size 3179 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..d12c1a3c05d486c698bca7012d45bf31bc50ffbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/ctabgan.py @@ -0,0 +1,58 @@ +""" +Generative model training algorithm based on the CTABGANSynthesiser + +""" +import pandas as pd +import time +from model.pipeline.data_preparation import DataPrep +from model.synthesizer.ctabgan_synthesizer import CTABGANSynthesizer + +import warnings + +warnings.filterwarnings("ignore") + +class CTABGAN(): + + def __init__(self, + df, + test_ratio = 0.20, + categorical_columns = [ 'workclass', 'education', 'marital-status', 'occupation', 'relationship', 'race', 'gender', 'native-country', 'income'], + log_columns = [], + mixed_columns= {'capital-loss':[0.0],'capital-gain':[0.0]}, + integer_columns = ['age', 'fnlwgt','capital-gain', 'capital-loss','hours-per-week'], + problem_type= {"Classification": 'income'}, + batch_size = 512, + class_dim = (256, 256, 256, 256), + lr = 2e-4, + epochs = 10, + device=None): + + self.__name__ = 'CTABGAN' + + self.synthesizer = CTABGANSynthesizer(lr = lr, epochs = epochs, batch_size = batch_size, class_dim = class_dim, device = device) + self.raw_df = df + print(self.raw_df.shape) + self.test_ratio = test_ratio + self.categorical_columns = categorical_columns + self.log_columns = log_columns + self.mixed_columns = mixed_columns + self.integer_columns = integer_columns + self.problem_type = problem_type + + def fit(self, no_train=False): + print("-"*100) + start_time = time.time() + self.data_prep = DataPrep(self.raw_df,self.categorical_columns,self.log_columns,self.mixed_columns,self.integer_columns,self.problem_type,self.test_ratio) + self.synthesizer.fit(train_data=self.data_prep.df, categorical = self.data_prep.column_types["categorical"], + mixed = self.data_prep.column_types["mixed"],type=self.problem_type, no_train=no_train) + end_time = time.time() + print('Finished training in',end_time-start_time," seconds.") + print("-"*100) + + + def generate_samples(self, num_samples, seed=0): + + sample = self.synthesizer.sample(num_samples, seed) + sample_df = self.data_prep.inverse_prep(sample) + + return sample_df diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py new file mode 100644 index 0000000000000000000000000000000000000000..2cc965efb802eac7263640e94ffba0cbdfff8c7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/eval/evaluation.py @@ -0,0 +1,191 @@ +import numpy as np +import pandas as pd +from sklearn import metrics +from sklearn import model_selection +from sklearn.preprocessing import MinMaxScaler,StandardScaler +from sklearn.neural_network import MLPClassifier +from sklearn.linear_model import LogisticRegression +from sklearn import svm,tree +from sklearn.ensemble import RandomForestClassifier +from dython.nominal import compute_associations +from scipy.stats import wasserstein_distance +from scipy.spatial import distance +import warnings + +warnings.filterwarnings("ignore") + +def supervised_model_training(x_train, y_train, x_test, + y_test, model_name): + + if model_name == 'lr': + model = LogisticRegression(random_state=42,max_iter=500) + elif model_name == 'svm': + model = svm.SVC(random_state=42,probability=True) + elif model_name == 'dt': + model = tree.DecisionTreeClassifier(random_state=42) + elif model_name == 'rf': + model = RandomForestClassifier(random_state=42) + elif model_name == "mlp": + model = MLPClassifier(random_state=42,max_iter=100) + + model.fit(x_train, y_train) + pred = model.predict(x_test) + + if len(np.unique(y_train))>2: + predict = model.predict_proba(x_test) + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict,average="weighted",multi_class="ovr") + f1_score = metrics.precision_recall_fscore_support(y_test, pred,average="weighted")[2] + return [acc, auc,f1_score] + + else: + predict = model.predict_proba(x_test)[:,1] + acc = metrics.accuracy_score(y_test,pred)*100 + auc = metrics.roc_auc_score(y_test, predict) + f1_score = metrics.precision_recall_fscore_support(y_test,pred)[2].mean() + return [acc, auc,f1_score] + + +def get_utility_metrics(real_path,fake_paths,scaler="MinMax",classifiers=["lr","dt","rf","mlp"],test_ratio=.20): + + data_real = pd.read_csv(real_path).to_numpy() + data_dim = data_real.shape[1] + + data_real_y = data_real[:,-1] + data_real_X = data_real[:,:data_dim-1] + X_train_real, X_test_real, y_train_real, y_test_real = model_selection.train_test_split(data_real_X ,data_real_y, test_size=test_ratio, stratify=data_real_y,random_state=42) + + if scaler=="MinMax": + scaler_real = MinMaxScaler() + else: + scaler_real = StandardScaler() + + scaler_real.fit(X_train_real) + X_train_real_scaled = scaler_real.transform(X_train_real) + X_test_real_scaled = scaler_real.transform(X_test_real) + + all_real_results = [] + for classifier in classifiers: + real_results = supervised_model_training(X_train_real_scaled,y_train_real,X_test_real_scaled,y_test_real,classifier) + all_real_results.append(real_results) + + all_fake_results_avg = [] + + for fake_path in fake_paths: + data_fake = pd.read_csv(fake_path).to_numpy() + data_fake_y = data_fake[:,-1] + data_fake_X = data_fake[:,:data_dim-1] + X_train_fake, _ , y_train_fake, _ = model_selection.train_test_split(data_fake_X ,data_fake_y, test_size=test_ratio, stratify=data_fake_y,random_state=42) + + if scaler=="MinMax": + scaler_fake = MinMaxScaler() + else: + scaler_fake = StandardScaler() + + scaler_fake.fit(data_fake_X) + + X_train_fake_scaled = scaler_fake.transform(X_train_fake) + + all_fake_results = [] + for classifier in classifiers: + fake_results = supervised_model_training(X_train_fake_scaled,y_train_fake,X_test_real_scaled,y_test_real,classifier) + all_fake_results.append(fake_results) + + all_fake_results_avg.append(all_fake_results) + + diff_results = np.array(all_real_results)- np.array(all_fake_results_avg).mean(axis=0) + + return diff_results + +def stat_sim(real_path,fake_path,cat_cols=None): + + Stat_dict={} + + real = pd.read_csv(real_path) + fake = pd.read_csv(fake_path) + + really = real.copy() + fakey = fake.copy() + + real_corr = compute_associations(real, nominal_columns=cat_cols) + + fake_corr = compute_associations(fake, nominal_columns=cat_cols) + + corr_dist = np.linalg.norm(real_corr - fake_corr) + + cat_stat = [] + num_stat = [] + + for column in real.columns: + + if column in cat_cols: + real_pdf=(really[column].value_counts()/really[column].value_counts().sum()) + fake_pdf=(fakey[column].value_counts()/fakey[column].value_counts().sum()) + categories = (fakey[column].value_counts()/fakey[column].value_counts().sum()).keys().tolist() + sorted_categories = sorted(categories) + + real_pdf_values = [] + fake_pdf_values = [] + + for i in sorted_categories: + real_pdf_values.append(real_pdf[i]) + fake_pdf_values.append(fake_pdf[i]) + + if len(real_pdf)!=len(fake_pdf): + zero_cats = set(really[column].value_counts().keys())-set(fakey[column].value_counts().keys()) + for z in zero_cats: + real_pdf_values.append(real_pdf[z]) + fake_pdf_values.append(0) + Stat_dict[column]=(distance.jensenshannon(real_pdf_values,fake_pdf_values, 2.0)) + cat_stat.append(Stat_dict[column]) + else: + scaler = MinMaxScaler() + scaler.fit(real[column].values.reshape(-1,1)) + l1 = scaler.transform(real[column].values.reshape(-1,1)).flatten() + l2 = scaler.transform(fake[column].values.reshape(-1,1)).flatten() + Stat_dict[column]= (wasserstein_distance(l1,l2)) + num_stat.append(Stat_dict[column]) + + return [np.mean(num_stat),np.mean(cat_stat),corr_dist] + +def privacy_metrics(real_path,fake_path,data_percent=15): + + real = pd.read_csv(real_path).drop_duplicates(keep=False) + fake = pd.read_csv(fake_path).drop_duplicates(keep=False) + + real_refined = real.sample(n=int(len(real)*(.01*data_percent)), random_state=42).to_numpy() + fake_refined = fake.sample(n=int(len(fake)*(.01*data_percent)), random_state=42).to_numpy() + + scalerR = StandardScaler() + scalerR.fit(real_refined) + scalerF = StandardScaler() + scalerF.fit(fake_refined) + df_real_scaled = scalerR.transform(real_refined) + df_fake_scaled = scalerF.transform(fake_refined) + + dist_rf = metrics.pairwise_distances(df_real_scaled, Y=df_fake_scaled, metric='minkowski', n_jobs=-1) + dist_rr = metrics.pairwise_distances(df_real_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + dist_ff = metrics.pairwise_distances(df_fake_scaled, Y=None, metric='minkowski', n_jobs=-1) + rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + fifth_perc_rr = np.percentile(min_dist_rr,5) + min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + fifth_perc_ff = np.percentile(min_dist_ff,5) + + return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py new file mode 100644 index 0000000000000000000000000000000000000000..dec2dc9715af03ecabf6efb3cff333588e5aa25c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/pipeline/data_preparation.py @@ -0,0 +1,114 @@ +import numpy as np +import pandas as pd +from sklearn import preprocessing +from sklearn import model_selection + +class DataPrep(object): + + def __init__(self, raw_df: pd.DataFrame, categorical: list, log:list, mixed:dict, integer:list, type:dict, test_ratio:float): + + + self.categorical_columns = categorical + self.log_columns = log + self.mixed_columns = mixed + self.integer_columns = integer + self.column_types = dict() + self.column_types["categorical"] = [] + self.column_types["mixed"] = {} + self.lower_bounds = {} + self.label_encoder_list = [] + + + target_col = list(type.values())[0] + y_real = raw_df[target_col] + X_real = raw_df.drop(columns=[target_col]) + # X_train_real, _, y_train_real, _ = model_selection.train_test_split(X_real ,y_real, test_size=test_ratio, stratify=y_real,random_state=42) + X_train_real, y_train_real = X_real, y_real + X_train_real[target_col]= y_train_real + + self.df = X_train_real + + self.df = self.df.replace(r' ', np.nan) + self.df = self.df.fillna('empty') + + all_columns= set(self.df.columns) + irrelevant_missing_columns = set(self.categorical_columns) + relevant_missing_columns = list(all_columns - irrelevant_missing_columns) + + for i in relevant_missing_columns: + if i in self.log_columns: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + elif i in list(self.mixed_columns.keys()): + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x ) + self.mixed_columns[i].append(-9999999) + else: + if "empty" in list(self.df[i].values): + self.df[i] = self.df[i].apply(lambda x: -9999999 if x=="empty" else x) + self.mixed_columns[i] = [-9999999] + + if self.log_columns: + for log_column in self.log_columns: + valid_indices = [] + for idx,val in enumerate(self.df[log_column].values): + if val!=-9999999: + valid_indices.append(idx) + eps = 1 + lower = np.min(self.df[log_column].iloc[valid_indices].values) + self.lower_bounds[log_column] = lower + if lower>0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x) if x!=-9999999 else -9999999) + elif lower == 0: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x+eps) if x!=-9999999 else -9999999) + else: + self.df[log_column] = self.df[log_column].apply(lambda x: np.log(x-lower+eps) if x!=-9999999 else -9999999) + + for column_index, column in enumerate(self.df.columns): + if column in self.categorical_columns: + label_encoder = preprocessing.LabelEncoder() + self.df[column] = self.df[column].astype(str) + label_encoder.fit(self.df[column]) + current_label_encoder = dict() + current_label_encoder['column'] = column + current_label_encoder['label_encoder'] = label_encoder + transformed_column = label_encoder.transform(self.df[column]) + self.df[column] = transformed_column + self.label_encoder_list.append(current_label_encoder) + self.column_types["categorical"].append(column_index) + + elif column in self.mixed_columns: + self.column_types["mixed"][column_index] = self.mixed_columns[column] + + super().__init__() + + def inverse_prep(self, data, eps=1): + + df_sample = pd.DataFrame(data,columns=self.df.columns) + + for i in range(len(self.label_encoder_list)): + le = self.label_encoder_list[i]["label_encoder"] + df_sample[self.label_encoder_list[i]["column"]] = df_sample[self.label_encoder_list[i]["column"]].astype(int) + df_sample[self.label_encoder_list[i]["column"]] = le.inverse_transform(df_sample[self.label_encoder_list[i]["column"]]) + + if self.log_columns: + for i in df_sample: + if i in self.log_columns: + lower_bound = self.lower_bounds[i] + if lower_bound>0: + df_sample[i].apply(lambda x: np.exp(x)) + elif lower_bound==0: + df_sample[i] = df_sample[i].apply(lambda x: np.ceil(np.exp(x)-eps) if (np.exp(x)-eps) < 0 else (np.exp(x)-eps)) + else: + df_sample[i] = df_sample[i].apply(lambda x: np.exp(x)-eps+lower_bound) + + if self.integer_columns: + for column in self.integer_columns: + df_sample[column]= (np.round(df_sample[column].values)) + df_sample[column] = df_sample[column].astype(int) + + df_sample.replace(-9999999, np.nan,inplace=True) + df_sample.replace('empty', np.nan,inplace=True) + + return df_sample diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py new file mode 100644 index 0000000000000000000000000000000000000000..7e4dd5cc2ecfb7c730b8cdab498c3cba332a318f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/ctabgan_synthesizer.py @@ -0,0 +1,526 @@ +import numpy as np +import pandas as pd +import torch +import torch.utils.data +import torch.optim as optim +from torch.optim import Adam +from torch.nn import functional as F +from torch.nn import (Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, +Conv2d, ConvTranspose2d, BatchNorm2d, Sigmoid, init, BCELoss, CrossEntropyLoss,SmoothL1Loss) +from model.synthesizer.transformer import ImageTransformer,DataTransformer +from tqdm import tqdm + + +class Classifier(Module): + def __init__(self,input_dim, dis_dims,st_ed): + super(Classifier,self).__init__() + dim = input_dim-(st_ed[1]-st_ed[0]) + seq = [] + self.str_end = st_ed + for item in list(dis_dims): + seq += [ + Linear(dim, item), + LeakyReLU(0.2), + Dropout(0.5) + ] + dim = item + + if (st_ed[1]-st_ed[0])==1: + seq += [Linear(dim, 1)] + + elif (st_ed[1]-st_ed[0])==2: + seq += [Linear(dim, 1),Sigmoid()] + else: + seq += [Linear(dim,(st_ed[1]-st_ed[0]))] + + self.seq = Sequential(*seq) + + def forward(self, input): + + label=None + + if (self.str_end[1]-self.str_end[0])==1: + label = input[:, self.str_end[0]:self.str_end[1]] + else: + label = torch.argmax(input[:, self.str_end[0]:self.str_end[1]], axis=-1) + + new_imp = torch.cat((input[:,:self.str_end[0]],input[:,self.str_end[1]:]),1) + + if ((self.str_end[1]-self.str_end[0])==2) | ((self.str_end[1]-self.str_end[0])==1): + return self.seq(new_imp).view(-1), label + else: + return self.seq(new_imp), label + +def apply_activate(data, output_info): + data_t = [] + st = 0 + for item in output_info: + if item[1] == 'tanh': + ed = st + item[0] + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif item[1] == 'softmax': + ed = st + item[0] + data_t.append(F.gumbel_softmax(data[:, st:ed], tau=0.2)) + st = ed + return torch.cat(data_t, dim=1) + +def get_st_ed(target_col_index,output_info): + st = 0 + c= 0 + tc= 0 + for item in output_info: + if c==target_col_index: + break + if item[1]=='tanh': + st += item[0] + elif item[1] == 'softmax': + st += item[0] + c+=1 + tc+=1 + ed= st+output_info[tc][0] + return (st,ed) + +def random_choice_prob_index_sampling(probs,col_idx): + option_list = [] + for i in col_idx: + pp = probs[i] + option_list.append(np.random.choice(np.arange(len(probs[i])), p=pp)) + + return np.array(option_list).reshape(col_idx.shape) + +def random_choice_prob_index(a, axis=1): + r = np.expand_dims(np.random.rand(a.shape[1 - axis]), axis=axis) + return (a.cumsum(axis=axis) > r).argmax(axis=axis) + +def maximum_interval(output_info): + max_interval = 0 + for item in output_info: + max_interval = max(max_interval, item[0]) + return max_interval + +class Cond(object): + def __init__(self, data, output_info): + + self.model = [] + st = 0 + counter = 0 + for item in output_info: + + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + counter += 1 + self.model.append(np.argmax(data[:, st:ed], axis=-1)) + st = ed + + self.interval = [] + self.n_col = 0 + self.n_opt = 0 + st = 0 + self.p = np.zeros((counter, maximum_interval(output_info))) + self.p_sampling = [] + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = np.sum(data[:, st:ed], axis=0) + tmp_sampling = np.sum(data[:, st:ed], axis=0) + tmp = np.log(tmp + 1) + tmp = tmp / np.sum(tmp) + tmp_sampling = tmp_sampling / np.sum(tmp_sampling) + self.p_sampling.append(tmp_sampling) + self.p[self.n_col, :item[0]] = tmp + self.interval.append((self.n_opt, item[0])) + self.n_opt += item[0] + self.n_col += 1 + st = ed + + self.interval = np.asarray(self.interval) + + def sample_train(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + mask = np.zeros((batch, self.n_col), dtype='float32') + mask[np.arange(batch), idx] = 1 + opt1prime = random_choice_prob_index(self.p[idx]) + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec, mask, idx, opt1prime + + def sample(self, batch): + if self.n_col == 0: + return None + batch = batch + + idx = np.random.choice(np.arange(self.n_col), batch) + + vec = np.zeros((batch, self.n_opt), dtype='float32') + opt1prime = random_choice_prob_index_sampling(self.p_sampling,idx) + + for i in np.arange(batch): + vec[i, self.interval[idx[i], 0] + opt1prime[i]] = 1 + + return vec + +def cond_loss(data, output_info, c, m): + loss = [] + st = 0 + st_c = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + + elif item[1] == 'softmax': + ed = st + item[0] + ed_c = st_c + item[0] + tmp = F.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none') + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) + return (loss * m).sum() / data.size()[0] + +class Sampler(object): + def __init__(self, data, output_info): + super(Sampler, self).__init__() + self.data = data + self.model = [] + self.n = len(data) + st = 0 + for item in output_info: + if item[1] == 'tanh': + st += item[0] + continue + elif item[1] == 'softmax': + ed = st + item[0] + tmp = [] + for j in range(item[0]): + tmp.append(np.nonzero(data[:, st + j])[0]) + self.model.append(tmp) + st = ed + + def sample(self, n, col, opt): + if col is None: + idx = np.random.choice(np.arange(self.n), n) + return self.data[idx] + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self.model[c][o])) + return self.data[idx] + +class Discriminator(Module): + def __init__(self, side, layers): + super(Discriminator, self).__init__() + self.side = side + info = len(layers)-2 + self.seq = Sequential(*layers) + self.seq_info = Sequential(*layers[:info]) + + def forward(self, input): + return (self.seq(input)), self.seq_info(input) + +class Generator(Module): + def __init__(self, side, layers): + super(Generator, self).__init__() + self.side = side + self.seq = Sequential(*layers) + + def forward(self, input_): + return self.seq(input_) + +def determine_layers_disc(side, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_D = [] + for prev, curr in zip(layer_dims, layer_dims[1:]): + layers_D += [ + Conv2d(prev[0], curr[0], 4, 2, 1, bias=False), + BatchNorm2d(curr[0]), + LeakyReLU(0.2, inplace=True) + ] + print() + layers_D += [ + + Conv2d(layer_dims[-1][0], 1, layer_dims[-1][1], 1, 0), + Sigmoid() + ] + + return layers_D + +def determine_layers_gen(side, random_dim, num_channels): + assert side >= 4 and side <= 32 + + layer_dims = [(1, side), (num_channels, side // 2)] + + while layer_dims[-1][1] > 3 and len(layer_dims) < 4: + layer_dims.append((layer_dims[-1][0] * 2, layer_dims[-1][1] // 2)) + + layers_G = [ + ConvTranspose2d( + random_dim, layer_dims[-1][0], layer_dims[-1][1], 1, 0, output_padding=0, bias=False) + ] + + for prev, curr in zip(reversed(layer_dims), reversed(layer_dims[:-1])): + layers_G += [ + BatchNorm2d(prev[0]), + ReLU(True), + ConvTranspose2d(prev[0], curr[0], 4, 2, 1, output_padding=0, bias=True) + ] + return layers_G + + +def weights_init(m): + classname = m.__class__.__name__ + + if classname.find('Conv') != -1: + init.normal_(m.weight.data, 0.0, 0.02) + + elif classname.find('BatchNorm') != -1: + init.normal_(m.weight.data, 1.0, 0.02) + init.constant_(m.bias.data, 0) + +class CTABGANSynthesizer: + def __init__(self, + lr=2e-4, + class_dim=(256, 256, 256, 256), + random_dim=128, + num_channels=64, + l2scale=1e-5, + batch_size=1024, + epochs=1, + device=torch.device("cpu")): + + + self.random_dim = random_dim + self.class_dim = class_dim + self.num_channels = num_channels + self.dside = None + self.gside = None + self.l2scale = l2scale + self.lr = lr + self.batch_size = batch_size + self.epochs = epochs + self.device = device + + def fit(self, train_data=pd.DataFrame, categorical=[], mixed={}, type={}, no_train=False): + print("Fit started.") + problem_type = None + target_index=None + if type: + problem_type = list(type.keys())[0] + if problem_type: + target_index = train_data.columns.get_loc(type[problem_type]) + + self.transformer = DataTransformer(train_data=train_data, categorical_list=categorical, mixed_dict=mixed) + self.transformer.fit() + + train_data = self.transformer.transform(train_data.values) + + data_sampler = Sampler(train_data, self.transformer.output_info) + data_dim = self.transformer.output_dim + self.cond_generator = Cond(train_data, self.transformer.output_info) + + sides = [4, 8, 16, 24, 32] + col_size_d = data_dim + self.cond_generator.n_opt + for i in sides: + if i * i >= col_size_d: + self.dside = i + break + + sides = [4, 8, 16, 24, 32] + col_size_g = data_dim + for i in sides: + if i * i >= col_size_g: + self.gside = i + break + + layers_G = determine_layers_gen(self.gside, self.random_dim+self.cond_generator.n_opt, self.num_channels) + layers_D = determine_layers_disc(self.dside, self.num_channels) + + self.generator = Generator(self.gside, layers_G).to(self.device) + discriminator = Discriminator(self.dside, layers_D).to(self.device) + optimizer_params = dict(lr=self.lr, betas=(0.5, 0.9), eps=1e-3, weight_decay=self.l2scale) + optimizerG = Adam(self.generator.parameters(), **optimizer_params) + optimizerD = Adam(discriminator.parameters(), **optimizer_params) + + st_ed = None + classifier=None + optimizerC= None + if target_index != None: + st_ed= get_st_ed(target_index,self.transformer.output_info) + classifier = Classifier(data_dim,self.class_dim,st_ed).to(self.device) + optimizerC = optim.Adam(classifier.parameters(),**optimizer_params) + + + self.generator.apply(weights_init) + discriminator.apply(weights_init) + + self.Gtransformer = ImageTransformer(self.gside) + self.Dtransformer = ImageTransformer(self.dside) + + + if no_train: return + + print("Training started.") + for i in range(self.epochs): + # for _ in range(steps_per_epoch): + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + perm = np.arange(self.batch_size) + np.random.shuffle(perm) + real = data_sampler.sample(self.batch_size, col[perm], opt[perm]) + c_perm = c[perm] + + real = torch.from_numpy(real.astype('float32')).to(self.device) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + real_cat = torch.cat([real, c_perm], dim=1) + + real_cat_d = self.Dtransformer.transform(real_cat) + fake_cat_d = self.Dtransformer.transform(fake_cat) + + optimizerD.zero_grad() + y_real,_ = discriminator(real_cat_d) + y_fake,_ = discriminator(fake_cat_d) + loss_d = (-(torch.log(y_real + 1e-4).mean()) - (torch.log(1. - y_fake + 1e-4).mean())) + loss_d.backward() + optimizerD.step() + + noisez = torch.randn(self.batch_size, self.random_dim, device=self.device) + + condvec = self.cond_generator.sample_train(self.batch_size) + + c, m, col, opt = condvec + c = torch.from_numpy(c).to(self.device) + m = torch.from_numpy(m).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(self.batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + optimizerG.zero_grad() + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket, self.transformer.output_info) + + fake_cat = torch.cat([fakeact, c], dim=1) + fake_cat = self.Dtransformer.transform(fake_cat) + + y_fake,info_fake = discriminator(fake_cat) + + cross_entropy = cond_loss(faket, self.transformer.output_info, c, m) + + _,info_real = discriminator(real_cat_d) + + g = -(torch.log(y_fake + 1e-4).mean()) + cross_entropy + g.backward(retain_graph=True) + loss_mean = torch.norm(torch.mean(info_fake.view(self.batch_size,-1), dim=0) - torch.mean(info_real.view(self.batch_size,-1), dim=0), 1) + loss_std = torch.norm(torch.std(info_fake.view(self.batch_size,-1), dim=0) - torch.std(info_real.view(self.batch_size,-1), dim=0), 1) + loss_info = loss_mean + loss_std + loss_info.backward() + optimizerG.step() + + if (i + 1) % 500 == 0: + print(f"Step: {i}/{self.epochs} Loss: {loss_mean:.4f}") + + if problem_type: + + fake = self.generator(noisez) + + faket = self.Gtransformer.inverse_transform(fake) + + fakeact = apply_activate(faket, self.transformer.output_info) + + real_pre, real_label = classifier(real) + fake_pre, fake_label = classifier(fakeact) + + c_loss = CrossEntropyLoss() + + if (st_ed[1] - st_ed[0])==1: + c_loss= SmoothL1Loss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + real_label = torch.reshape(real_label,real_pre.size()) + fake_label = torch.reshape(fake_label,fake_pre.size()) + + + elif (st_ed[1] - st_ed[0])==2: + c_loss = BCELoss() + real_label = real_label.type_as(real_pre) + fake_label = fake_label.type_as(fake_pre) + + loss_cc = c_loss(real_pre, real_label) + loss_cg = c_loss(fake_pre, fake_label) + + optimizerG.zero_grad() + loss_cg.backward() + optimizerG.step() + + optimizerC.zero_grad() + loss_cc.backward() + optimizerC.step() + + @torch.no_grad() + def sample(self, n, seed=0): + + torch.manual_seed(seed) + torch.cuda.manual_seed(seed) + sample_batch_size = 8092 + self.generator.eval() + + output_info = self.transformer.output_info + steps = n // sample_batch_size + 1 + + data = [] + + for i in range(steps): + noisez = torch.randn(sample_batch_size, self.random_dim, device=self.device) + condvec = self.cond_generator.sample(sample_batch_size) + c = condvec + c = torch.from_numpy(c).to(self.device) + noisez = torch.cat([noisez, c], dim=1) + noisez = noisez.view(sample_batch_size,self.random_dim+self.cond_generator.n_opt,1,1) + + fake = self.generator(noisez) + faket = self.Gtransformer.inverse_transform(fake) + fakeact = apply_activate(faket,output_info) + # print(len(data)) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + result = self.transformer.inverse_transform(data) + + return result[0:n] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..18fc3c492a99c7f2455ebf2c2cddf09525333b92 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/model/synthesizer/transformer.py @@ -0,0 +1,363 @@ +import numpy as np +import pandas as pd +import torch +from sklearn.mixture import BayesianGaussianMixture + +class DataTransformer(): + + def __init__(self, train_data=pd.DataFrame, categorical_list=[], mixed_dict={}, n_clusters=10, eps=0.005): + self.meta = None + self.n_clusters = n_clusters + self.eps = eps + self.train_data = train_data + self.categorical_columns= categorical_list + self.mixed_columns= mixed_dict + + def get_metadata(self): + + meta = [] + + for index in range(self.train_data.shape[1]): + column = self.train_data.iloc[:,index] + if index in self.categorical_columns: + mapper = column.value_counts().index.tolist() + meta.append({ + "name": index, + "type": "categorical", + "size": len(mapper), + "i2s": mapper + }) + elif index in self.mixed_columns.keys(): + meta.append({ + "name": index, + "type": "mixed", + "min": column.min(), + "max": column.max(), + "modal": self.mixed_columns[index] + }) + else: + meta.append({ + "name": index, + "type": "continuous", + "min": column.min(), + "max": column.max(), + }) + + return meta + + def fit(self): + data = self.train_data.values + self.meta = self.get_metadata() + model = [] + self.ordering = [] + self.output_info = [] + self.output_dim = 0 + self.components = [] + self.filter_arr = [] + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + gm = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, + max_iter=100,n_init=1, random_state=42) + gm.fit(data[:, id_].reshape([-1, 1])) + mode_freq = (pd.Series(gm.predict(data[:, id_].reshape([-1, 1]))).value_counts().keys()) + model.append(gm) + old_comp = gm.weights_ > self.eps + comp = [] + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + self.components.append(comp) + self.output_info += [(1, 'tanh'), (np.sum(comp), 'softmax')] + self.output_dim += 1 + np.sum(comp) + + elif info['type'] == "mixed": + + gm1 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + gm2 = BayesianGaussianMixture(n_components=self.n_clusters, + weight_concentration_prior_type='dirichlet_process', + weight_concentration_prior=0.001, max_iter=100, + n_init=1,random_state=42) + + gm1.fit(data[:, id_].reshape([-1, 1])) + + filter_arr = [] + for element in data[:, id_]: + if element not in info['modal']: + filter_arr.append(True) + else: + filter_arr.append(False) + + gm2.fit(data[:, id_][filter_arr].reshape([-1, 1])) + mode_freq = (pd.Series(gm2.predict(data[:, id_][filter_arr].reshape([-1, 1]))).value_counts().keys()) + self.filter_arr.append(filter_arr) + model.append((gm1,gm2)) + + old_comp = gm2.weights_ > self.eps + + comp = [] + + for i in range(self.n_clusters): + if (i in (mode_freq)) & old_comp[i]: + comp.append(True) + else: + comp.append(False) + + self.components.append(comp) + + self.output_info += [(1, 'tanh'), (np.sum(comp) + len(info['modal']), 'softmax')] + self.output_dim += 1 + np.sum(comp) + len(info['modal']) + + else: + model.append(None) + self.components.append(None) + self.output_info += [(info['size'], 'softmax')] + self.output_dim += info['size'] + + self.model = model + + def transform(self, data, ispositive = False, positive_list = None): + values = [] + mixed_counter = 0 + for id_, info in enumerate(self.meta): + current = data[:, id_] + if info['type'] == "continuous": + current = current.reshape([-1, 1]) + means = self.model[id_].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_].predict_proba(current.reshape([-1, 1])) + n_opts = sum(self.components[id_]) + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(data), dtype='int') + for i in range(len(data)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + + re_ordered_phot = np.zeros_like(probs_onehot) + + col_sums = probs_onehot.sum(axis=0) + + + n = probs_onehot.shape[1] + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_phot[:,id] = probs_onehot[:,val] + + + values += [features, re_ordered_phot] + + elif info['type'] == "mixed": + + means_0 = self.model[id_][0].means_.reshape([-1]) + stds_0 = np.sqrt(self.model[id_][0].covariances_).reshape([-1]) + + zero_std_list = [] + means_needed = [] + stds_needed = [] + + for mode in info['modal']: + if mode!=-9999999: + dist = [] + for idx,val in enumerate(list(means_0.flatten())): + dist.append(abs(mode-val)) + index_min = np.argmin(np.array(dist)) + zero_std_list.append(index_min) + else: continue + + for idx in zero_std_list: + means_needed.append(means_0[idx]) + stds_needed.append(stds_0[idx]) + + + mode_vals = [] + + for i,j,k in zip(info['modal'],means_needed,stds_needed): + this_val = np.abs(i - j) / (4*k) + mode_vals.append(this_val) + + if -9999999 in info["modal"]: + mode_vals.append(0) + + current = current.reshape([-1, 1]) + filter_arr = self.filter_arr[mixed_counter] + current = current[filter_arr] + + means = self.model[id_][1].means_.reshape((1, self.n_clusters)) + stds = np.sqrt(self.model[id_][1].covariances_).reshape((1, self.n_clusters)) + features = np.empty(shape=(len(current),self.n_clusters)) + if ispositive == True: + if id_ in positive_list: + features = np.abs(current - means) / (4 * stds) + else: + features = (current - means) / (4 * stds) + + probs = self.model[id_][1].predict_proba(current.reshape([-1, 1])) + + n_opts = sum(self.components[id_]) # 8 + features = features[:, self.components[id_]] + probs = probs[:, self.components[id_]] + + opt_sel = np.zeros(len(current), dtype='int') + for i in range(len(current)): + pp = probs[i] + 1e-6 + pp = pp / sum(pp) + opt_sel[i] = np.random.choice(np.arange(n_opts), p=pp) + idx = np.arange((len(features))) + features = features[idx, opt_sel].reshape([-1, 1]) + features = np.clip(features, -.99, .99) + probs_onehot = np.zeros_like(probs) + probs_onehot[np.arange(len(probs)), opt_sel] = 1 + extra_bits = np.zeros([len(current), len(info['modal'])]) + temp_probs_onehot = np.concatenate([extra_bits,probs_onehot], axis = 1) + final = np.zeros([len(data), 1 + probs_onehot.shape[1] + len(info['modal'])]) + features_curser = 0 + for idx, val in enumerate(data[:, id_]): + if val in info['modal']: + category_ = list(map(info['modal'].index, [val]))[0] + final[idx, 0] = mode_vals[category_] + final[idx, (category_+1)] = 1 + + else: + final[idx, 0] = features[features_curser] + final[idx, (1+len(info['modal'])):] = temp_probs_onehot[features_curser][len(info['modal']):] + features_curser = features_curser + 1 + + just_onehot = final[:,1:] + re_ordered_jhot= np.zeros_like(just_onehot) + n = just_onehot.shape[1] + col_sums = just_onehot.sum(axis=0) + largest_indices = np.argsort(-1*col_sums)[:n] + self.ordering.append(largest_indices) + for id,val in enumerate(largest_indices): + re_ordered_jhot[:,id] = just_onehot[:,val] + final_features = final[:,0].reshape([-1, 1]) + values += [final_features, re_ordered_jhot] + mixed_counter = mixed_counter + 1 + + else: + self.ordering.append(None) + col_t = np.zeros([len(data), info['size']]) + idx = list(map(info['i2s'].index, current)) + col_t[np.arange(len(data)), idx] = 1 + values.append(col_t) + + return np.concatenate(values, axis=1) + + def inverse_transform(self, data): + data_t = np.zeros([len(data), len(self.meta)]) + st = 0 + for id_, info in enumerate(self.meta): + if info['type'] == "continuous": + u = data[:, st] + v = data[:, st + 1:st + 1 + np.sum(self.components[id_])] + order = self.ordering[id_] + v_re_ordered = np.zeros_like(v) + + for id,val in enumerate(order): + v_re_ordered[:,val] = v[:,id] + + v = v_re_ordered + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = v_t + st += 1 + np.sum(self.components[id_]) + means = self.model[id_].means_.reshape([-1]) + stds = np.sqrt(self.model[id_].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + std_t = stds[p_argmax] + mean_t = means[p_argmax] + tmp = u * 4 * std_t + mean_t + data_t[:, id_] = tmp + + elif info['type'] == "mixed": + + u = data[:, st] + full_v = data[:,(st+1):(st+1)+len(info['modal'])+np.sum(self.components[id_])] + order = self.ordering[id_] + full_v_re_ordered = np.zeros_like(full_v) + + for id,val in enumerate(order): + full_v_re_ordered[:,val] = full_v[:,id] + + full_v = full_v_re_ordered + mixed_v = full_v[:,:len(info['modal'])] + v = full_v[:,-np.sum(self.components[id_]):] + + u = np.clip(u, -1, 1) + v_t = np.ones((data.shape[0], self.n_clusters)) * -100 + v_t[:, self.components[id_]] = v + v = np.concatenate([mixed_v,v_t], axis=1) + + st += 1 + np.sum(self.components[id_]) + len(info['modal']) + means = self.model[id_][1].means_.reshape([-1]) + stds = np.sqrt(self.model[id_][1].covariances_).reshape([-1]) + p_argmax = np.argmax(v, axis=1) + + result = np.zeros_like(u) + + for idx in range(len(data)): + if p_argmax[idx] < len(info['modal']): + argmax_value = p_argmax[idx] + result[idx] = float(list(map(info['modal'].__getitem__, [argmax_value]))[0]) + else: + std_t = stds[(p_argmax[idx]-len(info['modal']))] + mean_t = means[(p_argmax[idx]-len(info['modal']))] + result[idx] = u[idx] * 4 * std_t + mean_t + + data_t[:, id_] = result + + else: + current = data[:, st:st + info['size']] + st += info['size'] + idx = np.argmax(current, axis=1) + data_t[:, id_] = list(map(info['i2s'].__getitem__, idx)) + + return data_t + +class ImageTransformer(): + + def __init__(self, side): + + self.height = side + + def transform(self, data): + + if self.height * self.height > len(data[0]): + + padding = torch.zeros((len(data), self.height * self.height - len(data[0]))).to(data.device) + data = torch.cat([data, padding], axis=1) + + return data.view(-1, 1, self.height, self.height) + + def inverse_transform(self, data): + + data = data.view(-1, self.height * self.height) + + return data + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..9ed3e80f4a226ec8e973f5f15db87540e4fa01a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/pipeline_ctabgan.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_ctabgan( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_ctabgan( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..1144dbbc7b9c35690b609f5717d766abd4ba9567 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/requirements.txt @@ -0,0 +1,6 @@ +numpy==1.21.0 +torch==1.9.1 +pandas==1.2.4 +sklearn==0.24.1 +dython==0.6.4.post1 +scipy==1.4.1 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..be74a48ec44624d341dda0f684780ac698ec3851 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/train_sample_ctabgan.py @@ -0,0 +1,108 @@ +import lib +import os +import numpy as np +import argparse +from pathlib import Path +from model.ctabgan import CTABGAN +import torch +import pickle + +def train_ctabgan( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = CTABGAN( + df = X, + test_ratio = 0.0, + **ctabgan_params, + **train_params, + device=device + ) + + synthesizer.fit() + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "ctabgan.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_ctabgan( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + ctabgan_params = lib.load_json("CTAB-GAN/columns.json")[real_data_path.name] + + cat_features = ctabgan_params["categorical_columns"] + # if synthesizer is None: + # synthesizer = load_ctabgan(X, ctabgan_params, train_params, parent_dir) + with open(parent_dir / "ctabgan.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.synthesizer.generator = synthesizer.synthesizer.generator.to(device) + gen_data = synthesizer.generate_samples(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1).values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + np.save(parent_dir / 'y_train', y.astype(float).astype(int)) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_ctabgan(args.parent_dir, args.real_data_path, change_val=True) + sample_ctabgan(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py new file mode 100644 index 0000000000000000000000000000000000000000..71e73f1edc23821ea1ea099a10095a6b1de032ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTAB-GAN/tune_ctabgan.py @@ -0,0 +1,150 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_ctabgan import train_ctabgan, sample_ctabgan +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 6, 8 + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [1000, 5000, 10000]) + # steps = trial.suggest_categorical('steps', [10]) + batch_size = 2 ** trial.suggest_int('batch_size', 9, 11) + random_dim = 2 ** trial.suggest_int('random_dim', 4, 7) + num_channels = 2 ** trial.suggest_int('num_channels', 4, 6) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + + train_params = { + "lr": lr, + "epochs": steps, + "class_dim": d_layers, + "batch_size": batch_size, + "random_dim": random_dim, + "num_channels": num_channels + } + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_ctabgan( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_ctabgan( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=35, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/ctabgan/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/ctabgan/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_ctabgan( + parent_dir=f"exp/{Path(real_data_path).name}/ctabgan/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "ctabgan", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig new file mode 100644 index 0000000000000000000000000000000000000000..8558c49851ee32e7577c83758bf92941054d2c5c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.editorconfig @@ -0,0 +1,24 @@ +# http://editorconfig.org + +root = true + +[*] +indent_style = space +indent_size = 4 +trim_trailing_whitespace = true +insert_final_newline = true +charset = utf-8 +end_of_line = lf + +[*.py] +max_line_length = 99 + +[*.bat] +indent_style = tab +end_of_line = crlf + +[LICENSE] +insert_final_newline = false + +[Makefile] +indent_style = tab diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS new file mode 100644 index 0000000000000000000000000000000000000000..e4db0356f3f62a8480ae07791b86c28adff16739 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/CODEOWNERS @@ -0,0 +1,2 @@ +# Global rule: +* @sdv-dev/core-contributors diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000000000000000000000000000000000000..16e0decde54dd915131ba85aa981029946dc53aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,33 @@ +--- +name: Bug report +about: Report an error that you found when using CTGAN +title: '' +labels: bug, pending review +assignees: '' + +--- + +### Environment Details + +Please indicate the following details about the environment in which you found the bug: + +* CTGAN version: +* Python version: +* Operating System: + +### Error Description + + + +### Steps to reproduce + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000000000000000000000000000000000000..54d7b6a17c3456c79fd59efaa5819d071e0101b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,24 @@ +--- +name: Feature request +about: Request a new feature that you would like to see implemented in CTGAN +title: '' +labels: new feature, pending review +assignees: '' + +--- + +### Problem Description + + + +### Expected behavior + + + +### Additional context + + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md new file mode 100644 index 0000000000000000000000000000000000000000..20aca671d77560c3c52bd7d00ae129ca2f160f8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/ISSUE_TEMPLATE/question.md @@ -0,0 +1,33 @@ +--- +name: Question +about: Doubts about CTGAN usage +title: '' +labels: question, pending review +assignees: '' + +--- + +### Environment details + +If you are already running CTGAN, please indicate the following details about the environment in +which you are running it: + +* CTGAN version: +* Python version: +* Operating System: + +### Problem description + + + +### What I already tried + + + +``` +Paste the command(s) you ran and the output. +If there was a crash, please include the traceback here. +``` diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml new file mode 100644 index 0000000000000000000000000000000000000000..fdc744eeec5f5a1a18ce12ab91a8796f1c25d9fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/integration.yml @@ -0,0 +1,31 @@ +name: Integration Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run integration tests + run: invoke integration diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml new file mode 100644 index 0000000000000000000000000000000000000000..07dde39e9f898c598379e9bd39dac1304be9456e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/lint.yml @@ -0,0 +1,21 @@ +name: Style Checks + +on: + - push + - pull_request + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - name: Set up Python 3.8 + uses: actions/setup-python@v2 + with: + python-version: 3.8 + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[dev] + - name: Run lint checks + run: invoke lint diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml new file mode 100644 index 0000000000000000000000000000000000000000..1989c957943adecaf4e9fb851971e961c9188b3d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/minimum.yml @@ -0,0 +1,31 @@ +name: Unit Tests Minimum Versions + +on: + - push + - pull_request + +jobs: + minimum: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch==1.8' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision==0.9.0' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Test with minimum versions + run: invoke minimum diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml new file mode 100644 index 0000000000000000000000000000000000000000..5a623b543050f215dce8a6ba0d9aeecf2875b779 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/readme.yml @@ -0,0 +1,25 @@ +name: Test README + +on: + - push + - pull_request + +jobs: + readme: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15] # skip windows bc rundoc fails + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke rundoc . + - name: Run the README.md + run: invoke readme diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml new file mode 100644 index 0000000000000000000000000000000000000000..6a63f0e006e1c8d3b635c441661c5ceb0282066b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.github/workflows/unit.yml @@ -0,0 +1,34 @@ +name: Unit Tests + +on: + - push + - pull_request + +jobs: + unit: + runs-on: ${{ matrix.os }} + strategy: + matrix: + python-version: [3.6, 3.7, 3.8, 3.9] + os: [ubuntu-latest, macos-10.15, windows-latest] + steps: + - uses: actions/checkout@v1 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - if: matrix.os == 'windows-latest' + name: Install dependencies - Windows + run: | + python -m pip install --upgrade pip + python -m pip install 'torch>=1.8,<2' -f https://download.pytorch.org/whl/cpu/torch/ + python -m pip install 'torchvision>=0.9.0,<1' -f https://download.pytorch.org/whl/cpu/torchvision/ + - name: Install dependencies + run: | + python -m pip install --upgrade pip + python -m pip install invoke .[test] + - name: Run unit tests + run: invoke unit + - if: matrix.os == 'ubuntu-latest' && matrix.python-version == 3.8 + name: Upload codecov report + uses: codecov/codecov-action@v2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.gitignore b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..1609a70e22920b86a4a717e9c9aae645184b0831 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.gitignore @@ -0,0 +1,107 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +.hypothesis/ +.pytest_cache/ +tests/readme_test/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ +docs/api/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# SageMath parsed files +*.sage.py + +# dotenv +.env + +# virtualenv +.venv +venv/ +ENV/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ + +# Vim +.*.swp diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml new file mode 100644 index 0000000000000000000000000000000000000000..ecfa96045b11d59a33951d94e2358ea6b30646b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/.travis.yml @@ -0,0 +1,15 @@ +# Config file for automatic testing at travis-ci.org +dist: bionic +language: python +python: + - 3.8 + - 3.7 + - 3.6 + +# Command to install dependencies +install: pip install -U tox-travis codecov + +after_success: codecov + +# Command to run tests +script: tox diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst new file mode 100644 index 0000000000000000000000000000000000000000..1ea30d0908426597369b5193f52f1ec2b6ff4826 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/AUTHORS.rst @@ -0,0 +1,13 @@ +Credits +======= + +Research and Development Lead +----------------------------- + +* Lei Xu + +Contributors +------------ + +* Carles Sala +* Kevin Kuo diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst new file mode 100644 index 0000000000000000000000000000000000000000..a21b70abaec7c75cf14208a5438d0af3dfac03b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/CONTRIBUTING.rst @@ -0,0 +1,237 @@ +.. highlight:: shell + +============ +Contributing +============ + +Contributions are welcome, and they are greatly appreciated! Every little bit +helps, and credit will always be given. + +You can contribute in many ways: + +Types of Contributions +---------------------- + +Report Bugs +~~~~~~~~~~~ + +Report bugs at the `GitHub Issues page`_. + +If you are reporting a bug, please include: + +* Your operating system name and version. +* Any details about your local setup that might be helpful in troubleshooting. +* Detailed steps to reproduce the bug. + +Fix Bugs +~~~~~~~~ + +Look through the GitHub issues for bugs. Anything tagged with "bug" and "help +wanted" is open to whoever wants to implement it. + +Implement Features +~~~~~~~~~~~~~~~~~~ + +Look through the GitHub issues for features. Anything tagged with "enhancement" +and "help wanted" is open to whoever wants to implement it. + +Write Documentation +~~~~~~~~~~~~~~~~~~~ + +CTGAN could always use more documentation, whether as part of the +official CTGAN docs, in docstrings, or even on the web in blog posts, +articles, and such. + +Submit Feedback +~~~~~~~~~~~~~~~ + +The best way to send feedback is to file an issue at the `GitHub Issues page`_. + +If you are proposing a feature: + +* Explain in detail how it would work. +* Keep the scope as narrow as possible, to make it easier to implement. +* Remember that this is a volunteer-driven project, and that contributions + are welcome :) + +Get Started! +------------ + +Ready to contribute? Here's how to set up `CTGAN` for local development. + +1. Fork the `CTGAN` repo on GitHub. +2. Clone your fork locally:: + + $ git clone git@github.com:your_name_here/CTGAN.git + +3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, + this is how you set up your fork for local development:: + + $ mkvirtualenv CTGAN + $ cd CTGAN/ + $ make install-develop + +4. Create a branch for local development:: + + $ git checkout -b name-of-your-bugfix-or-feature + + Try to use the naming scheme of prefixing your branch with ``gh-X`` where X is + the associated issue, such as ``gh-3-fix-foo-bug``. And if you are not + developing on your own fork, further prefix the branch with your GitHub + username, like ``githubusername/gh-3-fix-foo-bug``. + + Now you can make your changes locally. + +5. While hacking your changes, make sure to cover all your developments with the required + unit tests, and that none of the old tests fail as a consequence of your changes. + For this, make sure to run the tests suite and check the code coverage:: + + $ make lint # Check code styling + $ make test # Run the tests + $ make coverage # Get the coverage report + +6. When you're done making changes, check that your changes pass all the styling checks and + tests, including other Python supported versions, using:: + + $ make test-all + +7. Make also sure to include the necessary documentation in the code as docstrings following + the `Google docstrings style`_. + If you want to view how your documentation will look like when it is published, you can + generate and view the docs with this command:: + + $ make view-docs + +8. Commit your changes and push your branch to GitHub:: + + $ git add . + $ git commit -m "Your detailed description of your changes." + $ git push origin name-of-your-bugfix-or-feature + +9. Submit a pull request through the GitHub website. + +Pull Request Guidelines +----------------------- + +Before you submit a pull request, check that it meets these guidelines: + +1. It resolves an open GitHub Issue and contains its reference in the title or + the comment. If there is no associated issue, feel free to create one. +2. Whenever possible, it resolves only **one** issue. If your PR resolves more than + one issue, try to split it in more than one pull request. +3. The pull request should include unit tests that cover all the changed code +4. If the pull request adds functionality, the docs should be updated. Put + your new functionality into a function with a docstring, and add the + feature to the documentation in an appropriate place. +5. The pull request should work for all the supported Python versions. Check the `Travis Build + Status page`_ and make sure that all the checks pass. + +Unit Testing Guidelines +----------------------- + +All the Unit Tests should comply with the following requirements: + +1. Unit Tests should be based only in unittest and pytest modules. + +2. The tests that cover a module called ``ctgan/path/to/a_module.py`` + should be implemented in a separated module called + ``tests/ctgan/path/to/test_a_module.py``. + Note that the module name has the ``test_`` prefix and is located in a path similar + to the one of the tested module, just inside the ``tests`` folder. + +3. Each method of the tested module should have at least one associated test method, and + each test method should cover only **one** use case or scenario. + +4. Test case methods should start with the ``test_`` prefix and have descriptive names + that indicate which scenario they cover. + Names such as ``test_some_methed_input_none``, ``test_some_method_value_error`` or + ``test_some_method_timeout`` are right, but names like ``test_some_method_1``, + ``some_method`` or ``test_error`` are not. + +5. Each test should validate only what the code of the method being tested does, and not + cover the behavior of any third party package or tool being used, which is assumed to + work properly as far as it is being passed the right values. + +6. Any third party tool that may have any kind of random behavior, such as some Machine + Learning models, databases or Web APIs, will be mocked using the ``mock`` library, and + the only thing that will be tested is that our code passes the right values to them. + +7. Unit tests should not use anything from outside the test and the code being tested. This + includes not reading or writing to any file system or database, which will be properly + mocked. + +Tips +---- + +To run a subset of tests:: + + $ python -m pytest tests.test_ctgan + $ python -m pytest -k 'foo' + +Release Workflow +---------------- + +The process of releasing a new version involves several steps combining both ``git`` and +``bumpversion`` which, briefly: + +1. Merge what is in ``master`` branch into ``stable`` branch. +2. Update the version in ``setup.cfg``, ``ctgan/__init__.py`` and + ``HISTORY.md`` files. +3. Create a new git tag pointing at the corresponding commit in ``stable`` branch. +4. Merge the new commit from ``stable`` into ``master``. +5. Update the version in ``setup.cfg`` and ``ctgan/__init__.py`` + to open the next development iteration. + +.. note:: Before starting the process, make sure that ``HISTORY.md`` has been updated with a new + entry that explains the changes that will be included in the new version. + Normally this is just a list of the Pull Requests that have been merged to master + since the last release. + +Once this is done, run of the following commands: + +1. If you are releasing a patch version:: + + make release + +2. If you are releasing a minor version:: + + make release-minor + +3. If you are releasing a major version:: + + make release-major + +Release Candidates +~~~~~~~~~~~~~~~~~~ + +Sometimes it is necessary or convenient to upload a release candidate to PyPi as a pre-release, +in order to make some of the new features available for testing on other projects before they +are included in an actual full-blown release. + +In order to perform such an action, you can execute:: + + make release-candidate + +This will perform the following actions: + +1. Build and upload the current version to PyPi as a pre-release, with the format ``X.Y.Z.devN`` + +2. Bump the current version to the next release candidate, ``X.Y.Z.dev(N+1)`` + +After this is done, the new pre-release can be installed by including the ``dev`` section in the +dependency specification, either in ``setup.py``:: + + install_requires = [ + ... + 'ctgan>=X.Y.Z.dev', + ... + ] + +or in command line:: + + pip install 'ctgan>=X.Y.Z.dev' + + +.. _GitHub issues page: https://github.com/sdv-dev/CTGAN/issues +.. _Travis Build Status page: https://travis-ci.org/sdv-dev/CTGAN/pull_requests +.. _Google docstrings style: https://google.github.io/styleguide/pyguide.html?showone=Comments#Comments diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md new file mode 100644 index 0000000000000000000000000000000000000000..df2595e5dbbc2a9c44d571d9ae63bf86670e6cf2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/HISTORY.md @@ -0,0 +1,147 @@ +# History + +## v0.5.1 - 2022-02-25 + +This release fixes a bug with the decoder instantiation, and also allows users to set a random state for the model +fitting and sampling. + +### Issues closed + +* Update self.decoder with correct variable name - Issue [#203](https://github.com/sdv-dev/CTGAN/issues/203) by @tejuafonja +* Add random state - Issue [#204](https://github.com/sdv-dev/CTGAN/issues/204) by @katxiao + +## v0.5.0 - 2021-11-18 + +This release adds support for Python 3.9 and updates dependencies to ensure compatibility with the +rest of the SDV ecosystem, and upgrades to the latests [RDT](https://github.com/sdv-dev/RDT/releases/tag/v0.6.1) +release. + +### Issues closed + +* Add support for Python 3.9 - Issue [#177](https://github.com/sdv-dev/CTGAN/issues/177) by @pvk-developer +* Add pip check to CI workflows - Issue [#174](https://github.com/sdv-dev/CTGAN/issues/174) by @pvk-developer +* Typo in `CTGAN` code - Issue [#158](https://github.com/sdv-dev/CTGAN/issues/158) by @ori-katz100 and @fealho + +## v0.4.3 - 2021-07-12 + +Dependency upgrades to ensure compatibility with the rest of the SDV ecosystem. + +## v0.4.2 - 2021-04-27 + +In this release, the way in which the loss function of the TVAE model was computed has been fixed. +In addition, the default value of the `discriminator_decay` has been changed to a more optimal +value. Also some improvements to the tests were added. + +### Issues closed + +* `TVAE`: loss function - Issue [#143](https://github.com/sdv-dev/CTGAN/issues/143) by @fealho and @DingfanChen +* Set `discriminator_decay` to `1e-6` - Pull request [#145](https://github.com/sdv-dev/CTGAN/pull/145/) by @fealho +* Adds unit tests - Pull requests [#140](https://github.com/sdv-dev/CTGAN/pull/140) by @fealho + +## v0.4.1 - 2021-03-30 + +This release exposes all the hyperparameters which the user may find useful for both `CTGAN` +and `TVAE`. Also `TVAE` can now be fitted on datasets that are shorter than the batch +size and drops the last batch only if the data size is not divisible by the batch size. + +### Issues closed + +* `TVAE`: Adapt `batch_size` to data size - Issue [#135](https://github.com/sdv-dev/CTGAN/issues/135) by @fealho and @csala +* `ValueError` from `validate_discre_columns` with `uniqueCombinationConstraint` - Issue [133](https://github.com/sdv-dev/CTGAN/issues/133) by @fealho and @MLjungg + +## v0.4.0 - 2021-02-24 + +Maintenance relese to upgrade dependencies to ensure compatibility with the rest +of the SDV libraries. + +Also add a validation on the CTGAN `condition_column` and `condition_value` inputs. + +### Improvements + +* Validate condition_column and condition_value - Issue [#124](https://github.com/sdv-dev/CTGAN/issues/124) by @fealho + +## v0.3.1 - 2021-01-27 + +### Improvements + +* Check discrete_columns valid before fitting - [Issue #35](https://github.com/sdv-dev/CTGAN/issues/35) by @fealho + +## Bugs fixed + +* ValueError: max() arg is an empty sequence - [Issue #115](https://github.com/sdv-dev/CTGAN/issues/115) by @fealho + +## v0.3.0 - 2020-12-18 + +In this release we add a new TVAE model which was presented in the original CTGAN paper. +It also exposes more hyperparameters and moves epochs and log_frequency from fit to the constructor. + +A new verbose argument has been added to optionally disable unnecessary printing, and a new hyperparameter +called `discriminator_steps` has been added to CTGAN to control the number of optimization steps performed +in the discriminator for each generator epoch. + +The code has also been reorganized and cleaned up for better readability and interpretability. + +Special thanks to @Baukebrenninkmeijer @fealho @leix28 @csala for the contributions! + +### Improvements + +* Add TVAE - [Issue #111](https://github.com/sdv-dev/CTGAN/issues/111) by @fealho +* Move `log_frequency` to `__init__` - [Issue #102](https://github.com/sdv-dev/CTGAN/issues/102) by @fealho +* Add discriminator steps hyperparameter - [Issue #101](https://github.com/sdv-dev/CTGAN/issues/101) by @Baukebrenninkmeijer +* Code cleanup / Expose hyperparameters - [Issue #59](https://github.com/sdv-dev/CTGAN/issues/59) by @fealho and @leix28 +* Publish to conda repo - [Issue #54](https://github.com/sdv-dev/CTGAN/issues/54) by @fealho + +### Bugs fixed + +* Fixed NaN != NaN counting bug. - [Issue #100](https://github.com/sdv-dev/CTGAN/issues/100) by @fealho +* Update dependencies and testing - [Issue #90](https://github.com/sdv-dev/CTGAN/issues/90) by @csala + +## v0.2.2 - 2020-11-13 + +In this release we introduce several minor improvements to make CTGAN more versatile and +propertly support new types of data, such as categorical NaN values, as well as conditional +sampling and features to save and load models. + +Additionally, the dependency ranges and python versions have been updated to support up +to date runtimes. + +Many thanks @fealho @leix28 @csala @oregonpillow and @lurosenb for working on making this release possible! + +### Improvements + +* Drop Python 3.5 support - [Issue #79](https://github.com/sdv-dev/CTGAN/issues/79) by @fealho +* Support NaN values in categorical variables - [Issue #78](https://github.com/sdv-dev/CTGAN/issues/78) by @fealho +* Sample synthetic data conditioning on a discrete column - [Issue #69](https://github.com/sdv-dev/CTGAN/issues/69) by @leix28 +* Support recent versions of pandas - [Issue #57](https://github.com/sdv-dev/CTGAN/issues/57) by @csala +* Easy solution for restoring original dtypes - [Issue #26](https://github.com/sdv-dev/CTGAN/issues/26) by @oregonpillow + +### Bugs fixed + +* Loss to nan - [Issue #73](https://github.com/sdv-dev/CTGAN/issues/73) by @fealho +* Swapped the sklearn utils testing import statement - [Issue #53](https://github.com/sdv-dev/CTGAN/issues/53) by @lurosenb + +## v0.2.1 - 2020-01-27 + +Minor version including changes to ensure the logs are properly printed and +the option to disable the log transformation to the discrete column frequencies. + +Special thanks to @kevinykuo for the contributions! + +### Issues Resolved: + +* Option to sample from true data frequency instead of logged frequency - [Issue #16](https://github.com/sdv-dev/CTGAN/issues/16) by @kevinykuo +* Flush stdout buffer for epoch updates - [Issue #14](https://github.com/sdv-dev/CTGAN/issues/14) by @kevinykuo + +## v0.2.0 - 2019-12-18 + +Reorganization of the project structure with a new Python API, new Command Line Interface +and increased data format support. + +### Issues Resolved: + +* Reorganize the project structure - [Issue #10](https://github.com/sdv-dev/CTGAN/issues/10) by @csala +* Move epochs to the fit method - [Issue #5](https://github.com/sdv-dev/CTGAN/issues/5) by @csala + +## v0.1.0 - 2019-11-07 + +First Release - NeurIPS 2019 Version. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/LICENSE b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..f6f8213bcfc525df1b533a0dd4b06f05f9a14ea8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/LICENSE @@ -0,0 +1,22 @@ +MIT License + +Copyright (c) 2019, MIT Data To AI Lab + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in new file mode 100644 index 0000000000000000000000000000000000000000..469520f584a4ffc098d13e23c0d273f89e01a06e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/MANIFEST.in @@ -0,0 +1,11 @@ +include AUTHORS.rst +include CONTRIBUTING.rst +include HISTORY.md +include LICENSE +include README.md + +recursive-include tests * +recursive-exclude * __pycache__ +recursive-exclude * *.py[co] + +recursive-include docs *.md *.rst conf.py Makefile make.bat *.jpg *.png *.gif diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/Makefile b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/Makefile new file mode 100644 index 0000000000000000000000000000000000000000..bb667a145994b12c34f88661ec6a566f06a4518d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/Makefile @@ -0,0 +1,240 @@ +.DEFAULT_GOAL := help + +define BROWSER_PYSCRIPT +import os, webbrowser, sys + +try: + from urllib import pathname2url +except: + from urllib.request import pathname2url + +webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1]))) +endef +export BROWSER_PYSCRIPT + +define PRINT_HELP_PYSCRIPT +import re, sys + +for line in sys.stdin: + match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line) + if match: + target, help = match.groups() + print("%-20s %s" % (target, help)) +endef +export PRINT_HELP_PYSCRIPT + +BROWSER := python -c "$$BROWSER_PYSCRIPT" + +.PHONY: help +help: + @python -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST) + + +# CLEAN TARGETS + +.PHONY: clean-build +clean-build: ## remove build artifacts + rm -fr build/ + rm -fr dist/ + rm -fr .eggs/ + find . -name '*.egg-info' -exec rm -fr {} + + find . -name '*.egg' -exec rm -f {} + + +.PHONY: clean-pyc +clean-pyc: ## remove Python file artifacts + find . -name '*.pyc' -exec rm -f {} + + find . -name '*.pyo' -exec rm -f {} + + find . -name '*~' -exec rm -f {} + + find . -name '__pycache__' -exec rm -fr {} + + +.PHONY: clean-coverage +clean-coverage: ## remove coverage artifacts + rm -f .coverage + rm -f .coverage.* + rm -fr htmlcov/ + +.PHONY: clean-test +clean-test: ## remove test artifacts + rm -fr .tox/ + rm -fr .pytest_cache + +.PHONY: clean +clean: clean-build clean-pyc clean-test clean-coverage ## remove all build, test, coverage and Python artifacts + + +# INSTALL TARGETS + +.PHONY: install +install: clean-build clean-pyc ## install the package to the active Python's site-packages + pip install . + +.PHONY: install-test +install-test: clean-build clean-pyc ## install the package and test dependencies + pip install .[test] + +.PHONY: install-develop +install-develop: clean-build clean-pyc ## install the package in editable mode and dependencies for development + pip install -e .[dev] + +MINIMUM := $(shell sed -n '/install_requires = \[/,/]/p' setup.py | head -n-1 | tail -n+2 | sed 's/ *\(.*\),$?$$/\1/g' | tr '>' '=') + +.PHONY: install-minimum +install-minimum: ## install the minimum supported versions of the package dependencies + pip install $(MINIMUM) + + +# LINT TARGETS + + +.PHONY: lint +lint: ## check style with flake8 and isort + invoke lint + +.PHONY: fix-lint +fix-lint: ## fix lint issues using autoflake, autopep8, and isort + find ctgan tests -name '*.py' | xargs autoflake --in-place --remove-all-unused-imports --remove-unused-variables + autopep8 --in-place --recursive --aggressive ctgan tests + isort --apply --atomic --recursive ctgan tests + + +# TEST TARGETS + +.PHONY: test-unit +test-unit: ## run unit tests using pytest + invoke unit + +.PHONY: test-integration +test-integration: ## run integration tests using pytest + invoke integration + +.PHONY: test-readme +test-readme: ## run the readme snippets + invoke readme + +.PHONY: check-dependencies +check-dependencies: ## test if there are any broken dependencies + pip check + +.PHONY: test +test: test-unit test-integration test-readme ## test everything that needs test dependencies + +.PHONY: test-devel +test-devel: lint ## test everything that needs development dependencies + +.PHONY: test-all +test-all: ## run tests on every Python version with tox + tox -r + + +.PHONY: coverage +coverage: ## check code coverage quickly with the default Python + coverage run --source ctgan -m pytest + coverage report -m + coverage html + $(BROWSER) htmlcov/index.html + + +# RELEASE TARGETS + +.PHONY: dist +dist: clean ## builds source and wheel package + python setup.py sdist + python setup.py bdist_wheel + ls -l dist + +.PHONY: publish-confirm +publish-confirm: + @echo "WARNING: This will irreversibly upload a new version to PyPI!" + @echo -n "Please type 'confirm' to proceed: " \ + && read answer \ + && [ "$${answer}" = "confirm" ] + +.PHONY: publish-test +publish-test: dist publish-confirm ## package and upload a release on TestPyPI + twine upload --repository-url https://test.pypi.org/legacy/ dist/* + +.PHONY: publish +publish: dist publish-confirm ## package and upload a release + twine upload dist/* + +.PHONY: bumpversion-release +bumpversion-release: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release + git push --tags origin stable + +.PHONY: bumpversion-release-test +bumpversion-release-test: ## Merge master to stable and bumpversion release + git checkout stable || git checkout -b stable + git merge --no-ff master -m"make release-tag: Merge branch 'master' into stable" + bumpversion release --no-tag + @echo git push --tags origin stable + +.PHONY: bumpversion-patch +bumpversion-patch: ## Merge stable to master and bumpversion patch + git checkout master + git merge stable + bumpversion --no-tag patch + git push + +.PHONY: bumpversion-candidate +bumpversion-candidate: ## Bump the version to the next candidate + bumpversion candidate --no-tag + +.PHONY: bumpversion-minor +bumpversion-minor: ## Bump the version the next minor skipping the release + bumpversion --no-tag minor + +.PHONY: bumpversion-major +bumpversion-major: ## Bump the version the next major skipping the release + bumpversion --no-tag major + +.PHONY: bumpversion-revert +bumpversion-revert: ## Undo a previous bumpversion-release + git checkout master + git branch -D stable + +CLEAN_DIR := $(shell git status --short | grep -v ??) +CURRENT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD 2>/dev/null) +CHANGELOG_LINES := $(shell git diff HEAD..origin/stable HISTORY.md 2>&1 | wc -l) + +.PHONY: check-clean +check-clean: ## Check if the directory has uncommitted changes +ifneq ($(CLEAN_DIR),) + $(error There are uncommitted changes) +endif + +.PHONY: check-master +check-master: ## Check if we are in master branch +ifneq ($(CURRENT_BRANCH),master) + $(error Please make the release from master branch\n) +endif + +.PHONY: check-history +check-history: ## Check if HISTORY.md has been modified +ifeq ($(CHANGELOG_LINES),0) + $(error Please insert the release notes in HISTORY.md before releasing) +endif + +.PHONY: check-release +check-release: check-clean check-master check-history ## Check if the release can be made + @echo "A new release can be made" + +.PHONY: release +release: check-release bumpversion-release publish bumpversion-patch + +.PHONY: release-test +release-test: check-release bumpversion-release-test publish-test bumpversion-revert + +.PHONY: release-candidate +release-candidate: check-master publish bumpversion-candidate + +.PHONY: release-candidate-test +release-candidate-test: check-clean check-master publish-test + +.PHONY: release-minor +release-minor: check-release bumpversion-minor release + +.PHONY: release-major +release-major: check-release bumpversion-major release diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/README.md new file mode 100644 index 0000000000000000000000000000000000000000..6c8ab04c4ff5f505eaf5f1bf68c55f0161593f07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/README.md @@ -0,0 +1,182 @@ +
+
+

+ This repository is part of The Synthetic Data Vault Project, a project from DataCebo. +

+ +[![Development Status](https://img.shields.io/badge/Development%20Status-2%20--%20Pre--Alpha-yellow)](https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha) +[![PyPI Shield](https://img.shields.io/pypi/v/ctgan.svg)](https://pypi.python.org/pypi/ctgan) +[![Unit Tests](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml/badge.svg)](https://github.com/sdv-dev/CTGAN/actions/workflows/unit.yml) +[![Downloads](https://pepy.tech/badge/ctgan)](https://pepy.tech/project/ctgan) +[![Coverage Status](https://codecov.io/gh/sdv-dev/CTGAN/branch/master/graph/badge.svg)](https://codecov.io/gh/sdv-dev/CTGAN) + +
+
+

+ + + +

+
+ +
+ +# Overview + +CTGAN is a collection of Deep Learning based Synthetic Data Generators for single table data, which are able to learn from real data and generate synthetic clones with high fidelity. + +| Important Links | | +| --------------------------------------------- | -------------------------------------------------------------------- | +| :computer: **[Website]** | Check out the SDV Website for more information about the project. | +| :orange_book: **[SDV Blog]** | Regular publshing of useful content about Synthetic Data Generation. | +| :book: **[Documentation]** | Quickstarts, User and Development Guides, and API Reference. | +| :octocat: **[Repository]** | The link to the Github Repository of this library. | +| :scroll: **[License]** | The entire ecosystem is published under the MIT License. | +| :keyboard: **[Development Status]** | This software is in its Pre-Alpha stage. | +| [![][Slack Logo] **Community**][Community] | Join our Slack Workspace for announcements and discussions. | +| [![][MyBinder Logo] **Tutorials**][Tutorials] | Run the SDV Tutorials in a Binder environment. | + +[Website]: https://sdv.dev +[SDV Blog]: https://sdv.dev/blog +[Documentation]: https://sdv.dev/SDV +[Repository]: https://github.com/sdv-dev/CTGAN +[License]: https://github.com/sdv-dev/CTGAN/blob/master/LICENSE +[Development Status]: https://pypi.org/search/?c=Development+Status+%3A%3A+2+-+Pre-Alpha +[Slack Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/slack.png +[Community]: https://join.slack.com/t/sdv-space/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw +[MyBinder Logo]: https://github.com/sdv-dev/SDV/blob/master/docs/images/mybinder.png +[Tutorials]: https://mybinder.org/v2/gh/sdv-dev/SDV/master?filepath=tutorials + +## Implemented Models + +Currently, this library implements the **CTGAN** and **TVAE** models proposed in the [Modeling Tabular data using Conditional GAN](https://arxiv.org/abs/1907.00503) paper. For more information about these models, please check out the respective user guides: +* [CTGAN User Guide](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). +* [TVAE User Guide](https://sdv.dev/SDV/user_guides/single_table/tvae.html). + +# Install + +**CTGAN** is part of the **SDV** project and is automatically installed alongside it. For +details about this process please visit the [SDV Installation Guide]( +https://sdv.dev/SDV/getting_started/install.html) + +Optionally, **CTGAN** can also be installed as a standalone library using the following commands: + +**Using `pip`:** + +```bash +pip install ctgan +``` + +**Using `conda`:** + +```bash +conda install -c pytorch -c conda-forge ctgan +``` + +For more installation options please visit the [CTGAN installation Guide](INSTALL.md) + +# Usage Example + +> :warning: **WARNING**: If you're just getting started with synthetic data, we recommend using the SDV library which provides user-friendly APIs for interacting with CTGAN. To learn more about using CTGAN through SDV, check out the user guide [here](https://sdv.dev/SDV/user_guides/single_table/ctgan.html). + +To get started with CTGAN, you should prepare your data as either a `numpy.ndarray` or a `pandas.DataFrame` object with two types of columns: + +* **Continuous Columns**: can contain any numerical value. +* **Discrete Columns**: contain a finite number values, whether these are string values or not. + +In this example we load the [Adult Census Dataset](https://archive.ics.uci.edu/ml/datasets/adult) which is a built-in demo dataset. We then model it using the **CTGANSynthesizer** and generate a synthetic copy of it. + + +```python3 +from ctgan import CTGANSynthesizer +from ctgan import load_demo + +data = load_demo() + +# Names of the columns that are discrete +discrete_columns = [ + 'workclass', + 'education', + 'marital-status', + 'occupation', + 'relationship', + 'race', + 'sex', + 'native-country', + 'income' +] + +ctgan = CTGANSynthesizer(epochs=10) +ctgan.fit(data, discrete_columns) + +# Synthetic copy +samples = ctgan.sample(1000) +``` + + + +# Join our community + + +1. Please have a look at the [Contributing Guide](https://sdv.dev/SDV/developer_guides/contributing.html) to see how you can contribute to the project. +2. If you have any doubts, feature requests or detect an error, please [open an issue on github](https://github.com/sdv-dev/CTGAN/issues) or [join our Slack Workspace](https://sdv-space.slack.com/join/shared_invite/zt-gdsfcb5w-0QQpFMVoyB2Yd6SRiMplcw#/). +3. Also, do not forget to check the [project documentation site](https://sdv.dev/SDV/)! + + +# Citing TGAN + +If you use CTGAN, please cite the following work: + +- *Lei Xu, Maria Skoularidou, Alfredo Cuesta-Infante, Kalyan Veeramachaneni.* **Modeling Tabular data using Conditional GAN**. NeurIPS, 2019. + +```LaTeX +@inproceedings{xu2019modeling, + title={Modeling Tabular data using Conditional GAN}, + author={Xu, Lei and Skoularidou, Maria and Cuesta-Infante, Alfredo and Veeramachaneni, Kalyan}, + booktitle={Advances in Neural Information Processing Systems}, + year={2019} +} +``` + +# Related Projects +Please note that these libraries are external contributions and are not maintained nor supervised by +the MIT DAI-Lab team. + +## R interface for CTGAN + +A wrapper around **CTGAN** has been implemented by Kevin Kuo @kevinykuo, bringing the functionalities +of **CTGAN** to **R** users. + +More details can be found in the corresponding repository: https://github.com/kasaai/ctgan + +## CTGAN Server CLI + +A package to easily deploy **CTGAN** onto a remote server. This package is developed by Timothy Pillow @oregonpillow. + +More details can be found in the corresponding repository: https://github.com/oregonpillow/ctgan-server-cli + +--- + + +
+ +
+
+
+ +[The Synthetic Data Vault Project](https://sdv.dev) was first created at MIT's [Data to AI Lab]( +https://dai.lids.mit.edu/) in 2016. After 4 years of research and traction with enterprise, we +created [DataCebo](https://datacebo.com) in 2020 with the goal of growing the project. +Today, DataCebo is the proud developer of SDV, the largest ecosystem for +synthetic data generation & evaluation. It is home to multiple libraries that support synthetic +data, including: + +* 🔄 Data discovery & transformation. Reverse the transforms to reproduce realistic data. +* 🧠 Multiple machine learning models -- ranging from Copulas to Deep Learning -- to create tabular, + multi table and time series data. +* 📊 Measuring quality and privacy of synthetic data, and comparing different synthetic data + generation models. + +[Get started using the SDV package](https://sdv.dev/SDV/getting_started/install.html) -- a fully +integrated solution and your one-stop shop for synthetic data. Or, use the standalone libraries +for specific needs. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md new file mode 100644 index 0000000000000000000000000000000000000000..92e2ec5aa40b081c940ac1e918efaeeed8623584 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/README.md @@ -0,0 +1,29 @@ +## Instructions + +These are instructions to deploy the latest version of **CTGAN** to [conda](https://docs.conda.io/en/latest/). +It should be done after every new release. + +## Update the recipe +Prior to making the release on PyPI, you should update the meta.yaml to reflect any changes in the dependencies. +Note that you do not need to edit the version number as that is managed by bumpversion. + +## Make the PyPI release +Follow the standard release instructions to make a PyPI release. Then, return here to make the conda release. + +## Build a package +As part of the PyPI release, you will have updated the stable branch. You should now check out the stable +branch and build the conda package. + +```bash +git checkout stable +cd conda +conda build -c sdv-dev -c pytorch -c conda-forge . +``` + +## Upload to Anaconda +Finally, you can upload the resulting package to Anaconda. + +```bash +anaconda login +anaconda upload -u sdv-dev +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9d26c28c6ada4f4977d517986a05ceca138c7090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/conda/meta.yaml @@ -0,0 +1,51 @@ +{% set name = 'ctgan' %} +{% set version = '0.5.2.dev0' %} + +package: + name: "{{ name|lower }}" + version: "{{ version }}" + +source: + url: "https://pypi.io/packages/source/{{ name[0] }}/{{ name }}/{{ name }}-{{ version }}.tar.gz" + +build: + number: 0 + noarch: python + entry_points: + - ctgan=ctgan.__main__:main + script: "{{ PYTHON }} -m pip install . -vv" + +requirements: + host: + - pip + - pytest-runner + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + run: + - packaging >=20,<22 + - python >=3.6,<3.10 + - numpy >=1.18.0,<2 + - pandas >=1.1.3,<2 + - scikit-learn >=0.24,<1 + - pytorch >=1.8.0,<2 + - torchvision >=0.9.0,<1 + - rdt >=0.6.2,<0.7 + +about: + home: "https://github.com/sdv-dev/CTGAN" + license: MIT + license_family: MIT + license_file: + summary: "Conditional GAN for Tabular Data" + doc_url: + dev_url: + +extra: + recipe-maintainers: + - sdv-dev diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e3abb1c03b685802c21428ba050b1620e1a435fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__init__.py @@ -0,0 +1,17 @@ +# -*- coding: utf-8 -*- + +"""Top-level package for ctgan.""" + +__author__ = 'MIT Data To AI Lab' +__email__ = 'dailabmit@gmail.com' +__version__ = '0.5.2.dev0' + +from .demo import load_demo +from .synthesizers.ctgan import CTGANSynthesizer +from .synthesizers.tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer', + 'load_demo' +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..8291c1879b60d0de49db79fb6ca60d33f09c8763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/__main__.py @@ -0,0 +1,102 @@ +"""CLI.""" + +import argparse + +from ctgan.data import read_csv, read_tsv, write_tsv +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def _parse_args(): + parser = argparse.ArgumentParser(description='CTGAN Command Line Interface') + parser.add_argument('-e', '--epochs', default=300, type=int, + help='Number of training epochs') + parser.add_argument('-t', '--tsv', action='store_true', + help='Load data in TSV format instead of CSV') + parser.add_argument('--no-header', dest='header', action='store_false', + help='The CSV file has no header. Discrete columns will be indices.') + + parser.add_argument('-m', '--metadata', help='Path to the metadata') + parser.add_argument('-d', '--discrete', + help='Comma separated list of discrete columns without whitespaces.') + parser.add_argument('-n', '--num-samples', type=int, + help='Number of rows to sample. Defaults to the training data size') + + parser.add_argument('--generator_lr', type=float, default=2e-4, + help='Learning rate for the generator.') + parser.add_argument('--discriminator_lr', type=float, default=2e-4, + help='Learning rate for the discriminator.') + + parser.add_argument('--generator_decay', type=float, default=1e-6, + help='Weight decay for the generator.') + parser.add_argument('--discriminator_decay', type=float, default=0, + help='Weight decay for the discriminator.') + + parser.add_argument('--embedding_dim', type=int, default=128, + help='Dimension of input z to the generator.') + parser.add_argument('--generator_dim', type=str, default='256,256', + help='Dimension of each generator layer. ' + 'Comma separated integers with no whitespaces.') + parser.add_argument('--discriminator_dim', type=str, default='256,256', + help='Dimension of each discriminator layer. ' + 'Comma separated integers with no whitespaces.') + + parser.add_argument('--batch_size', type=int, default=500, + help='Batch size. Must be an even number.') + parser.add_argument('--save', default=None, type=str, + help='A filename to save the trained synthesizer.') + parser.add_argument('--load', default=None, type=str, + help='A filename to load a trained synthesizer.') + + parser.add_argument('--sample_condition_column', default=None, type=str, + help='Select a discrete column name.') + parser.add_argument('--sample_condition_column_value', default=None, type=str, + help='Specify the value of the selected discrete column.') + + parser.add_argument('data', help='Path to training data') + parser.add_argument('output', help='Path of the output file') + + return parser.parse_args() + + +def main(): + """CLI.""" + args = _parse_args() + if args.tsv: + data, discrete_columns = read_tsv(args.data, args.metadata) + else: + data, discrete_columns = read_csv(args.data, args.metadata, args.header, args.discrete) + + if args.load: + model = CTGANSynthesizer.load(args.load) + else: + generator_dim = [int(x) for x in args.generator_dim.split(',')] + discriminator_dim = [int(x) for x in args.discriminator_dim.split(',')] + model = CTGANSynthesizer( + embedding_dim=args.embedding_dim, generator_dim=generator_dim, + discriminator_dim=discriminator_dim, generator_lr=args.generator_lr, + generator_decay=args.generator_decay, discriminator_lr=args.discriminator_lr, + discriminator_decay=args.discriminator_decay, batch_size=args.batch_size, + epochs=args.epochs) + model.fit(data, discrete_columns) + + if args.save is not None: + model.save(args.save) + + num_samples = args.num_samples or len(data) + + if args.sample_condition_column is not None: + assert args.sample_condition_column_value is not None + + sampled = model.sample( + num_samples, + args.sample_condition_column, + args.sample_condition_column_value) + + if args.tsv: + write_tsv(sampled, args.metadata, args.output) + else: + sampled.to_csv(args.output, index=False) + + +if __name__ == '__main__': + main() diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py new file mode 100644 index 0000000000000000000000000000000000000000..1c3ec72e9ec972f9c7d148b66f212bf3e366a340 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data.py @@ -0,0 +1,94 @@ +"""Data loading.""" + +import json + +import numpy as np +import pandas as pd + + +def read_csv(csv_filename, meta_filename=None, header=True, discrete=None): + """Read a csv file.""" + data = pd.read_csv(csv_filename, header='infer' if header else None) + + if meta_filename: + with open(meta_filename) as meta_file: + metadata = json.load(meta_file) + + discrete_columns = [ + column['name'] + for column in metadata['columns'] + if column['type'] != 'continuous' + ] + + elif discrete: + discrete_columns = discrete.split(',') + if not header: + discrete_columns = [int(i) for i in discrete_columns] + + else: + discrete_columns = [] + + return data, discrete_columns + + +def read_tsv(data_filename, meta_filename): + """Read a tsv file.""" + with open(meta_filename) as f: + column_info = f.readlines() + + column_info_raw = [ + x.replace('{', ' ').replace('}', ' ').split() + for x in column_info + ] + + discrete = [] + continuous = [] + column_info = [] + + for idx, item in enumerate(column_info_raw): + if item[0] == 'C': + continuous.append(idx) + column_info.append((float(item[1]), float(item[2]))) + else: + assert item[0] == 'D' + discrete.append(idx) + column_info.append(item[1:]) + + meta = { + 'continuous_columns': continuous, + 'discrete_columns': discrete, + 'column_info': column_info + } + + with open(data_filename) as f: + lines = f.readlines() + + data = [] + for row in lines: + row_raw = row.split() + row = [] + for idx, col in enumerate(row_raw): + if idx in continuous: + row.append(col) + else: + assert idx in discrete + row.append(column_info[idx].index(col)) + + data.append(row) + + return np.asarray(data, dtype='float32'), meta['discrete_columns'] + + +def write_tsv(data, meta, output_filename): + """Write to a tsv file.""" + with open(output_filename, 'w') as f: + + for row in data: + for idx, col in enumerate(row): + if idx in meta['continuous_columns']: + print(col, end=' ', file=f) + else: + assert idx in meta['discrete_columns'] + print(meta['column_info'][idx][int(col)], end=' ', file=f) + + print(file=f) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py new file mode 100644 index 0000000000000000000000000000000000000000..5cbf339dac0980c5368d2d11e2934a268fb9d43a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_sampler.py @@ -0,0 +1,156 @@ +"""DataSampler module.""" + +import numpy as np + + +class DataSampler(object): + """DataSampler samples the conditional vector and corresponding data for CTGAN.""" + + def __init__(self, data, output_info, log_frequency): + self._data = data + + def is_discrete_column(column_info): + return (len(column_info) == 1 + and column_info[0].activation_fn == 'softmax') + + n_discrete_columns = sum( + [1 for column_info in output_info if is_discrete_column(column_info)]) + + self._discrete_column_matrix_st = np.zeros( + n_discrete_columns, dtype='int32') + + # Store the row id for each category in each discrete column. + # For example _rid_by_cat_cols[a][b] is a list of all rows with the + # a-th discrete column equal value b. + self._rid_by_cat_cols = [] + + # Compute _rid_by_cat_cols + st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + + rid_by_cat = [] + for j in range(span_info.dim): + rid_by_cat.append(np.nonzero(data[:, st + j])[0]) + self._rid_by_cat_cols.append(rid_by_cat) + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + assert st == data.shape[1] + + # Prepare an interval matrix for efficiently sample conditional vector + max_category = max([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ], default=0) + + self._discrete_column_cond_st = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_n_category = np.zeros(n_discrete_columns, dtype='int32') + self._discrete_column_category_prob = np.zeros((n_discrete_columns, max_category)) + self._n_discrete_columns = n_discrete_columns + self._n_categories = sum([ + column_info[0].dim + for column_info in output_info + if is_discrete_column(column_info) + ]) + + st = 0 + current_id = 0 + current_cond_st = 0 + for column_info in output_info: + if is_discrete_column(column_info): + span_info = column_info[0] + ed = st + span_info.dim + category_freq = np.sum(data[:, st:ed], axis=0) + if log_frequency: + category_freq = np.log(category_freq + 1) + category_prob = category_freq / np.sum(category_freq) + self._discrete_column_category_prob[current_id, :span_info.dim] = category_prob + self._discrete_column_cond_st[current_id] = current_cond_st + self._discrete_column_n_category[current_id] = span_info.dim + current_cond_st += span_info.dim + current_id += 1 + st = ed + else: + st += sum([span_info.dim for span_info in column_info]) + + def _random_choice_prob_index(self, discrete_column_id): + probs = self._discrete_column_category_prob[discrete_column_id] + r = np.expand_dims(np.random.rand(probs.shape[0]), axis=1) + return (probs.cumsum(axis=1) > r).argmax(axis=1) + + def sample_condvec(self, batch): + """Generate the conditional vector for training. + + Returns: + cond (batch x #categories): + The conditional vector. + mask (batch x #discrete columns): + A one-hot vector indicating the selected discrete column. + discrete column id (batch): + Integer representation of mask. + category_id_in_col (batch): + Selected category in the selected discrete column. + """ + if self._n_discrete_columns == 0: + return None + + discrete_column_id = np.random.choice( + np.arange(self._n_discrete_columns), batch) + + cond = np.zeros((batch, self._n_categories), dtype='float32') + mask = np.zeros((batch, self._n_discrete_columns), dtype='float32') + mask[np.arange(batch), discrete_column_id] = 1 + category_id_in_col = self._random_choice_prob_index(discrete_column_id) + category_id = (self._discrete_column_cond_st[discrete_column_id] + category_id_in_col) + cond[np.arange(batch), category_id] = 1 + + return cond, mask, discrete_column_id, category_id_in_col + + def sample_original_condvec(self, batch): + """Generate the conditional vector for generation use original frequency.""" + if self._n_discrete_columns == 0: + return None + + cond = np.zeros((batch, self._n_categories), dtype='float32') + + for i in range(batch): + row_idx = np.random.randint(0, len(self._data)) + col_idx = np.random.randint(0, self._n_discrete_columns) + matrix_st = self._discrete_column_matrix_st[col_idx] + matrix_ed = matrix_st + self._discrete_column_n_category[col_idx] + pick = np.argmax(self._data[row_idx, matrix_st:matrix_ed]) + cond[i, pick + self._discrete_column_cond_st[col_idx]] = 1 + + return cond + + def sample_data(self, n, col, opt): + """Sample data from original training data satisfying the sampled conditional vector. + + Returns: + n rows of matrix data. + """ + if col is None: + idx = np.random.randint(len(self._data), size=n) + return self._data[idx] + + idx = [] + for c, o in zip(col, opt): + idx.append(np.random.choice(self._rid_by_cat_cols[c][o])) + + return self._data[idx] + + def dim_cond_vec(self): + """Return the total number of categories.""" + return self._n_categories + + def generate_cond_from_condition_column_info(self, condition_info, batch): + """Generate the condition vector.""" + vec = np.zeros((batch, self._n_categories), dtype='float32') + id_ = self._discrete_column_matrix_st[condition_info['discrete_column_id']] + id_ += condition_info['value_id'] + vec[:, id_] = 1 + return vec diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..06cfd128247f187be963c4b8c26067b06a02cbce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/data_transformer.py @@ -0,0 +1,217 @@ +"""DataTransformer module.""" + +from collections import namedtuple + +import numpy as np +import pandas as pd +from rdt.transformers import BayesGMMTransformer, OneHotEncodingTransformer + +SpanInfo = namedtuple('SpanInfo', ['dim', 'activation_fn']) +ColumnTransformInfo = namedtuple( + 'ColumnTransformInfo', [ + 'column_name', 'column_type', 'transform', 'output_info', 'output_dimensions' + ] +) + + +class DataTransformer(object): + """Data Transformer. + + Model continuous columns with a BayesianGMM and normalized to a scalar [0, 1] and a vector. + Discrete columns are encoded using a scikit-learn OneHotEncoder. + """ + + def __init__(self, max_clusters=10, weight_threshold=0.005): + """Create a data transformer. + + Args: + max_clusters (int): + Maximum number of Gaussian distributions in Bayesian GMM. + weight_threshold (float): + Weight threshold for a Gaussian distribution to be kept. + """ + self._max_clusters = max_clusters + self._weight_threshold = weight_threshold + + def _fit_continuous(self, data): + """Train Bayesian GMM for continuous columns. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + gm = BayesGMMTransformer(max_clusters=min(len(data), 10)) + gm.fit(data, [column_name]) + num_components = sum(gm.valid_component_indicator) + + return ColumnTransformInfo( + column_name=column_name, column_type='continuous', transform=gm, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(num_components, 'softmax')], + output_dimensions=1 + num_components) + + def _fit_discrete(self, data): + """Fit one hot encoder for discrete column. + + Args: + data (pd.DataFrame): + A dataframe containing a column. + + Returns: + namedtuple: + A ``ColumnTransformInfo`` object. + """ + column_name = data.columns[0] + ohe = OneHotEncodingTransformer() + ohe.fit(data, [column_name]) + num_categories = len(ohe.dummies) + + return ColumnTransformInfo( + column_name=column_name, column_type='discrete', transform=ohe, + output_info=[SpanInfo(num_categories, 'softmax')], + output_dimensions=num_categories) + + def fit(self, raw_data, discrete_columns=()): + """Fit the ``DataTransformer``. + + Fits a ``BayesGMMTransformer`` for continuous columns and a + ``OneHotEncodingTransformer`` for discrete columns. + + This step also counts the #columns in matrix data and span information. + """ + self.output_info_list = [] + self.output_dimensions = 0 + self.dataframe = True + + if not isinstance(raw_data, pd.DataFrame): + self.dataframe = False + # work around for RDT issue #328 Fitting with numerical column names fails + discrete_columns = [str(column) for column in discrete_columns] + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + self._column_raw_dtypes = raw_data.infer_objects().dtypes + self._column_transform_info_list = [] + for column_name in raw_data.columns: + if column_name in discrete_columns: + column_transform_info = self._fit_discrete(raw_data[[column_name]]) + else: + column_transform_info = self._fit_continuous(raw_data[[column_name]]) + + self.output_info_list.append(column_transform_info.output_info) + self.output_dimensions += column_transform_info.output_dimensions + self._column_transform_info_list.append(column_transform_info) + + def _transform_continuous(self, column_transform_info, data): + column_name = data.columns[0] + data.loc[:, column_name] = data[column_name].to_numpy().flatten() + gm = column_transform_info.transform + transformed = gm.transform(data, [column_name]) + + # Converts the transformed data to the appropriate output format. + # The first column (ending in '.normalized') stays the same, + # but the lable encoded column (ending in '.component') is one hot encoded. + output = np.zeros((len(transformed), column_transform_info.output_dimensions)) + output[:, 0] = transformed[f'{column_name}.normalized'].to_numpy() + index = transformed[f'{column_name}.component'].to_numpy().astype(int) + output[np.arange(index.size), index + 1] = 1.0 + + return output + + def _transform_discrete(self, column_transform_info, data): + ohe = column_transform_info.transform + return ohe.transform(data).to_numpy() + + def transform(self, raw_data): + """Take raw data and output a matrix data.""" + if not isinstance(raw_data, pd.DataFrame): + column_names = [str(num) for num in range(raw_data.shape[1])] + raw_data = pd.DataFrame(raw_data, columns=column_names) + + column_data_list = [] + for column_transform_info in self._column_transform_info_list: + column_name = column_transform_info.column_name + data = raw_data[[column_name]] + if column_transform_info.column_type == 'continuous': + column_data_list.append(self._transform_continuous(column_transform_info, data)) + else: + column_data_list.append(self._transform_discrete(column_transform_info, data)) + + return np.concatenate(column_data_list, axis=1).astype(float) + + def _inverse_transform_continuous(self, column_transform_info, column_data, sigmas, st): + gm = column_transform_info.transform + data = pd.DataFrame(column_data[:, :2], columns=list(gm.get_output_types())) + data.iloc[:, 1] = np.argmax(column_data[:, 1:], axis=1) + if sigmas is not None: + selected_normalized_value = np.random.normal(data.iloc[:, 0], sigmas[st]) + data.iloc[:, 0] = selected_normalized_value + + return gm.reverse_transform(data, [column_transform_info.column_name]) + + def _inverse_transform_discrete(self, column_transform_info, column_data): + ohe = column_transform_info.transform + data = pd.DataFrame(column_data, columns=list(ohe.get_output_types())) + return ohe.reverse_transform(data)[column_transform_info.column_name] + + def inverse_transform(self, data, sigmas=None): + """Take matrix data and output raw data. + + Output uses the same type as input to the transform function. + Either np array or pd dataframe. + """ + st = 0 + recovered_column_data_list = [] + column_names = [] + for column_transform_info in self._column_transform_info_list: + dim = column_transform_info.output_dimensions + column_data = data[:, st:st + dim] + if column_transform_info.column_type == 'continuous': + recovered_column_data = self._inverse_transform_continuous( + column_transform_info, column_data, sigmas, st) + else: + recovered_column_data = self._inverse_transform_discrete( + column_transform_info, column_data) + + recovered_column_data_list.append(recovered_column_data) + column_names.append(column_transform_info.column_name) + st += dim + + recovered_data = np.column_stack(recovered_column_data_list) + recovered_data = (pd.DataFrame(recovered_data, columns=column_names) + .astype(self._column_raw_dtypes)) + if not self.dataframe: + recovered_data = recovered_data.to_numpy() + + return recovered_data + + def convert_column_name_value_to_id(self, column_name, value): + """Get the ids of the given `column_name`.""" + discrete_counter = 0 + column_id = 0 + for column_transform_info in self._column_transform_info_list: + if column_transform_info.column_name == column_name: + break + if column_transform_info.column_type == 'discrete': + discrete_counter += 1 + + column_id += 1 + + else: + raise ValueError(f"The column_name `{column_name}` doesn't exist in the data.") + + ohe = column_transform_info.transform + data = pd.DataFrame([value], columns=[column_transform_info.column_name]) + one_hot = ohe.transform(data).to_numpy()[0] + if sum(one_hot) == 0: + raise ValueError(f"The value `{value}` doesn't exist in the column `{column_name}`.") + + return { + 'discrete_column_id': discrete_counter, + 'column_id': column_id, + 'value_id': np.argmax(one_hot) + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py new file mode 100644 index 0000000000000000000000000000000000000000..a99f90aa576a31f07ebfa7081ee6e4e7817ed02f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/demo.py @@ -0,0 +1,10 @@ +"""Demo module.""" + +import pandas as pd + +DEMO_URL = 'http://ctgan-data.s3.amazonaws.com/census.csv.gz' + + +def load_demo(): + """Load the demo.""" + return pd.read_csv(DEMO_URL, compression='gzip') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..2f67c77a7892dad39ae429b80b46e8672a3c69df --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/__init__.py @@ -0,0 +1,16 @@ +"""Synthesizers module.""" + +from .ctgan import CTGANSynthesizer +from .tvae import TVAESynthesizer + +__all__ = ( + 'CTGANSynthesizer', + 'TVAESynthesizer' +) + + +def get_all_synthesizers(): + return { + name: globals()[name] + for name in __all__ + } diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py new file mode 100644 index 0000000000000000000000000000000000000000..5afb66d4a6d2700c27516d8a322ab7b30a9356eb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/base.py @@ -0,0 +1,105 @@ +"""BaseSynthesizer module.""" + +import contextlib + +import numpy as np +import torch + + +@contextlib.contextmanager +def set_random_states(random_state, set_model_random_state): + """Context manager for managing the random state. + + Args: + random_state (int or tuple): + The random seed or a tuple of (numpy.random.RandomState, torch.Generator). + set_model_random_state (function): + Function to set the random state on the model. + """ + original_np_state = np.random.get_state() + original_torch_state = torch.get_rng_state() + + random_np_state, random_torch_state = random_state + + np.random.set_state(random_np_state.get_state()) + torch.set_rng_state(random_torch_state.get_state()) + + try: + yield + finally: + current_np_state = np.random.RandomState() + current_np_state.set_state(np.random.get_state()) + current_torch_state = torch.Generator() + current_torch_state.set_state(torch.get_rng_state()) + set_model_random_state((current_np_state, current_torch_state)) + + np.random.set_state(original_np_state) + torch.set_rng_state(original_torch_state) + + +def random_state(function): + """Set the random state before calling the function. + + Args: + function (Callable): + The function to wrap around. + """ + def wrapper(self, *args, **kwargs): + if self.random_states is None: + return function(self, *args, **kwargs) + + else: + with set_random_states(self.random_states, self.set_random_state): + return function(self, *args, **kwargs) + + return wrapper + + +class BaseSynthesizer: + """Base class for all default synthesizers of ``CTGAN``. + + This should contain the save/load methods. + """ + + random_states = None + + def save(self, path): + """Save the model in the passed `path`.""" + device_backup = self._device + self.set_device(torch.device('cpu')) + torch.save(self, path) + self.set_device(device_backup) + + @classmethod + def load(cls, path): + """Load the model stored in the passed `path`.""" + device = torch.device('cuda:0' if torch.cuda.is_available() else 'cpu') + model = torch.load(path) + model.set_device(device) + return model + + def set_random_state(self, random_state): + """Set the random state. + + Args: + random_state (int, tuple, or None): + Either a tuple containing the (numpy.random.RandomState, torch.Generator) + or an int representing the random seed to use for both random states. + """ + if random_state is None: + self.random_states = random_state + elif isinstance(random_state, int): + self.random_states = ( + np.random.RandomState(seed=random_state), + torch.Generator().manual_seed(random_state), + ) + elif ( + isinstance(random_state, tuple) and + isinstance(random_state[0], np.random.RandomState) and + isinstance(random_state[1], torch.Generator) + ): + self.random_states = random_state + else: + raise TypeError( + f'`random_state` {random_state} expected to be an int or a tuple of ' + '(`np.random.RandomState`, `torch.Generator`)') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..e4253e87d6349cd2bccb669f46146edfd61e23a8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/ctgan.py @@ -0,0 +1,482 @@ +"""CTGANSynthesizer module.""" + +import warnings + +import numpy as np +import pandas as pd +import torch +from packaging import version +from torch import optim +from torch.nn import BatchNorm1d, Dropout, LeakyReLU, Linear, Module, ReLU, Sequential, functional + +from ..data_sampler import DataSampler +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Discriminator(Module): + """Discriminator for the CTGANSynthesizer.""" + + def __init__(self, input_dim, discriminator_dim, pac=10): + super(Discriminator, self).__init__() + dim = input_dim * pac + self.pac = pac + self.pacdim = dim + seq = [] + for item in list(discriminator_dim): + seq += [Linear(dim, item), LeakyReLU(0.2), Dropout(0.5)] + dim = item + + seq += [Linear(dim, 1)] + self.seq = Sequential(*seq) + + def calc_gradient_penalty(self, real_data, fake_data, device='cpu', pac=10, lambda_=10): + """Compute the gradient penalty.""" + alpha = torch.rand(real_data.size(0) // pac, 1, 1, device=device) + alpha = alpha.repeat(1, pac, real_data.size(1)) + alpha = alpha.view(-1, real_data.size(1)) + + interpolates = alpha * real_data + ((1 - alpha) * fake_data) + + disc_interpolates = self(interpolates) + + gradients = torch.autograd.grad( + outputs=disc_interpolates, inputs=interpolates, + grad_outputs=torch.ones(disc_interpolates.size(), device=device), + create_graph=True, retain_graph=True, only_inputs=True + )[0] + + gradients_view = gradients.view(-1, pac * real_data.size(1)).norm(2, dim=1) - 1 + gradient_penalty = ((gradients_view) ** 2).mean() * lambda_ + + return gradient_penalty + + def forward(self, input_): + """Apply the Discriminator to the `input_`.""" + assert input_.size()[0] % self.pac == 0 + return self.seq(input_.view(-1, self.pacdim)) + + +class Residual(Module): + """Residual layer for the CTGANSynthesizer.""" + + def __init__(self, i, o): + super(Residual, self).__init__() + self.fc = Linear(i, o) + self.bn = BatchNorm1d(o) + self.relu = ReLU() + + def forward(self, input_): + """Apply the Residual layer to the `input_`.""" + out = self.fc(input_) + out = self.bn(out) + out = self.relu(out) + return torch.cat([out, input_], dim=1) + + +class Generator(Module): + """Generator for the CTGANSynthesizer.""" + + def __init__(self, embedding_dim, generator_dim, data_dim): + super(Generator, self).__init__() + dim = embedding_dim + seq = [] + for item in list(generator_dim): + seq += [Residual(dim, item)] + dim += item + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + + def forward(self, input_): + """Apply the Generator to the `input_`.""" + data = self.seq(input_) + return data + + +class CTGANSynthesizer(BaseSynthesizer): + """Conditional Table GAN Synthesizer. + + This is the core class of the CTGAN project, where the different components + are orchestrated together. + For more details about the process, please check the [Modeling Tabular data using + Conditional GAN](https://arxiv.org/abs/1907.00503) paper. + + Args: + embedding_dim (int): + Size of the random sample passed to the Generator. Defaults to 128. + generator_dim (tuple or list of ints): + Size of the output samples for each one of the Residuals. A Residual Layer + will be created for each one of the values provided. Defaults to (256, 256). + discriminator_dim (tuple or list of ints): + Size of the output samples for each one of the Discriminator Layers. A Linear Layer + will be created for each one of the values provided. Defaults to (256, 256). + generator_lr (float): + Learning rate for the generator. Defaults to 2e-4. + generator_decay (float): + Generator weight decay for the Adam Optimizer. Defaults to 1e-6. + discriminator_lr (float): + Learning rate for the discriminator. Defaults to 2e-4. + discriminator_decay (float): + Discriminator weight decay for the Adam Optimizer. Defaults to 1e-6. + batch_size (int): + Number of data samples to process in each step. + discriminator_steps (int): + Number of discriminator updates to do for each generator update. + From the WGAN paper: https://arxiv.org/abs/1701.07875. WGAN paper + default is 5. Default used is 1 to match original CTGAN implementation. + log_frequency (boolean): + Whether to use log frequency of categorical levels in conditional + sampling. Defaults to ``True``. + verbose (boolean): + Whether to have print statements for progress results. Defaults to ``False``. + epochs (int): + Number of training epochs. Defaults to 300. + pac (int): + Number of samples to group together when applying the discriminator. + Defaults to 10. + cuda (bool): + Whether to attempt to use cuda for GPU computation. + If this is False or CUDA is not available, CPU will be used. + Defaults to ``True``. + """ + + def __init__(self, embedding_dim=128, generator_dim=(256, 256), discriminator_dim=(256, 256), + generator_lr=2e-4, generator_decay=1e-6, discriminator_lr=2e-4, + discriminator_decay=1e-6, batch_size=500, discriminator_steps=1, + log_frequency=True, verbose=False, epochs=300, pac=10, cuda=True): + + assert batch_size % 2 == 0 + + self._embedding_dim = embedding_dim + self._generator_dim = generator_dim + self._discriminator_dim = discriminator_dim + + self._generator_lr = generator_lr + self._generator_decay = generator_decay + self._discriminator_lr = discriminator_lr + self._discriminator_decay = discriminator_decay + + self._batch_size = batch_size + self._discriminator_steps = discriminator_steps + self._log_frequency = log_frequency + self._verbose = verbose + self._epochs = epochs + self.pac = pac + + if not cuda or not torch.cuda.is_available(): + device = 'cpu' + elif isinstance(cuda, str): + device = cuda + else: + device = 'cuda' + + self._device = torch.device(device) + + self._transformer = None + self._data_sampler = None + self._generator = None + + @staticmethod + def _gumbel_softmax(logits, tau=1, hard=False, eps=1e-10, dim=-1): + """Deals with the instability of the gumbel_softmax for older versions of torch. + + For more details about the issue: + https://drive.google.com/file/d/1AA5wPfZ1kquaRtVruCd6BiYZGcDeNxyP/view?usp=sharing + + Args: + logits […, num_features]: + Unnormalized log probabilities + tau: + Non-negative scalar temperature + hard (bool): + If True, the returned samples will be discretized as one-hot vectors, + but will be differentiated as if it is the soft sample in autograd + dim (int): + A dimension along which softmax will be computed. Default: -1. + + Returns: + Sampled tensor of same shape as logits from the Gumbel-Softmax distribution. + """ + if version.parse(torch.__version__) < version.parse('1.2.0'): + for i in range(10): + transformed = functional.gumbel_softmax(logits, tau=tau, hard=hard, + eps=eps, dim=dim) + if not torch.isnan(transformed).any(): + return transformed + raise ValueError('gumbel_softmax returning NaN.') + + return functional.gumbel_softmax(logits, tau=tau, hard=hard, eps=eps, dim=dim) + + def _apply_activate(self, data): + """Apply proper activation function to the output of the generator.""" + data_t = [] + st = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if span_info.activation_fn == 'tanh': + ed = st + span_info.dim + data_t.append(torch.tanh(data[:, st:ed])) + st = ed + elif span_info.activation_fn == 'softmax': + ed = st + span_info.dim + transformed = self._gumbel_softmax(data[:, st:ed], tau=0.2) + data_t.append(transformed) + st = ed + else: + raise ValueError(f'Unexpected activation function {span_info.activation_fn}.') + + return torch.cat(data_t, dim=1) + + def _cond_loss(self, data, c, m): + """Compute the cross entropy loss on the fixed discrete column.""" + loss = [] + st = 0 + st_c = 0 + for column_info in self._transformer.output_info_list: + for span_info in column_info: + if len(column_info) != 1 or span_info.activation_fn != 'softmax': + # not discrete column + st += span_info.dim + else: + ed = st + span_info.dim + ed_c = st_c + span_info.dim + tmp = functional.cross_entropy( + data[:, st:ed], + torch.argmax(c[:, st_c:ed_c], dim=1), + reduction='none' + ) + loss.append(tmp) + st = ed + st_c = ed_c + + loss = torch.stack(loss, dim=1) # noqa: PD013 + + return (loss * m).sum() / data.size()[0] + + def _validate_discrete_columns(self, train_data, discrete_columns): + """Check whether ``discrete_columns`` exists in ``train_data``. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + if isinstance(train_data, pd.DataFrame): + invalid_columns = set(discrete_columns) - set(train_data.columns) + elif isinstance(train_data, np.ndarray): + invalid_columns = [] + for column in discrete_columns: + if column < 0 or column >= train_data.shape[1]: + invalid_columns.append(column) + else: + raise TypeError('``train_data`` should be either pd.DataFrame or np.array.') + + if invalid_columns: + raise ValueError(f'Invalid columns found: {invalid_columns}') + + @random_state + def fit(self, train_data, discrete_columns=(), epochs=None): + """Fit the CTGAN Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self._validate_discrete_columns(train_data, discrete_columns) + + if epochs is None: + epochs = self._epochs + else: + warnings.warn( + ('`epochs` argument in `fit` method has been deprecated and will be removed ' + 'in a future version. Please pass `epochs` to the constructor instead'), + DeprecationWarning + ) + + self._transformer = DataTransformer() + self._transformer.fit(train_data, discrete_columns) + + train_data = self._transformer.transform(train_data) + + self._data_sampler = DataSampler( + train_data, + self._transformer.output_info_list, + self._log_frequency) + + data_dim = self._transformer.output_dimensions + + self._generator = Generator( + self._embedding_dim + self._data_sampler.dim_cond_vec(), + self._generator_dim, + data_dim + ).to(self._device) + + discriminator = Discriminator( + data_dim + self._data_sampler.dim_cond_vec(), + self._discriminator_dim, + pac=self.pac + ).to(self._device) + + optimizerG = optim.Adam( + self._generator.parameters(), lr=self._generator_lr, betas=(0.5, 0.9), + weight_decay=self._generator_decay + ) + + optimizerD = optim.Adam( + discriminator.parameters(), lr=self._discriminator_lr, + betas=(0.5, 0.9), weight_decay=self._discriminator_decay + ) + + mean = torch.zeros(self._batch_size, self._embedding_dim, device=self._device) + std = mean + 1 + + print('CTGAN training') + steps_per_epoch = max(len(train_data) // self._batch_size, 1) + for i in range(epochs): + for n in range(self._discriminator_steps): + fakez = torch.normal(mean=mean, std=std) + + condvec = self._data_sampler.sample_condvec(self._batch_size) + if condvec is None: + c1, m1, col, opt = None, None, None, None + real = self._data_sampler.sample_data(self._batch_size, col, opt) + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + perm = np.arange(self._batch_size) + np.random.shuffle(perm) + real = self._data_sampler.sample_data( + self._batch_size, col[perm], opt[perm]) + c2 = c1[perm] + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + real = torch.from_numpy(real.astype('float32')).to(self._device) + + if c1 is not None: + fake_cat = torch.cat([fakeact, c1], dim=1) + real_cat = torch.cat([real, c2], dim=1) + else: + real_cat = real + fake_cat = fakeact + + y_fake = discriminator(fake_cat) + y_real = discriminator(real_cat) + + pen = discriminator.calc_gradient_penalty( + real_cat, fake_cat, self._device, self.pac) + loss_d = -(torch.mean(y_real) - torch.mean(y_fake)) + + optimizerD.zero_grad() + pen.backward(retain_graph=True) + loss_d.backward() + optimizerD.step() + + fakez = torch.normal(mean=mean, std=std) + condvec = self._data_sampler.sample_condvec(self._batch_size) + + if condvec is None: + c1, m1, col, opt = None, None, None, None + else: + c1, m1, col, opt = condvec + c1 = torch.from_numpy(c1).to(self._device) + m1 = torch.from_numpy(m1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + + if c1 is not None: + y_fake = discriminator(torch.cat([fakeact, c1], dim=1)) + else: + y_fake = discriminator(fakeact) + + if condvec is None: + cross_entropy = 0 + else: + cross_entropy = self._cond_loss(fake, c1, m1) + + loss_g = -torch.mean(y_fake) + cross_entropy + + optimizerG.zero_grad() + loss_g.backward() + optimizerG.step() + + if self._verbose and (i + 1) % 1000 == 0: + print(f'Epoch {i+1}, Loss G: {loss_g.detach().cpu(): .4f},' # noqa: T001 + f'Loss D: {loss_d.detach().cpu(): .4f}', + flush=True) + + @random_state + def sample(self, n, condition_column=None, condition_value=None): + """Sample data similar to the training data. + + Choosing a condition_column and condition_value will increase the probability of the + discrete condition_value happening in the condition_column. + + Args: + n (int): + Number of rows to sample. + condition_column (string): + Name of a discrete column. + condition_value (string): + Name of the category in the condition_column which we wish to increase the + probability of happening. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + if condition_column is not None and condition_value is not None: + condition_info = self._transformer.convert_column_name_value_to_id( + condition_column, condition_value) + global_condition_vec = self._data_sampler.generate_cond_from_condition_column_info( + condition_info, self._batch_size) + else: + global_condition_vec = None + + steps = n // self._batch_size + 1 + data = [] + for i in range(steps): + mean = torch.zeros(self._batch_size, self._embedding_dim) + std = mean + 1 + fakez = torch.normal(mean=mean, std=std).to(self._device) + + if global_condition_vec is not None: + condvec = global_condition_vec.copy() + else: + condvec = self._data_sampler.sample_original_condvec(self._batch_size) + + if condvec is None: + pass + else: + c1 = condvec + c1 = torch.from_numpy(c1).to(self._device) + fakez = torch.cat([fakez, c1], dim=1) + + fake = self._generator(fakez) + fakeact = self._apply_activate(fake) + data.append(fakeact.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:n] + + return self._transformer.inverse_transform(data) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + if self._generator is not None: + self._generator.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..1baa3f38a8157b80fb866c205491616543fb0470 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/ctgan/synthesizers/tvae.py @@ -0,0 +1,218 @@ +"""TVAESynthesizer module.""" + +import numpy as np +import torch +from torch.nn import Linear, Module, Parameter, ReLU, Sequential +from torch.nn.functional import cross_entropy +from torch.optim import Adam +from torch.utils.data import DataLoader, TensorDataset + +from ..data_transformer import DataTransformer +from .base import BaseSynthesizer, random_state + + +class Encoder(Module): + """Encoder for the TVAESynthesizer. + + Args: + data_dim (int): + Dimensions of the data. + compress_dims (tuple or list of ints): + Size of each hidden layer. + embedding_dim (int): + Size of the output vector. + """ + + def __init__(self, data_dim, compress_dims, embedding_dim): + super(Encoder, self).__init__() + dim = data_dim + seq = [] + for item in list(compress_dims): + seq += [ + Linear(dim, item), + ReLU() + ] + dim = item + + self.seq = Sequential(*seq) + self.fc1 = Linear(dim, embedding_dim) + self.fc2 = Linear(dim, embedding_dim) + + def forward(self, input_): + """Encode the passed `input_`.""" + feature = self.seq(input_) + mu = self.fc1(feature) + logvar = self.fc2(feature) + std = torch.exp(0.5 * logvar) + return mu, std, logvar + + +class Decoder(Module): + """Decoder for the TVAESynthesizer. + + Args: + embedding_dim (int): + Size of the input vector. + decompress_dims (tuple or list of ints): + Size of each hidden layer. + data_dim (int): + Dimensions of the data. + """ + + def __init__(self, embedding_dim, decompress_dims, data_dim): + super(Decoder, self).__init__() + dim = embedding_dim + seq = [] + for item in list(decompress_dims): + seq += [Linear(dim, item), ReLU()] + dim = item + + seq.append(Linear(dim, data_dim)) + self.seq = Sequential(*seq) + self.sigma = Parameter(torch.ones(data_dim) * 0.1) + + def forward(self, input_): + """Decode the passed `input_`.""" + return self.seq(input_), self.sigma + + +def _loss_function(recon_x, x, sigmas, mu, logvar, output_info, factor): + st = 0 + loss = [] + for column_info in output_info: + for span_info in column_info: + if span_info.activation_fn != 'softmax': + ed = st + span_info.dim + std = sigmas[st] + eq = x[:, st] - torch.tanh(recon_x[:, st]) + loss.append((eq ** 2 / 2 / (std ** 2)).sum()) + loss.append(torch.log(std) * x.size()[0]) + st = ed + + else: + ed = st + span_info.dim + loss.append(cross_entropy( + recon_x[:, st:ed], torch.argmax(x[:, st:ed], dim=-1), reduction='sum')) + st = ed + + assert st == recon_x.size()[1] + KLD = -0.5 * torch.sum(1 + logvar - mu**2 - logvar.exp()) + return sum(loss) * factor / x.size()[0], KLD / x.size()[0] + + +class TVAESynthesizer(BaseSynthesizer): + """TVAESynthesizer.""" + + def __init__( + self, + embedding_dim=128, + compress_dims=(128, 128), + decompress_dims=(128, 128), + l2scale=1e-5, + batch_size=500, + epochs=300, + lr=1e-3, + loss_factor=2, + device="cuda:0" + ): + self.embedding_dim = embedding_dim + self.compress_dims = compress_dims + self.decompress_dims = decompress_dims + + self.lr = lr + self.l2scale = l2scale + self.batch_size = batch_size + self.loss_factor = loss_factor + self.epochs = epochs + + + self._device = torch.device(device) + + @random_state + def fit(self, train_data, discrete_columns=()): + """Fit the TVAE Synthesizer models to the training data. + + Args: + train_data (numpy.ndarray or pandas.DataFrame): + Training Data. It must be a 2-dimensional numpy array or a pandas.DataFrame. + discrete_columns (list-like): + List of discrete columns to be used to generate the Conditional + Vector. If ``train_data`` is a Numpy array, this list should + contain the integer indices of the columns. Otherwise, if it is + a ``pandas.DataFrame``, this list should contain the column names. + """ + self.transformer = DataTransformer() + self.transformer.fit(train_data, discrete_columns) + train_data = self.transformer.transform(train_data) + dataset = TensorDataset(torch.from_numpy(train_data.astype('float32'))) + loader = DataLoader(dataset, batch_size=self.batch_size, shuffle=True, drop_last=False) + + data_dim = self.transformer.output_dimensions + encoder = Encoder(data_dim, self.compress_dims, self.embedding_dim).to(self._device) + self.decoder = Decoder(self.embedding_dim, self.decompress_dims, data_dim).to(self._device) + optimizerAE = Adam( + list(encoder.parameters()) + list(self.decoder.parameters()), + lr=self.lr, + weight_decay=self.l2scale) + data_iter = iter(loader) + print('Training:') + for i in range(self.epochs): + try: + data = next(data_iter) + except: + data_iter = iter(loader) + data = next(data_iter) + + optimizerAE.zero_grad() + real = data[0].to(self._device) + mu, std, logvar = encoder(real) + eps = torch.randn_like(std) + emb = eps * std + mu + rec, sigmas = self.decoder(emb) + loss_1, loss_2 = _loss_function( + rec, real, sigmas, mu, logvar, + self.transformer.output_info_list, self.loss_factor + ) + loss = loss_1 + loss_2 + loss.backward() + optimizerAE.step() + self.decoder.sigma.data.clamp_(0.01, 1.0) + if (i + 1) % 1000 == 0: + print(f"{i + 1}/{self.epochs} {loss}", flush=True) + + @random_state + def sample(self, samples, seed=0): + """Sample data similar to the training data. + + Args: + samples (int): + Number of rows to sample. + + Returns: + numpy.ndarray or pandas.DataFrame + """ + + torch.cuda.manual_seed(seed) + torch.manual_seed(seed) + + self.decoder.eval() + + sample_batch_size = 8092 + steps = samples // sample_batch_size + 1 + data = [] + for _ in range(steps): + mean = torch.zeros(sample_batch_size, self.embedding_dim) + std = mean + 1 + noise = torch.normal(mean=mean, std=std).to(self._device) + fake, sigmas = self.decoder(noise) + fake = torch.tanh(fake) + data.append(fake.detach().cpu().numpy()) + + data = np.concatenate(data, axis=0) + data = data[:samples] + return self.transformer.inverse_transform(data, sigmas.detach().cpu().numpy()) + + def set_device(self, device): + """Set the `device` to be used ('GPU' or 'CPU).""" + self._device = device + self.decoder.to(self._device) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg new file mode 100644 index 0000000000000000000000000000000000000000..8398eee0de75e378fa157456b8594f9ec383c45c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.cfg @@ -0,0 +1,59 @@ +[bumpversion] +current_version = 0.5.2.dev0 +commit = True +tag = True +parse = (?P\d+)\.(?P\d+)\.(?P\d+)(\.(?P[a-z]+)(?P\d+))? +serialize = + {major}.{minor}.{patch}.{release}{candidate} + {major}.{minor}.{patch} + +[bumpversion:part:release] +optional_value = release +first_value = dev +values = + dev + release + +[bumpversion:part:candidate] + +[bumpversion:file:setup.py] +search = version='{current_version}' +replace = version='{new_version}' + +[bumpversion:file:ctgan/__init__.py] +search = __version__ = '{current_version}' +replace = __version__ = '{new_version}' + +[bumpversion:file:conda/meta.yaml] +search = version = '{current_version}' +replace = version = '{new_version}' + +[bdist_wheel] +universal = 1 + +[flake8] +convention = google +max-line-length = 99 +exclude = docs, .tox, .git, __pycache__, .ipynb_checkpoints +extend-ignore = D107, # Missing docstring in __init__ + D407, # Missing dashed underline after section + D417, # Missing argument descriptions in the docstring + SFS3, # String literal formatting using f-string. + VNE001 # Single letter variable names are not allowed +per-file-ignores = + ctgan/data.py:T001 + +[isort] +include_trailing_comment = True +line_length = 99 +lines_between_types = 0 +multi_line_output = 4 +not_skip = __init__.py +use_parentheses = True + +[aliases] +test = pytest + +[tool:pytest] +collect_ignore = ['setup.py'] + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.py new file mode 100644 index 0000000000000000000000000000000000000000..83d973eb603ce5a4f4dc31f3bac459eeabdd1ec5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/setup.py @@ -0,0 +1,119 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""The setup script.""" + +from setuptools import find_packages, setup + +with open('README.md', encoding='utf-8') as readme_file: + readme = readme_file.read() + +with open('HISTORY.md', encoding='utf-8') as history_file: + history = history_file.read() + +install_requires = [ + 'packaging>=20,<22', + "numpy>=1.18.0,<1.20.0;python_version<'3.7'", + "numpy>=1.20.0,<2;python_version>='3.7'", + 'pandas>=1.1.3,<2', + 'scikit-learn>=0.24,<2', + 'torch>=1.8.0,<2', + 'torchvision>=0.9.0,<1', + 'rdt>=0.6.2,<0.7', +] + +setup_requires = [ + 'pytest-runner>=2.11.1', +] + +tests_require = [ + 'pytest>=3.4.2', + 'pytest-rerunfailures>=9.1.1,<10', + 'pytest-cov>=2.6.0', +] + +development_requires = [ + # general + 'pip>=9.0.1', + 'bumpversion>=0.5.3,<0.6', + 'watchdog>=0.8.3,<0.11', + + # style check + 'flake8>=3.7.7,<4', + 'isort>=4.3.4,<5', + 'dlint>=0.11.0,<0.12', # code security addon for flake8 + 'flake8-debugger>=4.0.0,<4.1', + 'flake8-mock>=0.3,<0.4', + 'flake8-mutable>=1.2.0,<1.3', + 'flake8-absolute-import>=1.0,<2', + 'flake8-multiline-containers>=0.0.18,<0.1', + 'flake8-print>=4.0.0,<4.1', + 'flake8-quotes>=3.3.0,<4', + 'flake8-fixme>=1.1.1,<1.2', + 'flake8-expression-complexity>=0.0.9,<0.1', + 'flake8-eradicate>=1.1.0,<1.2', + 'flake8-builtins>=1.5.3,<1.6', + 'flake8-variables-names>=0.0.4,<0.1', + 'pandas-vet>=0.2.2,<0.3', + 'flake8-comprehensions>=3.6.1,<3.7', + 'dlint>=0.11.0,<0.12', + 'flake8-docstrings>=1.5.0,<2', + 'flake8-sfs>=0.0.3,<0.1', + 'flake8-pytest-style>=1.5.0,<2', + + # fix style issues + 'autoflake>=1.1,<2', + 'autopep8>=1.4.3,<1.6', + + # distribute on PyPI + 'twine>=1.10.0,<4', + 'wheel>=0.30.0', + + # Advanced testing + 'coverage>=4.5.1,<6', + 'tox>=2.9.1,<4', + + 'invoke', +] + +setup( + author='MIT Data To AI Lab', + author_email='dailabmit@gmail.com', + classifiers=[ + 'Development Status :: 2 - Pre-Alpha', + 'Intended Audience :: Developers', + 'License :: OSI Approved :: MIT License', + 'Natural Language :: English', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + ], + description='Conditional GAN for Tabular Data', + entry_points={ + 'console_scripts': [ + 'ctgan=ctgan.__main__:main' + ], + }, + extras_require={ + 'test': tests_require, + 'dev': development_requires + tests_require, + }, + install_package_data=True, + install_requires=install_requires, + license='MIT license', + long_description=readme + '\n\n' + history, + long_description_content_type='text/markdown', + include_package_data=True, + keywords='ctgan CTGAN', + name='ctgan', + packages=find_packages(include=['ctgan', 'ctgan.*']), + python_requires='>=3.6,<3.10', + setup_requires=setup_requires, + test_suite='tests', + tests_require=tests_require, + url='https://github.com/sdv-dev/CTGAN', + version='0.5.2.dev0', + zip_safe=False, +) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tasks.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tasks.py new file mode 100644 index 0000000000000000000000000000000000000000..78730cea28cec928ff175364db655f10abe6143e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tasks.py @@ -0,0 +1,121 @@ +import glob +import operator +import os +import re +import platform +import shutil +import stat +from pathlib import Path + +from invoke import task + +COMPARISONS = { + '>=': operator.ge, + '>': operator.gt, + '<': operator.lt, + '<=': operator.le +} + + +@task +def check_dependencies(c): + c.run('python -m pip check') + + +@task +def unit(c): + c.run('python -m pytest ./tests/unit --cov=ctgan --cov-report=xml') + + +@task +def integration(c): + c.run('python -m pytest ./tests/integration --reruns 3') + + +@task +def readme(c): + test_path = Path('tests/readme_test') + if test_path.exists() and test_path.is_dir(): + shutil.rmtree(test_path) + + cwd = os.getcwd() + os.makedirs(test_path, exist_ok=True) + shutil.copy('README.md', test_path / 'README.md') + os.chdir(test_path) + c.run('rundoc run --single-session python3 -t python3 README.md') + os.chdir(cwd) + shutil.rmtree(test_path) + + +def _validate_python_version(line): + python_version_match = re.search(r"python_version(<=?|>=?)\'(\d\.?)+\'", line) + if python_version_match: + python_version = python_version_match.group(0) + comparison = re.search(r'(>=?|<=?)', python_version).group(0) + version_number = python_version.split(comparison)[-1].replace("'", "") + comparison_function = COMPARISONS[comparison] + return comparison_function(platform.python_version(), version_number) + + return True + + +@task +def install_minimum(c): + with open('setup.py', 'r') as setup_py: + lines = setup_py.read().splitlines() + + versions = [] + started = False + for line in lines: + if started: + if line == ']': + started = False + continue + + line = line.strip() + if _validate_python_version(line): + requirement = re.match(r'[^>]*', line).group(0) + requirement = re.sub(r"""['",]""", '', requirement) + version = re.search(r'>=?[^(,|#)]*', line).group(0) + if version: + version = re.sub(r'>=?', '==', version) + version = re.sub(r"""['",]""", '', version) + requirement += version + + versions.append(requirement) + + elif (line.startswith('install_requires = [') or + line.startswith('pomegranate_requires = [')): + started = True + + c.run(f'python -m pip install {" ".join(versions)}') + + +@task +def minimum(c): + install_minimum(c) + check_dependencies(c) + unit(c) + integration(c) + + +@task +def lint(c): + check_dependencies(c) + c.run('flake8 ctgan') + c.run('flake8 tests --ignore=D101') + c.run('isort -c --recursive ctgan tests') + + +def remove_readonly(func, path, _): + "Clear the readonly bit and reattempt the removal" + os.chmod(path, stat.S_IWRITE) + func(path) + + +@task +def rmdir(c, path): + try: + shutil.rmtree(path, onerror=remove_readonly) + except PermissionError: + pass diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..a750d3dabc716a49fb722dbbb87e7a2120fc5fd4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_ctgan.py @@ -0,0 +1,275 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for ctgan. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import tempfile as tf + +import numpy as np +import pandas as pd +import pytest + +from ctgan.synthesizers.ctgan import CTGANSynthesizer + + +def test_ctgan_no_categoricals(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000) + }) + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, []) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 1) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous'} + + +def test_ctgan_dataframe(): + """Test the CTGANSynthesizer when passed a dataframe.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_ctgan_numpy(): + """Test the CTGANSynthesizer when passed a numpy array.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = [1] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data.to_numpy(), discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, np.ndarray) + assert set(np.unique(sampled[:, 1])) == {'a', 'b', 'c'} + + +def test_log_frequency(): + """Test the CTGANSynthesizer with no `log_frequency` set to False.""" + data = pd.DataFrame({ + 'continuous': np.random.random(1000), + 'discrete': np.repeat(['a', 'b', 'c'], [950, 25, 25]) + }) + + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] < 6500 + + ctgan = CTGANSynthesizer(log_frequency=False, epochs=100) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(10000) + counts = sampled['discrete'].value_counts() + assert counts['a'] > 9000 + + +def test_categorical_nan(): + """Test the CTGANSynthesizer with no categorical values.""" + data = pd.DataFrame({ + 'continuous': np.random.random(30), + # This must be a list (not a np.array) or NaN will be cast to a string. + 'discrete': [np.nan, 'b', 'c'] * 10 + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + sampled = ctgan.sample(100) + + assert sampled.shape == (100, 2) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == {'continuous', 'discrete'} + + # since np.nan != np.nan, we need to be careful here + values = set(sampled['discrete'].unique()) + assert len(values) == 3 + assert any(pd.isna(x) for x in values) + assert {'b', 'c'}.issubset(values) + + +def test_synthesizer_sample(): + """Test the CTGANSynthesizer samples the correct datatype.""" + data = pd.DataFrame({ + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + samples = ctgan.sample(1000, 'discrete', 'a') + assert isinstance(samples, pd.DataFrame) + + +def test_save_load(): + """Test the CTGANSynthesizer load/save methods.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with tf.TemporaryDirectory() as temporary_directory: + ctgan.save(temporary_directory + 'test_tvae.pkl') + ctgan = CTGANSynthesizer.load(temporary_directory + 'test_tvae.pkl') + + sampled = ctgan.sample(1000) + assert set(sampled.columns) == {'continuous', 'discrete'} + assert set(sampled['discrete'].unique()) == {'a', 'b', 'c'} + + +def test_wrong_discrete_columns_dataframe(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['b', 'c'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match="Invalid columns found: {'.*', '.*'}"): + ctgan.fit(data, discrete_columns) + + +def test_wrong_discrete_columns_numpy(): + """Test the CTGANSynthesizer correctly crashes when passed non-existing discrete columns.""" + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = [0, 1] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: \[1\]'): + ctgan.fit(data.to_numpy(), discrete_columns) + + +def test_wrong_sampling_conditions(): + """Test the CTGANSynthesizer correctly crashes when passed incorrect sampling conditions.""" + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + ctgan.fit(data, discrete_columns) + + with pytest.raises(ValueError, match="The column_name `cardinal` doesn't exist in the data."): + ctgan.sample(1, 'cardinal', "doesn't matter") + + with pytest.raises(ValueError): # noqa: RDT currently incorrectly raises a tuple instead of a string + ctgan.sample(1, 'discrete', 'd') + + +def test_fixed_random_seed(): + """Test the CTGANSynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + ctgan = CTGANSynthesizer(epochs=1) + + # Run + ctgan.fit(data, discrete_columns) + sampled_random = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_0_0 = ctgan.sample(10) + sampled_0_1 = ctgan.sample(10) + + ctgan.set_random_state(0) + sampled_1_0 = ctgan.sample(10) + sampled_1_1 = ctgan.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) + + +# Below are CTGAN tests that should be implemented in the future +def test_continuous(): + """Test training the CTGAN synthesizer on a continuous dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using kstest: + # - uniform (assert p-value > 0.05) + # - gaussian (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical(): + """Test training the CTGAN synthesizer on a categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_categorical_log_frequency(): + """Test training the CTGAN synthesizer on a small categorical dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using cstest: + # - uniform (assert p-value > 0.05) + # - very skewed / biased? (assert p-value > 0.05) + # - inversely correlated (assert correlation < 0) + + +def test_mixed(): + """Test training the CTGAN synthesizer on a small mixed-type dataset.""" + # assert the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test_conditional(): + """Test training the CTGAN synthesizer and sampling conditioned on a categorical.""" + # verify that conditioning increases the likelihood of getting a sample with the specified + # categorical value + + +def test_batch_size_pack_size(): + """Test that if batch size is not a multiple of pack size, it raises a sane error.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..ab8c583e0dd11fee3e1ce3d5cd4ac8f0a847a192 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/synthesizer/test_tvae.py @@ -0,0 +1,131 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +"""Integration tests for tvae. + +These tests only ensure that the software does not crash and that +the API works as expected in terms of input and output data formats, +but correctness of the data values and the internal behavior of the +model are not checked. +""" + +import numpy as np +import pandas as pd +from sklearn import datasets + +from ctgan.synthesizers.tvae import TVAESynthesizer + + +def test_tvae(tmpdir): + """Test the TVAESynthesizer load/save methods.""" + iris = datasets.load_iris() + data = pd.DataFrame(iris.data, columns=iris.feature_names) + data['class'] = pd.Series(iris.target).map(iris.target_names.__getitem__) + + tvae = TVAESynthesizer(epochs=10) + tvae.fit(data, ['class']) + + path = str(tmpdir / 'test_tvae.pkl') + tvae.save(path) + tvae = TVAESynthesizer.load(path) + + sampled = tvae.sample(100) + + assert sampled.shape == (100, 5) + assert isinstance(sampled, pd.DataFrame) + assert set(sampled.columns) == set(data.columns) + assert set(sampled.dtypes) == set(data.dtypes) + + +def test_drop_last_false(): + """Test the TVAESynthesizer predicts the correct values.""" + data = pd.DataFrame({ + '1': ['a', 'b', 'c'] * 150, + '2': ['a', 'b', 'c'] * 150 + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data, ['1', '2']) + + sampled = tvae.sample(100) + correct = 0 + for _, row in sampled.iterrows(): + if row['1'] == row['2']: + correct += 1 + + assert correct >= 95 + + +# TVAE tests that should be implemented in the future. +def test_continuous(): + """Test training the TVAE synthesizer on a small continuous dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest. + + +def test_categorical(): + """Test training the TVAE synthesizer on a small categorical dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a cstest. + + +def test_mixed(): + """Test training the TVAE synthesizer on a small mixed-type dataset.""" + # verify that the distribution of the samples is close to the distribution of the data + # using a kstest for continuous + a cstest for categorical. + + +def test__loss_function(): + """Test the TVAESynthesizer produces average values similar to the training data.""" + data = pd.DataFrame({ + '1': [float(i) for i in range(1000)], + '2': [float(2 * i) for i in range(1000)] + }) + + tvae = TVAESynthesizer(epochs=300) + tvae.fit(data) + + num_samples = 1000 + sampled = tvae.sample(num_samples) + error = 0 + for _, row in sampled.iterrows(): + error += abs(2 * row['1'] - row['2']) + + avg_error = error / num_samples + + assert avg_error < 400 + + +def test_fixed_random_seed(): + """Test the TVAESynthesizer with a fixed seed. + + Expect that when the random seed is reset with the same seed, the same sequence + of data will be produced. Expect that the data generated with the seed is + different than randomly sampled data. + """ + # Setup + data = pd.DataFrame({ + 'continuous': np.random.random(100), + 'discrete': np.random.choice(['a', 'b', 'c'], 100) + }) + discrete_columns = ['discrete'] + + tvae = TVAESynthesizer(epochs=1) + + # Run + tvae.fit(data, discrete_columns) + sampled_random = tvae.sample(10) + + tvae.set_random_state(0) + sampled_0_0 = tvae.sample(10) + sampled_0_1 = tvae.sample(10) + + tvae.set_random_state(0) + sampled_1_0 = tvae.sample(10) + sampled_1_1 = tvae.sample(10) + + # Assert + assert not np.array_equal(sampled_random, sampled_0_0) + assert not np.array_equal(sampled_random, sampled_0_1) + np.testing.assert_array_equal(sampled_0_0, sampled_1_0) + np.testing.assert_array_equal(sampled_0_1, sampled_1_1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..2f0314ca08a4cbd05d2dba7560edeeab57780306 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/integration/test_data_transformer.py @@ -0,0 +1,42 @@ +"""Data transformer intergration testing module.""" + + +# Data Transformer tests that should be implemented in the future. +def test_constant(): + """Test transforming a dataframe containing constant values.""" + + +def test_df_continuous(): + """Test transforming a dataframe containing only continuous values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is **not** deterministic + # make sure it can be inverted + + +def test_df_categorical(): + """Test transforming a dataframe containing only categorical values.""" + # validate output ranges [0, 1] + # validate output shape (# samples, # output dims) + # validate that forward transform is deterministic + # make sure it can be inverted + + +def test_df_mixed(): + """Test transforming a dataframe containing mixed data types.""" + + +def test_df_mixed_nan(): + """Test transforming a dataframe containing mixed data types + NaN for categoricals.""" + + +def test_np_continuous(): + """Test transforming a np.array containing only continuous values.""" + + +def test_np_categorical(): + """Test transforming a np.array containing only categorical values.""" + + +def test_np_mixed(): + """Test transforming a np.array containing mixed data types.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..60ff4d04eff14032ccb698a80a37aa16cb4ff1ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/__init__.py @@ -0,0 +1 @@ +"""Unit testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..80d7afbb190ef7d1204849cae14f6a89312c39f7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/__init__.py @@ -0,0 +1 @@ +"""CTGANSynthesizer testing module.""" diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py new file mode 100644 index 0000000000000000000000000000000000000000..5859d93deb2bebe6f07faf0a7c3b08c841e66546 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_base.py @@ -0,0 +1,111 @@ + +"""BaseSynthesizer unit testing module.""" + +from unittest.mock import MagicMock, call, patch + +import numpy as np +import torch + +from ctgan.synthesizers.base import BaseSynthesizer, random_state + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_valid_random_state(random_mock, torch_mock): + """Test the ``random_state`` attribute with a valid random state. + + Expect that the decorated function uses the random_state attribute. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + + random_state_mock = MagicMock() + random_state_mock.get_state.return_value = 'desired numpy state' + torch_generator_mock = MagicMock() + torch_generator_mock.get_state.return_value = 'desired torch state' + instance.random_states = (random_state_mock, torch_generator_mock) + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + random_mock.RandomState.return_value = random_state_mock + random_mock.get_state.return_value = 'random state' + torch_mock.Generator.return_value = torch_generator_mock + torch_mock.get_rng_state.return_value = 'torch random state' + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + assert random_mock.get_state.call_count == 2 + assert torch_mock.get_rng_state.call_count == 2 + random_mock.RandomState.assert_has_calls( + [call().get_state(), call(), call().set_state('random state')]) + random_mock.set_state.assert_has_calls([call('desired numpy state'), call('random state')]) + torch_mock.set_rng_state.assert_has_calls( + [call('desired torch state'), call('torch random state')]) + + +@patch('ctgan.synthesizers.base.torch') +@patch('ctgan.synthesizers.base.np.random') +def test_no_random_seed(random_mock, torch_mock): + """Test the ``random_state`` attribute with no random state. + + Expect that the decorated function calls the original function + when there is no random state. + """ + # Setup + my_function = MagicMock() + instance = MagicMock() + instance.random_states = None + + args = {'some', 'args'} + kwargs = {'keyword': 'value'} + + # Run + decorated_function = random_state(my_function) + decorated_function(instance, *args, **kwargs) + + # Assert + my_function.assert_called_once_with(instance, *args, **kwargs) + + instance.assert_not_called + random_mock.get_state.assert_not_called() + random_mock.RandomState.assert_not_called() + random_mock.set_state.assert_not_called() + torch_mock.get_rng_state.assert_not_called() + torch_mock.Generator.assert_not_called() + torch_mock.set_rng_state.assert_not_called() + + +class TestBaseSynthesizer: + + def test_set_random_state(self): + """Test ``set_random_state`` works as expected.""" + # Setup + instance = BaseSynthesizer() + + # Run + instance.set_random_state(3) + + # Assert + assert isinstance(instance.random_states, tuple) + assert isinstance(instance.random_states[0], np.random.RandomState) + assert isinstance(instance.random_states[1], torch.Generator) + + def test_set_random_state_with_none(self): + """Test ``set_random_state`` with None.""" + # Setup + instance = BaseSynthesizer() + + # Run and assert + instance.set_random_state(3) + assert instance.random_states is not None + + instance.set_random_state(None) + assert instance.random_states is None diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py new file mode 100644 index 0000000000000000000000000000000000000000..7a724d30779cea4e9512fc480e8417c17a21da7a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_ctgan.py @@ -0,0 +1,343 @@ +"""CTGANSynthesizer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock + +import pandas as pd +import pytest +import torch + +from ctgan.data_transformer import SpanInfo +from ctgan.synthesizers.ctgan import CTGANSynthesizer, Discriminator, Generator, Residual + + +class TestDiscriminator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 3*`discriminator_dim` + 1. + + Setup: + - Create Discriminator + + Input: + - input_dim = positive integer + - discriminator_dim = list of integers + - pack = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.pack` and `self.packdim` + """ + discriminator_dim = [1, 2, 3] + discriminator = Discriminator(input_dim=50, discriminator_dim=discriminator_dim, pac=7) + + assert discriminator.pac == 7 + assert discriminator.pacdim == 350 + assert len(discriminator.seq) == 3 * len(discriminator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. Notice that the input_dim = input_size. + + Setup: + - initialize with input_size, discriminator_dim, pac + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N/pac, 1) + """ + discriminator = Discriminator(input_dim=50, discriminator_dim=[100, 200, 300], pac=7) + output = discriminator(torch.randn(70, 50)) + assert output.shape == (10, 1) + + # Check to make sure no gradients attached + for parameter in discriminator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in discriminator.parameters(): + assert parameter.grad is not None + + +class TestResidual(TestCase): + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with input_size, output_size + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, input_size + output_size) + """ + residual = Residual(10, 2) + output = residual(torch.randn(100, 10)) + assert output.shape == (100, 12) + + # Check to make sure no gradients attached + for parameter in residual.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in residual.parameters(): + assert parameter.grad is not None + + +class TestGenerator(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure `self.seq` has same length as `generator_dim` + 1. + + Setup: + - Create Generator + + Input: + - embedding_dim = positive integer + - generator_dim = list of integers + - data_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq` + """ + generator_dim = [1, 2, 3] + generator = Generator(embedding_dim=50, generator_dim=generator_dim, data_dim=7) + + assert len(generator.seq) == len(generator_dim) + 1 + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(output)`. + + Setup: + - initialize with embedding_dim, generator_dim, data_dim + - Create random tensor as input + + Input: + - input = random tensor of shape (N, input_size) + + Output: + - tensor of shape (N, data_dim) + """ + generator = Generator(embedding_dim=60, generator_dim=[100, 200, 300], data_dim=500) + output = generator(torch.randn(70, 60)) + assert output.shape == (70, 500) + + # Check to make sure no gradients attached + for parameter in generator.parameters(): + assert parameter.grad is None + + # Backpropagate + output.mean().backward() + + # Check to make sure all parameters have gradients + for parameter in generator.parameters(): + assert parameter.grad is not None + + +def _assert_is_between(data, lower, upper): + """Assert all values of the tensor 'data' are within range.""" + assert all((data >= lower).numpy().tolist()) + assert all((data <= upper).numpy().tolist()) + + +class TestCTGANSynthesizer(TestCase): + + def test__apply_activate_(self): + """Test `_apply_activate` for tables with both continuous and categoricals. + + Check every continuous column has all values between -1 and 1 + (since they are normalized), and check every categorical column adds up to 1. + + Setup: + - Mock `self._transformer.output_info_list` + + Input: + - data = tensor of shape (N, data_dims) + + Output: + - tensor = tensor of shape (N, data_dims) + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(3, 'softmax')], + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')] + ] + + data = torch.randn(100, 6) + result = model._apply_activate(data) + + assert result.shape == (100, 6) + _assert_is_between(result[:, 0:3], 0.0, 1.0) + _assert_is_between(result[: 3], -1.0, 1.0) + _assert_is_between(result[:, 4:6], 0.0, 1.0) + + def test__cond_loss(self): + """Test `_cond_loss`. + + Test that the loss is purely a function of the target categorical. + + Setup: + - mock transformer.output_info_list + - create two categoricals, one continuous + - compute the conditional loss, conditioned on the 1st categorical + - compare the loss to the cross-entropy of the 1st categorical, manually computed + + Input: + data - the synthetic data generated by the model + c - a tensor with the same shape as the data but with only a specific one-hot vector + corresponding to the target column filled in + m - binary mask used to select the categorical column to condition on + + Output: + loss scalar; this should only be affected by the target column + + Note: + - even though the implementation of this is probably right, I'm not sure if the idea + behind it is correct + """ + model = CTGANSynthesizer() + model._transformer = Mock() + model._transformer.output_info_list = [ + [SpanInfo(1, 'tanh'), SpanInfo(2, 'softmax')], + [SpanInfo(3, 'softmax')], # this is the categorical column we are conditioning on + [SpanInfo(2, 'softmax')], # this is the categorical column we are bry jrbec on + ] + + data = torch.tensor([ + # first 3 dims ignored, next 3 dims are the prediction, last 2 dims are ignored + [0.0, -1.0, 0.0, 0.05, 0.05, 0.9, 0.1, 0.4], + ]) + + c = torch.tensor([ + # first 3 dims are a one-hot for the categorical, + # next 2 are for a different categorical that we are not conditioning on + # (continuous values are not stored in this tensor) + [0.0, 0.0, 1.0, 0.0, 0.0], + ]) + + # this indicates that we are conditioning on the first categorical + m = torch.tensor([[1, 0]]) + + result = model._cond_loss(data, c, m) + expected = torch.nn.functional.cross_entropy( + torch.tensor([ + [0.05, 0.05, 0.9], # 3 categories, one hot + ]), + torch.tensor([2]) + ) + + assert (result - expected).abs() < 1e-3 + + def test__validate_discrete_columns(self): + """Test `_validate_discrete_columns` if the discrete column doesn't exist. + + Check the appropriate error is raised if `discrete_columns` is invalid, both + for numpy arrays and dataframes. + + Setup: + - Create dataframe with a discrete column + - Define `discrete_columns` as something not in the dataframe + + Input: + - train_data = 2-dimensional numpy array or a pandas.DataFrame + - discrete_columns = list of strings or integers + + Output: + None + + Side Effects: + - Raises error if the discrete column is invalid. + + Note: + - could create another function for numpy array + """ + data = pd.DataFrame({ + 'discrete': ['a', 'b'] + }) + discrete_columns = ['doesnt exist'] + + ctgan = CTGANSynthesizer(epochs=1) + with pytest.raises(ValueError, match=r'Invalid columns found: {\'doesnt exist\'}'): + ctgan.fit(data, discrete_columns) + + def test_sample(self): + """Test `sample` correctly sets `condition_info` and `global_condition_vec`. + + Tests the first 7 lines of sample by mocking the DataTransformer and DataSampler + and checking that they are being correctly used. + + Setup: + - Create and fit the synthesizer + - Mock DataTransformer, DataSampler + + Input: + - n = integer + - condition_column = string (not None) + - condition_value = string (not None) + + Output: + Not relevant + + Note: + - I'm not sure we need this test + """ + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cff981a86078d1689bec7bb5a37856aa903b68e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/synthesizer/test_tvae.py @@ -0,0 +1,123 @@ +"""TVAESynthesizer unit testing module.""" + +from unittest import TestCase + + +class TestEncoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`compress_dims`. + + Setup: + - Create Encoder + + Input: + - data_dim = positive integer + - compress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.fc1` and `self.fc2` + """ + + def test_forward(self): + """Test `test_forward` for a generic case. + + Check that the output shapes are correct and that std is positive. + We can also test that all parameters have a gradient attached to them + by running `encoder.parameters()`. To do that, we just need to use `loss.backward()` + for some loss, like `loss = torch.mean(mu) + torch.mean(std) + torch.mean(logvar)`. + + Setup: + - Create random tensor + + Input: + - input = random tensor of shape (N, data_dim) + + Output: + - Tuple of (mu, std, logvar): + mu - tensor of shape (N, embedding_dim) + std - tensor of shape (N, embedding_dim), non-negative values + logvar - tensor of shape (N, embedding_dim) + """ + + +class TestDecoder(TestCase): + + def test___init__(self): + """Test `__init__` for a generic case. + + Make sure 'self.seq' has same length as 2*`decompress_dims` + 1. + + Setup: + - Create Decoder + + Input: + - data_dim = positive integer + - decompress_dims = list of integers + - embedding_dim = positive integer + + Output: + - None + + Side Effects: + - Set `self.seq`, `self.sigma` + """ + + +class TestLossFunction(TestCase): + + def test__loss_function(self): + """Test `_loss_function`. + + Check loss values = to specific numbers. + + Setup: + Build all the tensors, lists, etc. + + Input: + recon_x = tensor of shape (N, data_dims) + x = tensor of shape (N, data_dims) + sigmas = tensor of shape (N,) + mu = tensor of shape (N,) + logvar = tensor of shape (N,) + output_info = list of SpanInfo objects from the data transformer, + including at least 1 continuous and 1 discrete + factor = scalar + + Output: + reconstruction loss = scalar = f(recon_x, x, sigmas, output_info, factor) + kld loss = scalar = f(logvar, mu) + """ + + +class TestTVAESynthesizer(TestCase): + + def test_set_device(self): + """Test 'set_device' if a GPU is available. + + Check that decoder/encoder can successfully be moved to the device. + If the machine doesn't have a GPU, this test shouldn't run. + + Setup: + - Move decoder/encoder to device + + Input: + - device = string + + Output: + None + + Side Effects: + - Set `self._device` to `device` + - Moves `self.decoder` to `self._device` + + Note: + - Need to be careful when checking whether the encoder is actually set + to the right device, since it's not saved (it's only used in fit). + """ diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py new file mode 100644 index 0000000000000000000000000000000000000000..305f84ee5e57d156348b54400a5c6138d3466b40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tests/unit/test_data_transformer.py @@ -0,0 +1,473 @@ +"""Data transformer unit testing module.""" + +from unittest import TestCase +from unittest.mock import Mock, patch + +import numpy as np +import pandas as pd + +from ctgan.data_transformer import ColumnTransformInfo, DataTransformer, SpanInfo + + +class TestDataTransformer(TestCase): + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test___fit_continuous(self, MockBGM): + """Test ``_fit_continuous`` on a simple continuous column. + + A ``BayesGMMTransformer`` will be created and fit with some ``data``. + + Setup: + - Mock the ``BayesGMMTransformer`` with ``valid_component_indicator`` as + ``[True, False, True]``. + - Initialize a ``DataTransformer``. + + Input: + - A dataframe with only one column containing random float values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``BayesGMMTransformer`` instance. + - ``output_dimensions`` is 3 (matches size of ``valid_component_indicator``). + - ``output_info`` assigns the correct activation functions. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.valid_component_indicator = [True, False, True] + transformer = DataTransformer() + data = pd.DataFrame(np.random.normal((100, 1)), columns=['column']) + + # Run + info = transformer._fit_continuous(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == bgm_instance + assert info.output_dimensions == 3 + assert info.output_info[0].dim == 1 + assert info.output_info[0].activation_fn == 'tanh' + assert info.output_info[1].dim == 2 + assert info.output_info[1].activation_fn == 'softmax' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__fit_continuous_max_clusters(self, MockBGM): + """Test ``_fit_continuous`` with data that has less than 10 rows. + + Expect that a ``BayesGMMTransformer`` is created with the max number of clusters + set to the length of the data. + + Input: + - Data with less than 10 rows. + + Side Effects: + - A ``BayesGMMTransformer`` is created with the max number of clusters set to the + length of the data. + """ + # Setup + data = pd.DataFrame(np.random.normal((7, 1)), columns=['column']) + transformer = DataTransformer() + + # Run + transformer._fit_continuous(data) + + # Assert + MockBGM.assert_called_once_with(max_clusters=len(data)) + + @patch('ctgan.data_transformer.OneHotEncodingTransformer') + def test___fit_discrete(self, MockOHE): + """Test ``_fit_discrete_`` on a simple discrete column. + + A ``OneHotEncodingTransformer`` will be created and fit with the ``data``. + + Setup: + - Mock the ``OneHotEncodingTransformer``. + - Create ``DataTransformer``. + + Input: + - A dataframe with only one column containing ``['a', 'b']`` values. + + Output: + - A ``ColumnTransformInfo`` object where: + - ``column_name`` matches the column of the data. + - ``transform`` is the ``OneHotEncodingTransformer`` instance. + - ``output_dimensions`` is 2. + - ``output_info`` assigns the correct activation function. + + Side Effects: + - ``fit`` should be called with the data. + """ + # Setup + ohe_instance = MockOHE.return_value + ohe_instance.dummies = ['a', 'b'] + transformer = DataTransformer() + data = pd.DataFrame(np.array(['a', 'b'] * 100), columns=['column']) + + # Run + info = transformer._fit_discrete(data) + + # Assert + assert info.column_name == 'column' + assert info.transform == ohe_instance + assert info.output_dimensions == 2 + assert info.output_info[0].dim == 2 + assert info.output_info[0].activation_fn == 'softmax' + + def test_fit(self): + """Test ``fit`` on a np.ndarray with one continuous and one discrete columns. + + The ``fit`` method should: + - Set ``self.dataframe`` to ``False``. + - Set ``self._column_raw_dtypes`` to the appropirate dtypes. + - Use the appropriate ``_fit`` type for each column. + - Update ``self.output_info_list``, ``self.output_dimensions`` and + ``self._column_transform_info_list`` appropriately. + + Setup: + - Create ``DataTransformer``. + - Mock ``_fit_discrete``. + - Mock ``_fit_continuous``. + + Input: + - A table with one continuous and one discrete columns. + - A list with the name of the discrete column. + + Side Effects: + - ``_fit_discrete`` and ``_fit_continuous`` should each be called once. + - Assigns ``self._column_raw_dtypes`` the appropriate dtypes. + - Assigns ``self.output_info_list`` the appropriate ``output_info``. + - Assigns ``self.output_dimensions`` the appropriate ``output_dimensions``. + - Assigns ``self._column_transform_info_list`` the appropriate + ``column_transform_info``. + """ + # Setup + transformer = DataTransformer() + transformer._fit_continuous = Mock() + transformer._fit_continuous.return_value = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + transformer._fit_discrete = Mock() + transformer._fit_discrete.return_value = ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + + data = pd.DataFrame({ + 'x': np.random.random(size=100), + 'y': np.random.choice(['yes', 'no'], size=100) + }) + + # Run + transformer.fit(data, discrete_columns=['y']) + + # Assert + transformer._fit_discrete.assert_called_once() + transformer._fit_continuous.assert_called_once() + assert transformer.output_dimensions == 6 + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__transform_continuous(self, MockBGM): + """Test ``_transform_continuous``. + + Setup: + - Mock the ``BayesGMMTransformer`` with the transform method returning + some dataframe. + - Create ``DataTransformer``. + + Input: + - ``ColumnTransformInfo`` object. + - A dataframe containing a continuous column. + + Output: + - A np.array where the first column contains the normalized part + of the mocked transform, and the other columns are a one hot encoding + representation of the component part of the mocked transform. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + data = pd.DataFrame({'x': np.array([0.1, 0.3, 0.5])}) + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._transform_continuous(column_transform_info, data) + + # Assert + expected = np.array([ + [0.1, 1, 0, 0], + [0.2, 0, 1, 0], + [0.3, 0, 1, 0], + ]) + np.testing.assert_array_equal(result, expected) + + def test_transform(self): + """Test ``transform`` on a dataframe with one continuous and one discrete columns. + + It should use the appropriate ``_transform`` type for each column and should return + them concanenated appropriately. + + Setup: + - Initialize a ``DataTransformer`` with a ``column_transform_info`` detailing + a continuous and a discrete columns. + - Mock the ``_transform_discrete`` and ``_transform_continuous`` methods. + + Input: + - A table with one continuous and one discrete columns. + + Output: + - np.array containing the transformed columns. + + Side Effects: + - ``_transform_discrete`` and ``_transform_continuous`` should each be called once. + """ + # Setup + data = pd.DataFrame({ + 'x': np.array([0.1, 0.3, 0.5]), + 'y': np.array(['yes', 'yes', 'no']) + }) + + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=None, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + transformer._transform_continuous = Mock() + selected_normalized_value = np.array([[0.1], [0.3], [0.5]]) + selected_component_onehot = np.array([ + [1, 0, 0], + [0, 1, 0], + [0, 1, 0], + ]) + return_value = np.concatenate( + (selected_normalized_value, selected_component_onehot), axis=1) + transformer._transform_continuous.return_value = return_value + + transformer._transform_discrete = Mock() + transformer._transform_discrete.return_value = np.array([ + [0, 1], + [0, 1], + [1, 0], + ]) + + # Run + result = transformer.transform(data) + + # Assert + transformer._transform_continuous.assert_called_once() + transformer._transform_discrete.assert_called_once() + + expected = np.array([ + [0.1, 1, 0, 0, 0, 1], + [0.3, 0, 1, 0, 0, 1], + [0.5, 0, 1, 0, 1, 0], + ]) + assert result.shape == (3, 6) + assert (result[:, 0] == expected[:, 0]).all(), 'continuous-cdf' + assert (result[:, 1:4] == expected[:, 1:4]).all(), 'continuous-softmax' + assert (result[:, 4:6] == expected[:, 4:6]).all(), 'discrete' + + @patch('ctgan.data_transformer.BayesGMMTransformer') + def test__inverse_transform_continuous(self, MockBGM): + """Test ``_inverse_transform_continuous``. + + Setup: + - Create ``DataTransformer``. + - Mock the ``BayesGMMTransformer`` where: + - ``get_output_types`` returns the appropriate dictionary. + - ``reverse_transform`` returns some dataframe. + + Input: + - A ``ColumnTransformInfo`` object. + - A np.ndarray where: + - The first column contains the normalized value + - The remaining columns correspond to the one-hot + - sigmas = np.ndarray of floats + - st = index of the sigmas ndarray + + Output: + - Dataframe where the first column are floats and the second is a lable encoding. + + Side Effects: + - The ``reverse_transform`` method should be called with a dataframe + where the first column are floats and the second is a lable encoding. + """ + # Setup + bgm_instance = MockBGM.return_value + bgm_instance.get_output_types.return_value = { + 'x.normalized': 'numerical', + 'x.component': 'numerical' + } + + bgm_instance.reverse_transform.return_value = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + transformer = DataTransformer() + column_data = np.array([ + [0.1, 1, 0, 0], + [0.3, 0, 1, 0], + [0.5, 0, 1, 0], + ]) + + column_transform_info = ColumnTransformInfo( + column_name='x', column_type='continuous', transform=bgm_instance, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ) + + # Run + result = transformer._inverse_transform_continuous( + column_transform_info, column_data, None, None) + + # Assert + expected = pd.DataFrame({ + 'x.normalized': [0.1, 0.2, 0.3], + 'x.component': [0.0, 1.0, 1.0] + }) + + np.testing.assert_array_equal(result, expected) + + expected_data = pd.DataFrame({ + 'x.normalized': [0.1, 0.3, 0.5], + 'x.component': [0, 1, 1] + }) + + pd.testing.assert_frame_equal( + bgm_instance.reverse_transform.call_args[0][0], + expected_data + ) + + def test_inverse_transform(self): + """Test ``inverse_transform`` on a np.ndarray with continuous and discrete columns. + + It should use the appropriate '_fit' type for each column and should return + the corresponding columns. Since we are using the same example as the 'test_transform', + and these two functions are inverse of each other, the returned value here should + match the input of that function. + + Setup: + - Mock _column_transform_info_list + - Mock _inverse_transform_discrete + - Mock _inverse_trarnsform_continuous + + Input: + - column_data = a concatenation of two np.ndarrays + - the first one refers to the continuous values + - the first column contains the normalized values + - the remaining columns correspond to the a one-hot + - the second one refers to the discrete values + - the columns correspond to a one-hot + Output: + - numpy array containing a discrete column and a continuous column + + Side Effects: + - _transform_discrete and _transform_continuous should each be called once. + """ + + def test_convert_column_name_value_to_id(self): + """Test ``convert_column_name_value_to_id`` on a simple ``_column_transform_info_list``. + + Tests that the appropriate indexes are returned when a table of three columns, + discrete, continuous, discrete, is passed as '_column_transform_info_list'. + + Setup: + - Mock ``_column_transform_info_list``. + + Input: + - column_name = the name of a discrete column + - value = the categorical value + + Output: + - dictionary containing: + - ``discrete_column_id`` = the index of the target column, + when considering only discrete columns + - ``column_id`` = the index of the target column + (e.g. 3 = the third column in the data) + - ``value_id`` = the index of the indicator value in the one-hot encoding + """ + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('y', 'yes') + + # Assert + assert result['column_id'] == 1 # this is the 2nd column + assert result['discrete_column_id'] == 0 # this is the 1st discrete column + assert result['value_id'] == 1 # this is the 2nd dimension in the one hot encoding + + def test_convert_column_name_value_to_id_multiple(self): + """Test ``convert_column_name_value_to_id``.""" + # Setup + ohe = Mock() + ohe.transform.return_value = pd.DataFrame([ + [0, 1, 0] # one hot encoding, second dimension + ]) + transformer = DataTransformer() + transformer._column_transform_info_list = [ + ColumnTransformInfo( + column_name='x', column_type='continuous', transform=None, + output_info=[SpanInfo(1, 'tanh'), SpanInfo(3, 'softmax')], + output_dimensions=1 + 3 + ), + ColumnTransformInfo( + column_name='y', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ), + ColumnTransformInfo( + column_name='z', column_type='discrete', transform=ohe, + output_info=[SpanInfo(2, 'softmax')], + output_dimensions=2 + ) + ] + + # Run + result = transformer.convert_column_name_value_to_id('z', 'yes') + + # Assert + assert result['column_id'] == 2 # this is the 3rd column + assert result['discrete_column_id'] == 1 # this is the 2nd discrete column + assert result['value_id'] == 1 # this is the 1st dimension in the one hot encoding diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tox.ini b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tox.ini new file mode 100644 index 0000000000000000000000000000000000000000..5fbffba409c0fee10719de58cf5a5bf4639b374e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/CTGAN/tox.ini @@ -0,0 +1,19 @@ +[tox] +envlist = py38-lint, py3{6,7,8,9}-{unit,integration,readme} + +[testenv] +skipsdist = false +skip_install = false +deps = + invoke + readme: rundoc +extras = + lint: dev + unit: test + integration: test +commands = + lint: invoke lint + unit: invoke unit + integration: invoke integration + readme: invoke readme + invoke rmdir --path {envdir} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/pipeline_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/pipeline_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..cd8f0c4afd222607db65aae70fe969385ea4d79b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/pipeline_tvae.py @@ -0,0 +1,80 @@ +import tomli +import shutil +import os +import argparse +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + ctabgan = None + if args.train: + ctabgan = train_tvae( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + train_params=raw_config['train_params'], + change_val=args.change_val, + device=raw_config['device'] + ) + if args.sample: + sample_tvae( + synthesizer=ctabgan, + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + num_samples=raw_config['sample']['num_samples'], + train_params=raw_config['train_params'], + change_val=args.change_val, + seed=raw_config['sample']['seed'], + device=raw_config['device'] + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/train_sample_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/train_sample_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..7db74590f2826edf87938d3707bf12fdcfbf2b5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/train_sample_tvae.py @@ -0,0 +1,117 @@ +import lib +import os +import numpy as np +import argparse +from CTGAN.ctgan import TVAESynthesizer +from pathlib import Path +import torch +import pickle +import warnings +from sklearn.exceptions import ConvergenceWarning + +warnings.filterwarnings("ignore", category=ConvergenceWarning) + +def train_tvae( + parent_dir, + real_data_path, + train_params = {"batch_size": 512}, + change_val=False, + device = "cpu" +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + train_params["batch_size"] = min(y_train.shape[0], train_params["batch_size"]) + + print(train_params) + synthesizer = TVAESynthesizer( + **train_params, + device=device + ) + + synthesizer.fit(X, cat_features) + + # save_ctabgan(synthesizer, parent_dir) + with open(parent_dir / "tvae.obj", "wb") as f: + pickle.dump(synthesizer, f) + + return synthesizer + +def sample_tvae( + synthesizer, + parent_dir, + real_data_path, + num_samples, + train_params = {"batch_size": 512}, + change_val=False, + device="cpu", + seed=0 +): + real_data_path = Path(real_data_path) + parent_dir = Path(parent_dir) + device = torch.device(device) + + if change_val: + X_num_train, X_cat_train, y_train, _, _, _ = lib.read_changed_val(real_data_path) + else: + X_num_train, X_cat_train, y_train = lib.read_pure_data(real_data_path, 'train') + + X = lib.concat_to_pd(X_num_train, X_cat_train, y_train) + + X.columns = [str(_) for _ in X.columns] + + + cat_features = list(map(str, range(X_num_train.shape[1], X_num_train.shape[1]+X_cat_train.shape[1]))) if X_cat_train is not None else [] + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + cat_features += ["y"] + + with open(parent_dir / "tvae.obj", 'rb') as f: + synthesizer = pickle.load(f) + synthesizer.decoder = synthesizer.decoder.to(device) + + gen_data = synthesizer.sample(num_samples, seed) + + y = gen_data['y'].values + if len(np.unique(y)) == 1: + y[0] = 0 + y[1] = 1 + + X_cat = gen_data[cat_features].drop('y', axis=1, errors="ignore").values if len(cat_features) else None + X_num = gen_data.values[:, :X_num_train.shape[1]] if X_num_train is not None else None + + if X_num_train is not None: + np.save(parent_dir / 'X_num_train', X_num.astype(float)) + if X_cat_train is not None: + np.save(parent_dir / 'X_cat_train', X_cat.astype(str)) + y = y.astype(float) + if lib.load_json(real_data_path / "info.json")["task_type"] != "regression": + y = y.astype(int) + np.save(parent_dir / 'y_train', y) # only clf !!! + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('real_data_path', type=str) + parser.add_argument('parent_dir', type=str) + parser.add_argument('train_size', type=int) + args = parser.parse_args() + + ctabgan = train_tvae(args.parent_dir, args.real_data_path, change_val=True) + sample_tvae(ctabgan, args.parent_dir, args.real_data_path, args.train_size, change_val=True) + + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/tune_tvae.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/tune_tvae.py new file mode 100644 index 0000000000000000000000000000000000000000..0b6558c024ea45bdc43b09025ba4f233417de999 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/CTGAN/tune_tvae.py @@ -0,0 +1,153 @@ +from multiprocessing.sharedctypes import RawValue +import tempfile +import subprocess +import lib +import os +import optuna +import argparse +from pathlib import Path +from train_sample_tvae import train_tvae, sample_tvae +from scripts.eval_catboost import train_catboost + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type +train_size = args.train_size +device = args.device +assert eval_type in ('merged', 'synthetic') + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + # construct model + min_n_layers, max_n_layers, d_min, d_max = 1, 3, 6, 9 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + #### + + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [1000]) + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + + num_samples = int(train_size * (2 ** trial.suggest_int('frac_samples', -2, 3))) + embedding_dim = 2 ** trial.suggest_int('embedding_dim', 6, 10) + loss_factor = trial.suggest_loguniform('loss_factor', 0.001, 10) + + + train_params = { + "lr": lr, + "epochs": steps, + "embedding_dim": embedding_dim, + "batch_size": batch_size, + "loss_factor": loss_factor, + "compress_dims": d_layers, + "decompress_dims": d_layers + } + + trial.set_user_attr("train_params", train_params) + trial.set_user_attr("num_samples", num_samples) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + ctabgan = train_tvae( + parent_dir=dir_, + real_data_path=real_data_path, + train_params=train_params, + change_val=True, + device=device + ) + + for sample_seed in range(5): + sample_tvae( + ctabgan, + parent_dir=dir_, + real_data_path=real_data_path, + num_samples=num_samples, + train_params=train_params, + change_val=True, + seed=sample_seed, + device=device + ) + + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + return score / 5 + + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/tvae/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/tvae/", + "real_data_path": real_data_path, + "seed": 0, + "device": args.device, + "train_params": study.best_trial.user_attrs["train_params"], + "sample": {"seed": 0, "num_samples": study.best_trial.user_attrs["num_samples"]}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +train_tvae( + parent_dir=f"exp/{Path(real_data_path).name}/tvae/", + real_data_path=real_data_path, + train_params=study.best_trial.user_attrs["train_params"], + change_val=False, + device=device +) + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "tvae", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/LICENSE.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/LICENSE.md new file mode 100644 index 0000000000000000000000000000000000000000..3c105473f782136fd5659e03d454cfc3ba31252e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/LICENSE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022 Akim Kotelnikov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/README.md b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/README.md new file mode 100644 index 0000000000000000000000000000000000000000..517e9aa2f8024a8412a9028529e7fe88f6c57dec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/README.md @@ -0,0 +1,99 @@ +# TabDDPM: Modelling Tabular Data with Diffusion Models +This is the official code for our paper "TabDDPM: Modelling Tabular Data with Diffusion Models" ([paper](https://arxiv.org/abs/2209.15421)) + + + +## Setup the environment +1. Install [conda](https://docs.conda.io/en/latest/miniconda.html) (just to manage the env). +2. Run the following commands + ```bash + export REPO_DIR=/path/to/the/code + cd $REPO_DIR + + conda create -n tddpm python=3.9.7 + conda activate tddpm + + pip install torch==1.10.1+cu111 -f https://download.pytorch.org/whl/torch_stable.html + pip install -r requirements.txt + + # if the following commands do not succeed, update conda + conda env config vars set PYTHONPATH=${PYTHONPATH}:${REPO_DIR} + conda env config vars set PROJECT_DIR=${REPO_DIR} + + conda deactivate + conda activate tddpm + ``` + +## Running the experiments + +Here we describe the neccesary info for reproducing the experimental results. +Use `agg_results.ipynb` to print results for all dataset and all methods. + +### Datasets + +We upload the datasets used in the paper with our train/val/test splits (link below). We do not impose additional restrictions to the original dataset licenses, the sources of the data are listed in the paper appendix. + +You could load the datasets with the following commands: + +``` bash +conda activate tddpm +cd $PROJECT_DIR +wget "https://www.dropbox.com/s/rpckvcs3vx7j605/data.tar?dl=0" -O data.tar +tar -xvf data.tar +``` + +### File structure +`tab-ddpm/` -- implementation of the proposed method +`tuned_models/` -- tuned hyperparameters of evaluation model (CatBoost or MLP) + +All main scripts are in `scripts/` folder: + +- `scripts/pipeline.py` are used to train, sample and eval TabDDPM using a given config +- `scripts/tune_ddpm.py` -- tune hyperparameters of TabDDPM +- `scripts/eval_[catboost|mlp|simple].py` -- evaluate synthetic data using a tuned evaluation model or simple models +- `scripts/eval_seeds.py` -- eval using multiple sampling and multuple eval seeds +- `scripts/eval_seeds_simple.py` -- eval using multiple sampling and multuple eval seeds (for simple models) +- `scripts/tune_evaluation_model.py` -- tune hyperparameters of eval model (CatBoost or MLP) +- `scripts/resample_privacy.py` -- privacy calculation + +Experiments folder (`exp/`): +- All results and synthetic data are stored in `exp/[ds_name]/[exp_name]/` folder +- `exp/[ds_name]/config.toml` is a base config for tuning TabDDPM +- `exp/[ds_name]/eval_[catboost|mlp].json` stores results of evaluation (`scripts/eval_seeds.py`) + +To understand the structure of `config.toml` file, read `CONFIG_DESCRIPTION.md`. + +Baselines: +- `smote/` +- `CTGAN/` -- TVAE [official repo](https://github.com/sdv-dev/CTGAN) +- `CTAB-GAN/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN) +- `CTAB-GAN-Plus/` -- [official repo](https://github.com/Team-TUD/CTAB-GAN-Plus) + +### Examples + +Run TabDDPM tuning. + +Template and example (`--eval_seeds` is optional): +```bash +python scripts/tune_ddpm.py [ds_name] [train_size] synthetic [catboost|mlp] [exp_name] --eval_seeds +python scripts/tune_ddpm.py churn2 6500 synthetic catboost ddpm_tune --eval_seeds +``` + +Run TabDDPM pipeline. + +Template and example (`--train`, `--sample`, `--eval` are optional): +```bash +python scripts/pipeline.py --config [path_to_your_config] --train --sample --eval +python scripts/pipeline.py --config exp/churn2/ddpm_cb_best/config.toml --train --sample +``` +It takes approximately 7min to run the script above (NVIDIA GeForce RTX 2080 Ti). + +Run evaluation over seeds +Before running evaluation, you have to train the model with the given hyperparameters (the example above). + +Template and example: +```bash +python scripts/eval_seeds.py --config [path_to_your_config] [n_eval_seeds] [ddpm|smote|ctabgan|ctabgan-plus|tvae] synthetic [catboost|mlp] [n_sample_seeds] +python scripts/eval_seeds.py --config exp/churn2/ddpm_cb_best/config.toml 10 ddpm synthetic catboost 5 +``` \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py new file mode 100644 index 0000000000000000000000000000000000000000..77f1230651645a74d0f38b3ff44204cbe28e07ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py @@ -0,0 +1,6 @@ +import collections, collections.abc +for _a in ('Sequence','MutableSequence','MutableMapping','Mapping','MutableSet','Set','Callable','Iterable','Iterator'): + if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None)) +import sys, runpy +sys.argv = sys.argv[1:] +runpy.run_path(sys.argv[0], run_name='__main__') diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/agg_results.ipynb b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/agg_results.ipynb new file mode 100644 index 0000000000000000000000000000000000000000..b2265036321a1b9a52a99daf500759ef4b03d60a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/agg_results.ipynb @@ -0,0 +1,315 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Aggregating results to DataFrame" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import os\n", + "import lib\n", + "import numpy as np\n", + "import pandas as pd\n", + "\n", + "DATASETS = [\n", + " \"abalone\",\n", + " \"adult\",\n", + " \"buddy\",\n", + " \"california\",\n", + " \"cardio\",\n", + " \"churn2\",\n", + " \"default\",\n", + " \"diabetes\",\n", + " \"fb-comments\",\n", + " \"gesture\",\n", + " \"higgs-small\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + " \"miniboone\",\n", + " \"wilt\"\n", + "]\n", + "\n", + "_REGRESSION = [\n", + " \"abalone\",\n", + " \"california\",\n", + " \"fb-comments\",\n", + " \"house\",\n", + " \"insurance\",\n", + " \"king\",\n", + "]\n", + "\n", + "\n", + "method2exp = {\n", + " \"real\": \"exp/{}/ddpm_cb_best/\",\n", + " \"tab-ddpm\": \"exp/{}/ddpm_cb_best/\",\n", + " \"smote\": \"exp/{}/smote/\",\n", + " \"ctabgan+\": \"exp/{}/ctabgan-plus/\",\n", + " \"ctabgan\": \"exp/{}/ctabgan/\",\n", + " \"tvae\": \"exp/{}/tvae/\"\n", + "}\n", + "\n", + "eval_file = \"eval_catboost.json\"\n", + "show_std = False\n", + "df = pd.DataFrame(columns=[\"method\"] + [_[:3].upper() for _ in DATASETS])\n", + "\n", + "for algo in method2exp: \n", + " algo_res = []\n", + " for ds in DATASETS:\n", + " if not os.path.exists(os.path.join(method2exp[algo].format(ds), eval_file)):\n", + " algo_res.append(\"--\")\n", + " continue\n", + " metric = \"r2\" if ds in _REGRESSION else \"f1\"\n", + " res_dict = lib.load_json(os.path.join(method2exp[algo].format(ds), eval_file))\n", + "\n", + " if algo == \"real\":\n", + " res = f'{res_dict[\"real\"][\"test\"][metric + \"-mean\"]:.4f}' \n", + " if show_std: res += f'+-{res_dict[\"real\"][\"test\"][metric + \"-std\"]:.4f}'\n", + " else:\n", + " res = f'{res_dict[\"synthetic\"][\"test\"][metric + \"-mean\"]:.4f}'\n", + " if show_std: res += f'+-{res_dict[\"synthetic\"][\"test\"][metric + \"-std\"]:.4f}'\n", + "\n", + " algo_res.append(res)\n", + " df.loc[len(df)] = [algo] + algo_res" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "
\n", + "\n", + "\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "
methodABAADUBUDCALCARCHUDEFDIAFB-GESHIGHOUINSKINMINWIL
0real0.55620.81520.90630.85680.73790.74030.68800.78490.83710.63650.72380.66160.81370.90700.93420.8982
1tab-ddpm0.54990.79510.90570.83620.73740.75480.69100.73980.71280.59670.72180.67660.80920.83310.93620.9045
2smote0.54860.79120.89060.83970.73230.74320.69300.68350.80350.65790.72190.66250.81190.84160.93230.9127
3ctabgan+0.46720.77240.88440.52470.73270.70240.68650.73390.50880.40550.66390.50400.79660.44380.89200.7983
4ctabgan--0.78310.8552--0.71710.68750.64370.7310--0.39220.5748------0.88920.9060
5tvae0.43280.78100.86380.75180.71740.73170.65640.71360.68530.43400.63780.49260.78420.82380.91250.5006
\n", + "
" + ], + "text/plain": [ + " method ABA ADU BUD CAL CAR CHU DEF DIA \\\n", + "0 real 0.5562 0.8152 0.9063 0.8568 0.7379 0.7403 0.6880 0.7849 \n", + "1 tab-ddpm 0.5499 0.7951 0.9057 0.8362 0.7374 0.7548 0.6910 0.7398 \n", + "2 smote 0.5486 0.7912 0.8906 0.8397 0.7323 0.7432 0.6930 0.6835 \n", + "3 ctabgan+ 0.4672 0.7724 0.8844 0.5247 0.7327 0.7024 0.6865 0.7339 \n", + "4 ctabgan -- 0.7831 0.8552 -- 0.7171 0.6875 0.6437 0.7310 \n", + "5 tvae 0.4328 0.7810 0.8638 0.7518 0.7174 0.7317 0.6564 0.7136 \n", + "\n", + " FB- GES HIG HOU INS KIN MIN WIL \n", + "0 0.8371 0.6365 0.7238 0.6616 0.8137 0.9070 0.9342 0.8982 \n", + "1 0.7128 0.5967 0.7218 0.6766 0.8092 0.8331 0.9362 0.9045 \n", + "2 0.8035 0.6579 0.7219 0.6625 0.8119 0.8416 0.9323 0.9127 \n", + "3 0.5088 0.4055 0.6639 0.5040 0.7966 0.4438 0.8920 0.7983 \n", + "4 -- 0.3922 0.5748 -- -- -- 0.8892 0.9060 \n", + "5 0.6853 0.4340 0.6378 0.4926 0.7842 0.8238 0.9125 0.5006 " + ] + }, + "execution_count": 2, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "df" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3.9.7 ('base')", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.9.7" + }, + "orig_nbformat": 4, + "vscode": { + "interpreter": { + "hash": "a06af253165e97d0c1e75e8bf6d3252013856f30b8177e11b02d3fa36c37333d" + } + } + }, + "nbformat": 4, + "nbformat_minor": 2 +} diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..4440c9036b27a7ff5f55a6f733751f0d1d5caa0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db1cf55340ae5364a05a1c840094ca47fff79dd584850c9ee751b2a097f7b075 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..415f08cd7f0cafb12c8a8e86a587ca54e17e128a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/Tab-Cate-1/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dcb118d387bd15e6a79e571ad80c7a4fe900858c45ccea903e70a9550c86203 +size 256 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..239282facabecb1d9f1223c79c3fef51fe2be053 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe8c63e9f9a09cd9ca89affd4bb5e4d1545d59cdb31f9f73fb486257bbfd447f +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1bce1d2e055e5b55b325fe6842697c47a89b8461 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6bd872ae66f715fffcc92f2c7c4cc2246980b4df0e02b93738a8c9b4f697af0 +size 539 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2d0fab15dfaf04b2a9fb717ea0802d8e62fee7fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42a3a2e2f22ebc24b66aaa3403869283f6576ce04e5fafa81fec15735d66aee3 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6310c4aa9115b015b514b2a282c61d68fc369a75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d6478bba03b9309a26ef6e1247d95ce86668437fa08a6c5f15776ec9848a5e2 +size 2424 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9eb5c94dab72a3d1610e5222c6de3ddad5cd6c41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc6aa7d00bb5078f766e5d73ea4e04bbe8437bac44636cfd80a36b9262df0a01 +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76e24715bde6ce626bf4308daece11c372c83fef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7ef5506437037908e0c0d5f0bd0c5eb3c61747d9de491d345dc0e8e8be3845b8 +size 909 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..e1b158afbd5ef2c36faf553bf457b116fb84307c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fe4a3e4e117924a65d2da76254394ba8aae00555e30bebae916e154a925f0e3e +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..49ecaecc1998e6d60b6cf38839b1801c76106646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aaf9df7911d5911b85f1a805c48a1c6d0e978e287c10f9ef78365b08a14da806 +size 4809 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json new file mode 100644 index 0000000000000000000000000000000000000000..d6c8c3f0aa45c5f991ef888e56074644c40f7643 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_ada.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0684462d69e5c1c8db2b1fad1ae7760be1849abcc5a623b5eaf07255b04a17f8 +size 454 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json new file mode 100644 index 0000000000000000000000000000000000000000..812b1fa0d26104fc94f9d73497c59db5bda8c81b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/eval_simple_lr.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce2cdfb51f7d37053edfa2250af17d1adef47d3e0eb141926a6a74a613c6cbb2 +size 442 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..38785f12fa8a0a5c6ec6924e5ddf9222ec12dd11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c621cbd0dcc71b7f8c19d01e2aa6e3497f82d84a40a97a2bfac4ed83e3e0df42 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..7e3f93f4f09ff79f86157b296529a7e893d25078 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1b145c01ef06f81e77de7b8438cb942b863881a21cd76afbcb96b7a61100e96 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e1290d33f1f124f533c3159f32d21a3e917e8872 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d17baaaca34b2ff7aa0e7a68f062bfa12782bd4c483d07e7f97758a1f6a8357 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2a6ae85d7cb08d2200c0fd578de2cd4e0cacea2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00526ecd9377b1904c01ed6cce54c0e9b691c850e292f0588107f770ca1f8fc2 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..91fdedad84e55e1fef159b04ee30ed4841dc7692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3996ee9bde79e3982c88235d2b1122b8988c89611bb7c41dee2d1c12139e3bb +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa9932fd4604af72d4378fa0f4c66c2b7d3218e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e9cb8da939d962852869d248afad2320f27d30ac1900442e6f1379fe88051b76 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..41fdb7e2dca3291094b85592a2b047e69f29f529 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:207d7dcbfac7bbfc854a941b32c95a76a51496bb71717c2a5ff2a2dbb829b26e +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9bc4cdcb8f275644399a66aa1b80f60616bc3e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7df36381315039d5cb9a27726a08f74032f27bce1000fefbbb01aed9b3e4b2ae +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c623de2b0e3bf0dd3be30de30b65a60c9436a979 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df8ce015eace899092d39efd5c2b7d3fde374ed529dc16feac566fb6447990d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..511f215474c59b8543820b3d0b88de78e0de0d9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:559fcc7559fdf7b84792453eb40b37ba2940146f16519894b6f6fd37fa3bb5b3 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b6a8ec4bb5bd70ce60006afd3a7dff1822feb169 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20b5b6b62d80477424158fc13250fd86a5c810bffbf9f930efb7a1e3bcddf0af +size 2407 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a9fb552c41e001e71154ecafb476a465879687a7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c6b40deb21de47336a7784135e055cae8e4162fec33c39b78c3a41e3f74c948 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4da4fc191a2e5f0676788c852c5e1cbed41d32ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9f78af172c35514168b0ba7aa97d29f9d9e44ba99293de739049be2e3705645 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3723363ce4b36e338ef02bdf850bc9f02336320d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0290647040001ea9a368bf406a5f0fe3bfd8ad34fc91e12f9b3cbe4de489cd9c +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac7bcb5f706eeea6d76d7540548852531b06071a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bd237e3800561b53e3ad33f78abd40d90631f66532d2efdcef113e02a239cc46 +size 457 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..32cb493748339cff60f7fded2233546e5e32cc84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d181d9e4e274ba8953549a2a86feb4f9fd0d344a56fc0c23dee58489fb2f4dea +size 2412 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5d43bbd1d8113354997b9424e2221c43f837cf2b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/abalone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4b49fbcbcb81f577c2c56d703b327294a63a52fce9afa7b5fb98b20b61556c8c +size 199 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c91eaa420a435b2548fe9f6fa7cf86aca25a447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82fa681345385f4cbddf6c2946308525a747b4e8502e5eb0700402911680c3ee +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5f1a10d99f376c73048318bd2af6ae390e8a4490 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b99ae92eed9a1e581aa7ff0d271cd67f0955d0cf09a510dc5e1cc6a385e21b3 +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..38203892c516eb52a6199e64ce8d12d24b452965 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc182a50c2f168db47f03cf6e35aad805d855e67504c16b7abf4a54010869fe +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..66d6fdbcc81074fe3726c4679a8f0f06df75877d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98523dda3ed661941608fe1b376806a9d0affc87834ca87779f4671ba571c54b +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fbc7353d875b05901555aa21421fdbed1c536705 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea807b1b78a37648296de632ce735f58d486a97f4b24e932aa779c67e25acb9f +size 552 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..53d639a085e90b656b18c69da21e580cea010516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c80c4d789cbc01a2220a215ce23df5afd3492eed59f66682ac55336b42bcab6b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bef94f899e84c5df37d7988dd17dcb902600974b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85088d7d9b8600f758d5ff5571b8a8c6704d5a59ca6abe26fd4904ae19c55632 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..63cd2f794eb62ec7a0ee29203f9a9a9d4dff5462 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:289633f5b676d2316c97619996c97c873176e1210dd6db4a61191a6f4bb17f80 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d0d477a0e57573a39b7fd81b710503bd4e73724d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e8bc409e88198d374b05d90076684ca2b90d591045db6766a5e936801333b53f +size 945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4ca38c916877e7e9eaf024c9fb6c28a56f3c474e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b8d5261312695be59977ccae61c966a26b0cb69a14c644c68f922ac8f893a32 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2d09f8eb221ed76948966ea9f07fc9563f632d58 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2af8c461fb0755cb3b48fcc7f09188e00cf86cd81eda9c0b4bd578f27a7e4958 +size 1317 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6daff009fa1786d5a82839aa85d058902b799602 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2fb01634aa14168c902aa056ab75585f0e651d9f26731512fd0012ae3e689318 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab913f002d23e5ae0a7f14750752565fcbfd8ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2b61e81512f6e5be97135a46ef8fd46a22f64a9a53d6659700abdc151142c9 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..36d2e6dda9874bdd9bab29341f3c433d97584768 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df063802251823342ba95960aefc6e9a7860c912f1d086b50145bb973c372b69 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0402c64128c1641e1847800e507d54d189c6f51f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ccdb7ba1c26da827d15509d3040ebe6465586801b404cd099913fcd39dff534 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..1cc8823537ac8759cdf13cf468f7da760c1dceb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42ae10d1554df7b8b364f5e0ac4701986cd67aecb9967eb70ea2e077bb134652 +size 901 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..55a0bb6fcaf422c13a2c2ff53c58a57f8b9331d3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b61d18963acc154eb7ea64dfddcf182ed993a93b15c86cd757bc53cacbb9a23 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..139a662dcc89b87ec89a84edfd564e8c2de7cd30 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fdf95abca172dac3b978818cd21f1505d45d69d95bcd9d87e51cc0ee74025d4b +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d32d9411660891640b125047bf880d1fe4b25ab7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:62d657b20c19d7f33e7e5b64472078bd7db69f460cc77bce2b9da69939f7d13d +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..46589fdd2546416d8423587d17e49ab98f2fdb72 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:537b8d3c395d476ad7191337d6f7ca04e938ca5743ccec0bdc0ff94bd48997d2 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7ab60cea704ce4061d24f98827d49d17a1c9d10 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a2a0754baabf29b1ecb6a70d42bd4d1586800bfc47b6bbb0f1f304bb1242b09c +size 3324 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..00321a9ffa3e714125668ab0501694db50470136 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba31f53b7ae00081599032869b9b661df43572e336d56db4fa08beff271a4abb +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8f9ac5ebeb685a33a38e5c51e47b623dde84802e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d91e2295ca75ac6be7cb33c17ef83238dfb8a2e8b2b92237ed405bbaf111d6d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65e9f57bae10cf98cf7283cffec68a0a5fad217a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25a126b5e9fe86493e96b5df30b1a53919680a3a444f6f2605f45fba1d1598e2 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..872de3d2083c260dc16bcac5c091025328ed54dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ae76a56a721fb2229982da25398fc47af989bf8c76be29b8ec07d16eb8963c3 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bab398cb86a7bd5b269964545090c18d3004f9a5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cf5cf2766e0d2e778fd96198b87441aeb3272204d8c8ec028f9e1ef671f99db6 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..e5860629e7426905a6efd71025fc456b86e626b2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/adult/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca4e138bb4dc0c08fc0ae6e44516f58e8089a0fb6178c64f15c32431d647452 +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fec2e348eead32758349c9ff196afdaab3864d9d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a44105b82634b3c9b91016d8e954a0094ffad036e51845477eabd00e7d4094c9 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..30aad0f91dff111a4fedd1215e6009a644b61e07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9e3cc82640c33eb1b4b850f705145d9f84c7c20b787c0db7c3fbe856dc4b11b2 +size 535 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..42f18f71c16e70c9d9b070942fca0f017000e140 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:83d2c2f95c8958abaab28a0adba1d1d3d1e3702d2045c6b4533e35a63a55e604 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b0b6c1aa4f31697486bb4e03a22cc21ba57c7b99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab1c4263a713421bc1d7552aaa52a651e1020f71e1fe7a42b3723e4e7e143d1c +size 2393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f2561375d3b6eb2798994bd9db1120b027b7a1cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b238f1464d4e714993012382f3e052a3fc0722743a200411551aa5031fe0874 +size 516 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4021982c6c299c4de244288a83dc31e691242289 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98856815bb0939c1231594e31ce2b910e1fc809f185d28ffaf7a0b6603664c9a +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bb60ee553f1ea7d4c2d8540e3c2248a14b69f74c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2620ed0d33427576a9c706e74f86ae948076ac55615e4b87a82ba1daf9c789db +size 2394 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..49363d44b0b4c826d5d675158164c93de19c68d2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d35a863d159b0cd489d94ae8ae1cfb9b916fc02c99a931ce487cdf189532f3e4 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..722c460979cf67531c5b946aa745fd20ddb80a07 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4ba6dda074f72eee74b8afbc2b18fd4626e710a2d3583d4379509cf9025edcac +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac199ba6cbf5784bc6a656c727d92923bb947df3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61aa5b3aaa5ab7da9c58c291c32533b9945e60b67f43f898ab179a9b3060d895 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..81d026923d55ab59b3dc3c6383b52450a1a03f0c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b941bcd7d8c5cb1cc585540ec98f24a0c12236698bea9b81f59b95e3783eeb30 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..47e136ee719855e17287e833b4946e398a10e2b1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb18ddf958aa699f11e0af740a81cd39b8f6df95860b5fbd18185bbe47ddad4a +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6041d3975ff389fe0d3062e98b03c07159250e16 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b15ec2d2c0d7b64cc6c3c65f03be04a7b813ad6f58ac10c92591045cc079cde +size 307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..52f8c0995c704b748fee904d2b83d774f1717913 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c3675f54196bc3cb4b2d19bcb5618d8577268882c082a4e64c52e5f1f7f05c9 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c846e6c961316abf6d4e1a63f0e0b8247e643f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aac333513d83a2571f92a1ccd30688bcbb74b4c2334da701d2514a83605d652f +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3e5fb807e5fbc4e8b6daeae882cbf7220dfad65a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86ea8bc3b6b08c587585c1cd2287359abff44cc3e717767bd85cbc6a390e0870 +size 962 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae7fd0cda795fa6c97a342a0c128db17b5d7a763 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5b849b1a0af8d78f67ccbd04a3a35dee96b72f8aeb10ce3090ff3e11f6b425b5 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..778b938d4d50038bb857dddcffec813f70a4b1ee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dc2aec212d7363d486a316be109ee1d435c0944022f9f3a0279588b3ab4fc456 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9c068a90386d6600e32f428498170073bd7e8990 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa163009f809658f57d8d5128088de7586d4b689e127f65c61583796611e5c56 +size 399 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..318d2bf2e09df253811516d67ebca9f7c7f0695c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fde8a58d975533a542c08c06ea1b796065a6dee6cb0cfd4378e1b985818c71d0 +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b7833ba5f315b943a8d73137b7ed675646fb2715 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f71aaa39f6f7126dd425a82aa795129a6fc31019607c8ea99f4b6f8bf523a7e +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..f2c93e38fc570c526ef27a6db0f2d0234937f642 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:84f60f6dfb97afdb242b799a412b7c73905b61bde1593a62a7729e6c3f3c246a +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..45d86aec79a33b80cfbbcacdc2a7ee1bcd2760ce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9f43aacc1c469ef228585feae4b8ee193ce1602a6855ab41bf5bac7f30f2386 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5fa9cedcd3cf536a2a379ff590486c9b4eedcb53 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49a118abbde6ea1ca044c5f60965e23689dd5faef50a612bb571bd6b1774c57e +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..338bb99b41bfe233281929d5d2e05416b1095031 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2235588571940c74c58717080910fd181be9fae29e9a387b6d34ead239db91a9 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c27447695997806191b34155281cd904003c4235 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d66bfbd3170e741c11c189ab9c40e4d4ba0310d70df88fede66df233d7a13e6a +size 2383 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..75579242f2ca596609a081f4abe60db130da814c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/buddy/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:016e72d0b846232ef5ae45252cb4d3df6de8490ec64c12b58ca5f9b26eab509d +size 218 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..269fa24454c2b0228ea9d70a27f3217c50cd73fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:47fa5e3a33f17e31a9a3a7a986c4d189aa6de421185bf67340c6f851c5f68503 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9389e17f5523a293bafcbf07879c4fa7ba402a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c263f7234c47093e6b0c0ae04e54ff853ef64604141527e6099587da4c158fbc +size 536 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c01ed90eace99eefca1d9ddec2b75aebbea0c968 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:45cedb6e79c0e481d2608def3e1fcef07f832f989acc78d1397e373b261dfada +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..de5b58adce509a35f047a0ed963404afd0acdbbf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ff12d95e026451c0ea70fc9877fdeeaa06a5e55e8424c151b14ea8d5c4a65d +size 2425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..645123d51e5899d9ae6aa4d041c63d8c5f40b69a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b7f06bd35da5fa1b2a7af11faf1517e42bc7300a33804adc14a6a937d40e0b99 +size 961 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0c21aedc0ea78626a22795cfebdea5f097649bea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b8c5497ed9e9dd29cd6423795998a32a9e064afe3e25fa166429d1d4531c7632 +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..183d6bf2f7200c58fab0537bc71eea8dd9029042 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f45f5378800af031cc1189625a89e6f971f244084ab6a1ec44851c1cc97791bd +size 906 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4cd56144fff8b9f7435faaa60e0495f1b25eb902 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:449806d716989b618e9937da4fcd1d1b34a3303af0fed823518593f10210dc08 +size 4815 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c94ec5f2c60e366c93758984ccedf7276f71cce2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a28f54c683196f15422a3de9fd1729928800c9c6d9f2b2c4f306781a58bb0d57 +size 295 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..65f9bc67bb2bb4816ecc0159070ed355b2bc882a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25c3b72ca028e0ac20a23ef943128c03c5be2361341e312f6fb970bbadbea62a +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..0914fb8061937287fa55186e588aee0978202325 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db0bf0f16268095c085c9578c9dc6929619b25d85de4beafa71e2e2c0b8aba9a +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc53309f95d9da1956bf01d9d813899524f1a2ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:043cbac22ddcc78d3bf1ba8667bfd3319f2ef4d20be12171ddd794f02e3819b2 +size 974 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e6a741bc6e80d9a8caa8cd4d5aced901340df557 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f473c3dbf1df529cb9c83e61d15ece198d860dc01b2a2e89eb85fe9ddfb71e09 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..2a303e9844c21875d49583eb43bde27f212fdd91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d349508f350d7d86ab8f1bccd80706db33b4c493d8d0fbbe7a78dda7daa7bad +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..455675f5055f90694438c7fb7b00c6ab6a1f776e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc2d64e51d8b6b24265a2c3948da7bf7ebf652a479ffc356690c7c32e7d05de0 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..110388b3920b6cc8b54b8d5674f95d816e8401fb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d918b0594fae87d25263c250b82a3481da89d2b27414bc5f46fc15a128e3dec7 +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..cbd3b9076dc55fdf3c0d603ffe7c1128a83f2ab1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db184ee0c7f1a2f3b154833c774c7cc95247bee0f0bb332fdf2f81fee52d2980 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..422c57be1a335bc126ae19e81f8de261046667c8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:684c20875442fd0af9aef20e258408265a0afefd337b3095e30f383f558f4e66 +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ebf8752d97e0b55ee67d6b25ea55a0a6035bec7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cba89f4f5a0ee277861f5c59874977e192052179029bae2ce1d4d51afcdf3ba0 +size 2409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a63e8c4e3026a48b79e8f373d7b97101cb791ebb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfc716ea0562b0304e5fc93363c2b47e3c62c6f3b53efdf627d4016698dc628a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..57ac452fdc6cba483d2217dfdebff391e5ef5679 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:31f62570889e2465b493833d65252ee55965ed96a5621737168d7908c8847592 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..11fcabb46bddd9db63302a9187e507bce762f416 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2040299a5b6055953f17fb97dadaaf61b71b994f54639358a474976448bafe99 +size 620 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9aa6e63ec8e0a96295b61ede2f6fa3bfbcc3c4d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d208514a5cbe37b42c4a6d9be3ac9e2f32f359162f9e6e8c4f4482b5e487880d +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e2392a3b0b097544d9e26713aaae9629aa1625a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46f24cdcb144018444629866ac8d0cb66b41c004e3fdb3f30e037c63cf5676c8 +size 2427 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..873b6d4283bebf7fa8a88f9e689034395be410bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/california/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0381784bcfe24da14c94e836c3abb9ddce4a0b8019f2c94e421c7360d71b820 +size 220 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..32d5bd49be0dc36ca2706cd274f3d7a528666572 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7559f0164dc80330ee436b9c6776f02149f6292e4b43c6a46ae5e14dc42ac6bd +size 908 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c49810fdd2e5118eca066398387f600036483e15 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b8f5e646194ff57dcb4e98faf5ddd4bdf7bda7b88e30cd5467ed28b3bc3cca9 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e9acecbbb72edbbbad89031bd6ca7c1f812bafba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4741f1db86513a094d4851c28387739323b4a120db20c6876fb1c3c4882e8d90 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b37393fca5e2296bbb3f6766189c46f04372a0ab --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc5de6dffe429c643429ece101cb1c96a9fb69ff584943a3900e1c708b97781d +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6958fa6c7bdb05b6cdb345ec7a2b502db956de63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89520a1f3bea8b05349191737c397a74f73628e809f1b3e8812a9598676c95ba +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d54495c34176f8c6c531042f06f9cc6b328dc961 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7f673d62b4ca86b684d165166a9af155b8a46a2d04c3ff142119f3183b6c089d +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..359ad3f5de3d94dee020f29f1ed8e06d6dfe8b45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4092df04bdfa1202c4b36ae7b546150c9eb8b4208c2fdd0a10ec0fc8bc734df0 +size 3340 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48aaa3431e36e4baf682bf2feced3c975e00af7b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ee347b13e03324fa6939416de58aa2d45353abf49d2974268edb9195cbb626c +size 950 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5b257cb1dad201b5cdf58957295f53d2956a44c2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfa9f334e88216ec3f8c3dbdf41093ff0625bd58366228b8f18693763e4c8ed5 +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..da7a7e578cf69534d49bc1e245f9baa6572df901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d20ca1246e05efc45538fa88921adcf96a1cff065e9596a56ebb6a3e898349d2 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e40f16736ba413da0169a57765b841abaf1a17ef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1ebb005049375997ae5edad683d9be7aabe9e9fe61adb441fcf2570dc3a67409 +size 6635 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..698e4c1f1677c0dcc9913dd979e88babc5138ea1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:46040801014c5a90ce5594329dc9aa6df9f5149b14a31a0ebde94b8af530a2cb +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b5f8f7a4b101dba67cee17287d52bc9b3a4e502b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8059543ac2410dd6a9fcc21fdf78b27a52590fd11ad5ae78e8c0ec4c50562a1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..d27f58b1a316a4f1ec709075333dfba96bd26cc9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49914d0e4622823c539bf12671155b3eeba24785cf041e53d063c497a7aa8d84 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0fb1249b15b018b8e114a958355be527821c6f44 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddd98643049e38978a0c8ae1a9bf130dcffe50dd1d273f2ff9818c574ad577 +size 940 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..69342c6e3076359aacd57f8e4586aa0c5303f6e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:241fd60dff540e7a6cffc88bf736287b5a9782b2feb0c4e06b64c549dd9a6a05 +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4fb60954e12fb8aaddaf1ea7e5fccd9a97a93a62 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c310bd2406837fa0bd6a0923ac0627f101f55858cdb76829377b7e09371253d3 +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..62ba2b0042239c143d50e65943ea37b201e89849 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f063a4c004754b6c20bf16e11367ccb025f0fe33950f8109db30b8526421a74 +size 419 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..24cac350450f348792b320bbd64757b74b48964a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:37181708cfd498a42c52b35bda7e7f8e53d2f79fe33bbb5badce97ab7e4a7a56 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..6dee1e9c9b67a46cf3bb307905801fa58e17f2f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dca153ba761027a6e81093233805f135627203e9fe4b42746a95078cb14b6c3f +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..b0806ac8edf41b2e83d7de62a63399e9c7777a09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef17a4731ea97162ec746c119be4f28692a05e2d754f03d1b0e078955ae6e35a +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ff39c3baec69488d818d8e8862c15e6ba8697bc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d2cf3e6141978001f881e237a047125480c5d708c02bb2a8d2b8f8adfc3ca991 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..989257f2cd7879e01e0bae118eb99dc460a7135b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d60432905833e78c163a5ca441762a3457df059ee5f863599d7bf5f05573d206 +size 645 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ac1b0d7e901fad6a33299d8096cce6f7180b04db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6d4572c0f1c4eb5fa790e3626f7625b2278ef32a7d1d5571fcacb8e1c4a4239 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ba5d09d21c650c6a429bb224f86a64d69ab8b056 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7c30896741da121fa904dd52b9512b9d1c46dcc2ea99073d445cdaf46255c970 +size 3323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..ed7c62c7fca33b894540de13e4af3201f2e7066e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/cardio/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ccadf79ace90894cac1ef84b0026a59475672d6fe7c778033283d112d647a3f8 +size 204 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..6f116f2fba5dd8fc3b3d3a10760f8dfb7b20085c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5b571a95162a652fb0bf6963894d4f7bd0ad6af23c8d2e127d86ae8dc999d72 +size 900 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..890861bb0bd5c3b987c7bda6bda240ac57b5d287 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e427c6255a473f42cfc122abab8aac0663a8097a41c3ac82d1c937dd870df391 +size 514 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..23d90d8e9e197920c034ac32fee3128856b1ad32 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bee7ae165c8bd90f9599466bd937fbcc6382c85d4343664f002ae95323fd72e +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d9ea289193f0768b7476e5d29c6b1091d578ecaf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e6e0154410a192860debc43db1cc1bf95f1d64cc640e1be959ce864e14681ea +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e71bbfb5fe8ff8bbf9acb97402fa7f2c9752be4a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aeeef2beec0f188de9c8750c3ba9bff9ba497d52f60356a7cb1a6e307655d8bb +size 517 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..02da94123d89e9965060193a542baf1006d1e3e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5d8435dc0d389e501f8610b20dfa241443a4f26f0b490de7a2d3217e9b4fbaa3 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..82588f08417a5ac5d0b69922556c30b885479731 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26a4c16b1bef3bb88df83fe744e9fe90f7ae6bf920c9d8ae07001a367c8c1c01 +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2979b9f99debb0c439adf35c53038c5cf739b938 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:54167a575ecc0ef5b9cfa8601a300b5158e88351e24f2bc4ff6d5051ddf27def +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3c6027d7b382d2b945c75241a2f2d08a06940710 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ctabgan/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a89baf17b151d566d008c18ac8c7c932fcc6b4bcd600cce2606683d2aa0a235 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..02a7c3eb6688aafb9a1c0f16e33158d2194fb695 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c601b334e49062a1fe2da765c22767626e2478bf295faf6313bd704732c5e6d4 +size 968 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..76d80d8440204dc23c300538cec7bb957590aadd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04804a5fcb64dce7ee245ec0ae19ea2ba235aaa0b63364afcac4200a76b7b5a2 +size 1322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0ae295960b595eda7c3ba37879df08b75c1aded8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebf7c222b1216e92accff79804b4a00d2fd44919d5dd31bc6a6e60acd036fcc3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..dbde9454a5b06bf37c29db5e87b6bdec7a036723 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c003338c5f3ca1f6f85454ca4ae95e5c1716661addb4736e5e4df477fba9c332 +size 6633 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..74d365aa8e41d2a522edf59c2ea076c9b3dbe7f8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8a2a35828ecd06e28b595f77b8033817d57b2ac1d399b487e8913c9b99080b8f +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..74568be19440089618d17c6a8a09ca1250c8baa2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4597ad66b89668b391f34929896e5efd8143ec192b8dd09743a5f369a4726e1 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..3785c98a3859f8e1c87cbe724aa130a396e5c792 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd10ce7b695ccc05ee555915c57cfe784c6b193d66223143542ad70fd2b95aff +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b743faede98137b4da69b7e73dd3c37e68f66090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4fed4a225190587ae6f6c5e7f6e9222dee02300e601232414b778488a3722dc +size 963 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..9f709c6f28b5d6bb427d30148e84c6d040da00c9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2da779761d080f7f5b172c2cfb91aed74a04df83cbae1434f4fddbb188835820 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..c58de36a0ba076ba18f7edc3eec2d4c86e85b59c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b2062ba7a64a8c780bd72d03857641634071932507e5028ab8569d0a6839ebc4 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..1fd295065a538b8d64556e1134450227a6ab8450 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1486d35116d842c5f007c9638c5f9a042f6cc16fe64e3013c495af69cd76631f +size 299 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7ee39b00043cbce7f8f6551b74b9caf8d33a5f33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aebb8344a19ee1acce6ddc539289e78027660b8a4a1b31412a337cf189e8d7e0 +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..259b9c28e2216da88f2de4a2ada5f41fad0f3f66 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225c399903d85eecfa1180717481779c5181f957bdb0f19181252966d8e073b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f15da93f1bd7db41b61ab7274b891ecc9770ac3c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa30c8613e72c13f6f7c50feee02b7613ab54dd1e83e855c5ad884e88953fd24 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f23f43a640a36e089355ff831b1b3337f792d8ca --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3525848bbb0c7286606562d2141eacc717f087121cd663688fc213aaec6b04c5 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..87edb0ad883ac38f933339b7871283e57f5824b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f81553f0c9478bf6d53738d42abc5d200ae3c7dcba6c65952be292b66ad840e8 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..37910800c4a09e68e3c9d10588d70892ea76dc93 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:55674c76480d2de69613c7e6b3ed340f4cd8264e71cdcc0245d50ca2602cb406 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d6efa05500f2c702f445ed863ecd0ce0e6741e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8147293b90e33b933bcc4f90367f4321618d12c6a6dd8062b34a30b527a4ed29 +size 577 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e61dff9649ff3977e3095a15a1b52ecb8814bb40 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4902b279f2280269a77b7716d7029fbc4138d8341241ecf70733f6c72c2aecad +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1717d47b45f0d8bf948c052a264464bb740b7213 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7957770c239db6b73a5f331fa0bb2a6833f357ab9f1f64a7b8b09cdf949c27ec +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f65653e17ca75096c7b034cc2ff63912f4c3ef9a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/churn2/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1297715bcc666e21c0ececb41708a627a5521dfc91b676d4a077066162773ba3 +size 209 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d30f0ede012a7833c2dd8b4a4b770d76147c8577 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:19952c8a0f8428d5490cb019e5126a86ba664b4ebc8fc003c4890b9527a934e4 +size 927 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d4aa3f601a85d94ecb748a479d8aef67264e933b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:735c7bce4b893f0d9e465858a37825e849e4042d4f226f9f47f0683eae5bf81e +size 521 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ce2910d3a7adde56c554a761c5e9955a44ebe99d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6686b110d578fce74aeff473f802b92e7cc4427df7461775f7b361f6661aa28 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3960734418f032c074d955fe7aedd33694c6e57d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb99b57d00d4fb78c9e05cdcab9744c7745d8aa1f099110fa7443e283a822359 +size 3337 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ae426a48600b38c867dc7ea13eb3c93a61a29901 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:92b8d1bdb969df86f55c7f6a142aee1c5e7112e3c6ccf99c06d2b6bf8a0f2c0e +size 518 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5a7ecf664d2aed9530c9d93c71b6ea94c78409db --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8f02e8ac53b185b01b03c28fd7eaf41ef6f8bdbcd0524bee7abbf2f80d3ebdeb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..7045c60ead66c0e3751c7a6a1d51ab959399eaa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0ee8dc771d2fb906975727cecddf706e80992b06407b16e43fa754c807005f6 +size 3336 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..cff6db9f8bd0a9dfbe13f3161ca7d146a8b8d9e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dd27a87c527c36e6b159360409614c204ece2116e30231f22c504dddcbcad72f +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..99b9db3416effd012701e0bd8d1a0d077a7da75d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6f3a62be3bb3e7bcbb49a451de901401bab916647596899f5b4a507a92073f6 +size 967 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da6b9ef6dd806fbaf4e6f1b3f4906c09487319bb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ad87d4183c7897af8fa6d4a05a27527358bf028b3a7c5a7ba9c340f7618bbc3 +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5a402f4ff2521978ec9a1cc58e0a87954e46948e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d11c6eca82e0a9100d0d50d57a43acc0d06991b2e21eb6eff7b089245368685 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..d92579fd95aee209837d45082b3b356c9716ca8b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:15f8e3024dd62268a2398a89d07ae61e96e1d41531a74a919f3f025fa938c5ee +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5b0a2432100fc991c08f4124a8690c4a7102626c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db7e6bfc7b94bd5ad744097626148c79ab7334ad5cb3de320ff4f8b36a4e719c +size 259 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2a46dc0294af8413320fc3d932da96d5ceca964d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a4f55e7fd33edfead9868f09aa942bee3a0d6dd071564fce97612f875ea8160 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..bc3c5d4770e88eb3df2eeb57fd0a36b2abb756a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0718b6963905101eec88b075186859e2379f3f61d70f492e30941b323072c94 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..65ed7fb261953c72d2734e4d1dfbd5c1fa61ff24 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:206e30cd29010a15d526d9bf307ff9e220b93d9d65e142498c913baa5b2e6794 +size 905 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b2525ddf750cb43cb10446426478ca0d352f9d87 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c378d9fa551517824323a936dd4bfa1176ac6daa2ebd7a0948e5537a27e1b64c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f6999ba31d01ec9f118325fbb37a1bdc1f1c97dc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:25ac461df4235687a4012bf375919c8416dd3d5f4934002a33a47359702f31e0 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..14e1055fbe71324f8d1b316e7c42fba105dcd5ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4df813362412b44dc398a2d105242831190a9f46b54a0baf14f319ab9b0a43f +size 401 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3a0d3c9b2e132ba75b354c6d433fe5c6e3dccf69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1903dbe282b8414db88bd733bed0abf2cb61970b92826102a0da5e3cd04374 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f5723c53a582026c2ee3b1e92972272e297ac8a2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9fbe41349d882083cd3eecc13ca6f3af44bc47878ef9426ecf24ddf30aa1a1b9 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1351825de5ca06090b694cd42c3ceba59d97e794 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6358398a28b79dd57ee851c40462f5a514180d6d06158a58ed104e9af3b16dd3 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..44ecb044b241ed35d3bb8e36d0d236c93cece41a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f7abe796aa6e50dd2efe53f6285070f2b3b38e68ea8e02ab9b324faefac47b75 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7a22dac1ca8ef349cf2e70b8e8c3aa8147f43bba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6be0b028d0c36c4dc84cef8da80044c409ae99bea5e4032a5f657e14778d0bf9 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d79bc224a67304eed73f67dab601806dd36cc011 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6a642fcfa77c00fcdc72b9601b3ac97ce51ffa4c6ed8597fd40fa813c6c441c +size 578 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..07c8183cb7a115a895147e636b4f94c773b98112 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:229cd05169992e974284aef4dce3a714d7f621072d7e3ba47bd0147d952c2032 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..c933269e3b15eff51fd2530aadda7bbe13e702ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eb14e8186c7ee0cc954ea8c674750026de784be55db0371d7eda25ac7119a74a +size 3318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..3bdc442e9e4489de65882258c05bf43a06ac6c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/default/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f370369e0a38586d30c7421bcc66cde6703dd8ab748ca38463765ba2e80d788b +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db8a2977a47b2e060bdbf2c7bf7c835c7ac3b701 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1044d3337e80aa3a09e1aaf07c6e0f944b8232c70027d2d650c99a29cf4ce84 +size 918 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..64169b1082ba9f39304adafa7713b56f2fc1cc5a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1d6b146369ba3283478dc5a0016a8f42ed56d7df0a9057e41604f197e5cd4b0 +size 534 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e2c3ce3255a8b50b919da411cdf7186713c7be4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16cab54b8dbe820078b4538ecc0b3a44b264e2c1b060dec84f891ecd5cd8e2da +size 662 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f565d2a7b29d12eda6696ce249df33284dc3e942 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a89df37209f3ea372a4aa65a723aa80ae696502d7e39d61b96368b764b41ef3f +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..c9238ac80736514455ce9f40ef17558e459f3811 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:020ad746993891a7b7e1e3680345c1d05515c059d0685a126c4473129166e150 +size 554 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c461843206ad3cbec9b3d2a03ebff8734dbcc8b3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef0eef618b42ccf2c403385457cd075ea3815ac3b323206e0899b30524cfc7b1 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..45028174fec008f49746f487921eff5a9ecabda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:16f7e4f7a24d25d699923ba9731a92b9abbd4808ce3dc14368d657114f701ecd +size 3338 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..9df42bc64e8658d641d774b89b55bfa9cb15409a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5490d1e7ff5355cae1350dc796760ad6f75259ff7fd92387d0c18ffdffc3c85b +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0d61611df3edb22a4fa7e17866b3528ae725e646 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b22a91aade7709026caa9df573adef3919be7295d2aa42f8adeee2e4f6cee8ef +size 920 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..1e3be13787ef2353940c2ff97f4e3c458b859d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d554d53508f81e3d86513abaed89d81369c452e67648b445fa8e245bb8fb3ccf +size 1321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..ae8c50f8789756015254621cee945d1bdf240692 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:619f95f0490e193ed51da45ee60e9fdb393f6ee5e441117bf0446d763304ab1b +size 1316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..406ff1087ad01f0f5924482b967d16b657344a3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5970542d676a9e85db91793c1a6567883769ab254860f446948750825e715d2 +size 6630 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..c97fdc4bf623c0bd2820e22b138e0e8db2554855 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:74f92933f99075ac5696382e6a75e06808873d41d47ddae66d1bc0f73a87dc51 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..c6548854b54b44b909f204e40525c40e25142db7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ea4fa210ad435e41e9bf2632985560871ad757febc593f33fc1c6ab9fcf52d8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..eb6fd2749050c7886b58f0521b256f7f4d054875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c50563d980018084c24fe631e2b4a5f3c37a4c483d5d1f3f71c0d1001bf17cdd +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f4e72e3ca6322a41543e3b2817a682244ad04229 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b41c4feba56797309e908d0c41c8a91a0fa443c9ef5813c34daa30b0cb61b9b +size 951 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f354a7eb9b7cba64e1beb92da8258b3df548716 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0502b6755b48092f0e9ddc0a1f9e7910d8c6a6febcae015f5fa52cab91da1b4e +size 659 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..d3733b848b938dd807ec0a3cbc198e43a038264d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91a7a88913f932cf51b78509880337d29ce7aee87fc0488f5c686615f3a7f1c7 +size 661 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..93259a0b10c64dd8521ba6d3778a597b9caa9c74 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b9e7252bf842b1368f383a1fda59c5052d65cfcd691ce22185b0b3bd3a15e94 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fb86c4fa071f539308d8942d26bc788ca701dd7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1684541d340d8245725a274cb0f3a8df4269897bae8c0cab5ab13c9ec3410c9 +size 425 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2c465e0671a0d8eacbc90fe6eca9bc28592b154c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6d6e731c0d11226bcba2aa47683a707a8d0f85448d76466083b2c860f14dcad2 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..aa2b02b1418f83403abb6bd83fe1fe510ba64feb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1930c824d53c8691382820704e0cad315325343252257232c15fcc7ced22593 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..80d37feed69d46b96bef16cfad0033c3867079af --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a2d82505f43d7cd538c651690be0eb1b6750dd63ddae81f3da55f3366de78cb +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..3047c8a18b85dd975e5a5fede0fa4f3c4924e447 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0b8decc62991b71d8d02bdfe76474fae54dc771e37cb7e5cb388ba93e2b5f63 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..12c19d9c8b4f9ff69e3b8b64a4dd72c542ffb26a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e72aa8a518936938f25ea7332941c9797ae045cf0aacf15b210496f546374e6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fc2cdf43a114c76d6f4d2f31044559cb0ffb41b9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c2c01bd6c97390826b97479ff7d2e267bd8a938b2d94838c2f2011bb2996b2dc +size 612 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..55801536016e53760cefd438950112a0ab992a01 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0f50a6eb92711153300e23c4e8bbec37739c833cdbb38b12ea7e58e9e6689dbb +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4ab187e19301452f9b46d116fd253c282a43b6d0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:91404eee27abb530eeb50afcced5735db92546d32521326001405be6a5c40707 +size 3322 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..9d37de07649e065d5745fa1cc5f63f8f0881bbcd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/diabetes/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50dbc5570a52e17518da310bbd86973ba7e95e01702ac4636c81e743d164109f +size 198 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..333f6c895f63304005939bed734c5b4a3ba23495 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1bd2f7237c6614f727625e42237b558e33e022c2fbd79752fb3246f7b44eede9 +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f7158576596ae7788b845467937ea3a4ad9b7889 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f1723bffa9730b2dc8d2e657be7336222ea277f78a841ed2e9f575416ddc7b4 +size 541 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..436b7fbc02226c3d4a24fd72c27d268fbf54b790 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9a79a0099644def29c2966fd35dff1dec2e05baf62b955be7410128dcace002f +size 458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..8fc348a12063c0c14bb14d84fe5f3f42ab00b40d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:519804cbf1f8f280277dd9beea08329578e68c3b22758bdb696f8178e57ba3a7 +size 2505 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5d221aeaa17043ac673ddfa8ace328304852d5f9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e91f5a1d1f3302edde0c65a604cdc23cfafe6c0b418cf2a8b83b841c7c342b44 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..61fd254efcfbc44b3885c31c0616e157f66e720b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:601d66c4668274449c4a46b98255fc3bcea1cbeb0052f0936ece08fe190fda5d +size 907 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ebe53d92f95f03144b958faca7db5cf3e15b1a42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17c0e6a89a4b5bc58d756d439888ce605ef74efa9b177a8e8c6af9b405f1361b +size 4800 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..61c51c1d3b9ad8057df88c53dfd6a5bd442fa328 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d743a8baedd8c4c815620260fbf23b7330b1498a3d7b26f84fd1ab4ec64a1b73 +size 296 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f224d16ca9341abd1dae347b7de8de6fbceaa3bd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e2bedbc213977a3b3fe5e11a7c04b32ee3017838a7d09a887bc460ee8227ff6 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..5ffd2305107e6b846c8e211b14255e83446be141 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3cce986a96cbf4423cf1bcda4f374410adf9474e039fd149961c8c806580c03 +size 413 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c617c43c04116720c9d654763c72be848070f707 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94eedba18072bbae480e6fbdf10104f668d6666848d6365be3c36cdc9bd66a35 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..85d3c0e39f51b351408d4f0435173c1a395eb070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2392f0e4394cd09cb0cd45b87aaf5188496af4bc5ccb1cd946540678a31fe655 +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7278ce874ed61570ccd5c1763a3aa160a24d8499 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:048378c429d0dbd4891b9b12c50903e3554e9d84114bc23846e0b648b579d1a0 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..fced6196078064e5431ec67e3ca68252a8e1fef6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7b25fc4d49942d7b08d84b9168f733f4b9734d568962c4521943a3c849662f62 +size 589 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3d15815d1593a179fcc73748e47a4ab5fc2af4a0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0a72d23a0ab11b3df278791ad149095aed53d782d7a6ccc3511f4a860f80970 +size 459 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..55d8628bc23724a14f674ade448134b1567e4520 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1db91a1ce3ffd88daf75415408cf9472ac868bcc8168a0cf75366dade0b5caf +size 2408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..39fc4bea1df48a54d53238f7aba436caea02f516 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/fb-comments/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7317f444a3e1488d5f92ab368356303ff392de8545e982d13d3f7ddb5848c400 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..06bc386a1db8469c5f21b3c8a2c81d1741dd446d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0a64df287ee37f9431a592eb17b0280e440d02a003fee701ff2945ab5c37325 +size 910 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..d7413f0670c6edd7361c9c7b82d9fa85aa6a0908 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:32c35703b248e0f0372b9e4612acc3a640730c95fe5e451abbe4c15731b5d6e0 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..4d367e9abe1b44d5bb3b0dfccd75ea9967e01916 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa6e6bad2cf4145ea9388b0d207adc07ac8c571c2f779596e036e32e42b09fd7 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b10013726142a28b922fdbbae928562aee46db9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a12961a2ed12d47994fc41d22bc8f7f7e8d4c958d0d73edecbdcc5f8e07b4435 +size 2395 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..047615bee199b90843580fb20f179582f8f09996 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4613d2c2e1fe45c33d3545570f7cd4c035281c1909252be0415c0b95e298356e +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8f01095b225b915cbb53e7577a076e32017c1c8e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:51071871bd60b5388d81e23d9d36258836180796270dc482ba564e9621a2a643 +size 453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..4d08b1150e13ad1bfe9fa4bf5c4a564a07b0eee0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30a844cd0dd2933bbc3dfcab3d87e669552edf034821ffd0a6a4a18f71d813fe +size 2396 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..348755b263dded3e570682a653db8f053ca1357f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b3e6cd385cf4f905f491d54e29cc2ca35d9e6f910999af71ba913b3c5ef802c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..feed14b0f46d70949715e5e0c01a36d92a853510 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0993f5e522483b64d082bdea9503f95aae33fd65167630c12d82197f46c6dbc +size 929 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b13723f7431bf66f747a541e4991ee427f7c149a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0b25543c558ddd0bb6c114fcbf3e06b3c101f7733543b9013a9229e02d394b5 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..3f4e583bb1fd4b2ba0ac11ec89b8b9e2a2a9f5e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e0ab5ece732683c2d181b262d5bccab99821fb12b880ceed78f4e040b8c31993 +size 896 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..28deac7fa9e4a94c6242e0f0c6ffa4f353e8e08f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b63b0a26f2f87c7d2661655b8c9268aad1265ff4d7fe4f99535099c6b36338dc +size 4758 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..4c7232e3157e1133cb14ddc0f32436404e94c0f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d63b0ecacc41763b74551295b1542ce7c29c00b558c404b533671f3200842833 +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..10d829f9802860a47baba3df9e9d8f7ea585c8a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:951c1d3750cc6631207ca7d6703a58c674a0409ab2eb63370aa2d5ba4700d7c9 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7237a8277a25f0c18163cc5c8f02a0495ddac37a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:11337372964d7148d6daf843a3f8a8456fcc2abb21a7d3bb1b2d71ee714f139b +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..24334b8d23bc604089b3b05e472de861477bd5f6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:48e3c7798c169dff4e5c80a35c11bb71eea5b91b14cb3c80f1ab78fb1cc8b34e +size 405 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c6f4f10d7bf4debd0e0baced9bba617420fe901b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d055d710a9d9743c9088059f5f3ac687c3b4a0039ecf6749df6f669542add73f +size 452 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a32da369bdcb78b612f903c8ee05338643be7afe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:398f0937631d218f8637e9cbbef1383fa54bbb88b4f9ffe33acc1a836a479d29 +size 2386 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..03d0abb886e6c6779a9ee57a90d867d538b266d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:be8a997b12a5ec6cd39aeaf7c46fc98936f8611977942d0474a0a20255899bdc +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..497c8110776c7faa8eeb0a2a35accc0b0cdee6cd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d28d5b507fba9281f6f44380755b807674395417b853bd9442ee8ad52fd0f43 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..45c057f2486ac293fedac404bee4615cd59c1a97 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1099d2e1bfcc8f278c6b0a4cd6688526707eb2b7d80c7ea784d2d20db8b3da9 +size 579 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..0754e116055863fcd9138a0aeb61e3fcc087d219 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00542b3e7203234bbf573df38c9c5f06ddefa0658f337b5049ba8c35a4004905 +size 451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..800189407f477c0ac2ec1e17adc27f582d5d4a7e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:97fcef113d1275c3927abce0ee6745447b6c2482baaab3eea683c8cbcde7e43c +size 2384 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..7ab27f916e6978ba61b966c1306fef87b68dee09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/gesture/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:01e52cc6e6667dd051a724d7edaf44b81009f368ac0758488e48d861fede0828 +size 232 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..03fedb7c3dc25ad84d634da3a8b9380a858b678e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6a307600a0653c256432674bf2aa90990aba5f6a2a106e98e9618d588dcc7b8 +size 948 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ffc4c8ebe2fc39c897e30d7de49fdc1c2d31a66f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:760a12bb8b1a4b9ad522cdd0b61eb121b7d284024fd33f55493d07f96c1cdd5a +size 542 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b8d4afdedbe29648262787959ef96af1044f5f4f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de053c21039056c72a5cc3f09c7ddbf4ca3f9d16a7470c2f151e8c2c5bc461a8 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f8f46a3b3f773b4b986da71fd770b536d8aaa389 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a213faae594be359b84b406ab2e095cda9db5f9ab84e615970f1704259419fff +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..39618b0cdfe57e8f1b175668ee707b4e9910e808 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b991465bc1317d2e6ef0e57d37db6aff1108f4e6b492153c9e8389ad2512bf78 +size 546 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..75c93249436dc211b3c88c2dd76b0ac75ae03555 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00ba696dd5ebad1b715361d289aab901914cabc28e4462205016e273fce0d66b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..011849d3f534676137699f3a314759da540695ae --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d55c8036621ff2c9b35825e8268b11630b73ecea40c3854395f027fc44a29550 +size 3335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..2f712d395035e226a28266e663d1036707bf132e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cea498edc79f0cdfa0d9cb168b8500a2832a3a2089775e33587710d887beb4fc +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..dcbb2d611176a2d8bf2043af45f560aaace04ce5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20a3fa610b0ea4fd4c5b66bde8f49a35b185a8c74908324bbb603d36ed4b7428 +size 989 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..2dee08d78e7baa81ad1f2a43ec880583703c019c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c23a761b16ed59a3bf4294de51155c8fecd406103e3a5be1c757d5754d8acc6 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..0cc09486dec2ed58becf0eac48fbccd216ff907e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f508f21ff5d6e2510fce419fcc73db98fa0913b263a0aa8074b3b588ed51b1c +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f950dec45a8f48ebe7a2488eb48e30043f36f109 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f8469720ccb837070f8d1f0b4b63151ce8e6434620f869b7c5ac9ff36fdc1b5e +size 6634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8e705ffbaa56cfed732689cd10dcb69c4decc919 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852e37effd946fb65b7f394fea65547d8f8f3890f63eb9db6c06a4cb6503e85a +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..75556e02a7e1071f92f499e9b9e13ea1d7db7c6c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2705772e9869c7fca46bab06caaa10e427e5a1cd4d6ab5042a6e279a22e720f9 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7c62e69622e87f6d7e57ec9c82c66d61390c2d18 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6561fb96f7fcefa5ad991ed8e641629aefadb88e54ad82a072a3e83e22ccb35d +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..3f3d1c6e95ec4d69e9b8553aac109247c799bb91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c3ca4a3f3ead7e37b28bd406afdc57ac1739d5ef6508fcdc0e201b0bbe4204ec +size 414 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e4875ccf24467d05d4e8cbdc06cddb4a5180dbd0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:344d767fe2a9eb740e16d18883d7741ccb939978a3b99d7e73563766adaad05f +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..a52d447e1aaab3ea5f028cea2de591aafcf45424 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d72f0802d95c5420400626fb325cefc9aa236cb6dc58314632ec5d4169c4df67 +size 3321 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6a33a35d66132cbc14f5658343ceacae40cee5ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cceedc073ade6c8c8c944873e34bf2938ac96cbcbb6eaf05954c50b6d9085e4e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..9e8df7d13edf6634d616b42d800942e08d955062 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a557708d6af14a05fa86398f34357b5d6ef232e4296786a5d8e9ffa9c08c538 +size 622 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..25679afa0ba5ce7a6c2a746f04b2f46f0292f4ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:615fecbbd6b5ff85730ba4e9fa56efeece74fbe38f9ea1bf618d440acda6a3c0 +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1cf49237444d6800803452dcc9bbedeb8bc8e950 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:927b6b4caf572c95a34e24ede594379a2c1e726db80161d2947b1593f0cdd138 +size 6665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..f905897fac76a9cda4056eb5860a8ff6667a8fe9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/higgs-small/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:914fe67c0efe612d96561be21c706e7a226a721df32c2b62c9924dafe69b9332 +size 215 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..e7e2b814e25f5bad1bf9fcc595954e7298eb3ea9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:528b40c2d3222184ffe33f75d19cff368f89da842a9ecf026f79d5f27bbe5276 +size 937 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0a7a4de2400da5fd39dbaeea852e919158901d45 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8bd3302bb25952c83194457388db6fea312a7df0745ba8ec476a158c566d70cc +size 528 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..80c84796e2f248316457ea713365801da14d237b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0a1bbba8b256a7aed551747d9063887f788472058b7e293948c4d47e242d23b +size 469 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..181bf61c695df6664b710767b0fb71afc8437d81 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ac9e6f524f29c2632ed8b9a2646c5425a50feae61118d3132d65320d608d19a7 +size 2479 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..ff88133c4fcb328ac7b16552747fb8296426105f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:225d032d97754931a2c9ee8811d21e445ceffedcb5035ccf634ef48ff87302ad +size 995 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..d20d4457b1232ba47edbce4f64cec5f6fe7f1c99 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9c7e4b3aea3b986a6636149776c64ddddb2cc600f26b257f262e4b56618b3e8 +size 930 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..b8ba0ab926f1cfdffa5fc258c9f4d77982ce44d7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:666746502985de8e700a9fcc0039bacc9bd146af432fb05b82b54355ab2424fd +size 933 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..042dcc933ac97e20ed3a22ff880465b27dd5ab9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bb98360a56b180db06997eebd23a60482932a3747975bac918508bf02f4fb9ce +size 4915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5fff3289c7229732080c62d40d12efc032146f78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a7328a8b0d0c9a7de6226a7a1b8e514564d3c1083eb12c4ba617c5c6807e0228 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a693dec0d8434fab0336b794dd1e28c68c0241aa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9045f8011c485cb55e81c9b4e95ca0fb052c9a3435e35a69a97b41797cf282f9 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..b7fb08dad9f572208abbeddd84e0740aa356c230 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bcee542673a48e33a23092776d8e96e6c1e4f3b21b7b8787d1f3a9073f218f91 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..adc4214b1b074d65987ed797ca6cf6448a5747d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ffa43c89ab8722792d7bcc54bc7dfcf5d41bcf20e3f3abf3d8e88a5b98e5978 +size 952 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..5724f365db7fa2c28eed384744e97dc87946f445 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:23b8b7b4d549a42eacca574e4ce2266e7c8bceda5272a33c987eeaf80b7499a5 +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..2a998cf2f7de0b928103b222f8535d6c0a047e2f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7fe0b81e4deea87c242192e524807db9ab3f66e1dfc74aed2e3a78bde723f0ff +size 294 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0aa03ba62b1f302975116c4708a8a2efeda92ba5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2442f27f517cfb43bbaf59502be5cc6db24b9a097d51358fcc9df365d552dbb7 +size 402 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..314883b6eb24933d65156973e1afc1b27172f10b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d4ffd3b7adf6fcf1d327e847091368ecf0f71b40cb8b90436c604dc8a54669b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f4655be603ea1109fa208164026d376cce26be50 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b70d420cdffb87014e9fd9ef019ffdffddc58b56804ca2e611218f803cf28ebd +size 2458 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..d624e6d584ff582a265185a7e5c00e6263171faa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10dce84b0bbee2494ea0aa43beaee9c88dfb5a403bffe74defa700d6c785999c +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..e4e13829933f8764d73215cddebec4a13a2bdc43 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ca465ee811e532a4c5bef81a989ec7d2f6244a5d4742d0c363f74400f207d533 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..0553bd45d276e79f8b49d933bab6b0cf2932682d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:200ede2a5a9a98be57706e3fd0590aeae7ec160b4ac513f18623c24115764bc3 +size 574 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..c071992f864790d496ae83ffbee48595a2ee851b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b6611f4f0149cc926920743e7476379b114acddd6afd49d1bf6d21f85071ca6 +size 470 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..1aea951026ffb023621fece858640941afb21e9e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:861abd015a5284bd3a0f736764f7da77b85787132d418ee479a80208c480e7be +size 2465 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..64079a15d05916017485acc39a763ccf437abe46 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/house/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89633ac45b39452d815bc7f5aacac7339fecc8d4a9572498ad579014f19f0a06 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..2c731f01b582631631de6dd5b69699a73dda7413 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:82f4a7e5f3e84c7becbb90e602fb8b151e344a33b3f312e8e7387c05994688f0 +size 942 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..db7dd19a68e8eaa1a90ac71139a334fb0687f77a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c9c1217f32b6b6726f227a57f803421e181ba4e35157f1db5f9ba914658f5b94 +size 532 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..82defe6d7f8b1ef7a378ca83226604cef31b6aef --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fd069f690164256d25dfbde0ad8790f77b5e232dd3f0adf64410b640bb54c231 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..3cf46d58eca19c1941ec9ee42c919739cfd8e614 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4c846e7b87f5eb231776d149668781c3c940551ed2fa64ef6a5954b49fad91d +size 2460 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..82b2a87a76a82cf7e0f9098ff754cb6038329b13 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d7188e5d993b28be90477dda30d16dc4fd1492c0beb9938af03db9ac3093d8b +size 999 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..3bfd8fc770eb00509cc2d7c43232a98b8dfd6cac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cb22042a278459b9fcb7136bbb89dfdb1f13ff0258629814005e0cffbcea145 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..59869ca6d0de7c94394c981e70dc95c0e1d77a48 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9de0fa18e75155189845e29cc0befcf4d490d93264d96daf62cf75a30c90266 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0676cea17ec67a31e17a9cce1fdf6d11fd3b227f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89bc8213e080f76469119ea5b91e606453193d49e4a866cc495b0a589a9a0c68 +size 4889 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..f0ffcb99149d3510c70a5924f8c422c8a76150e5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:43b70402cda9d2dbe0bb5b51677c5c9882bedc445928c28a8c3d88f0a7722597 +size 261 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..6726199f5fc33e63365f3a27b1d556e34018d3ff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:323963077416988f3290d9e3816e6550f872cd8744295396c19e5b6f5dfc9c14 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..2f84826ccac5e886b0d45f3c7c185c7f194576b7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebc777a785cb2c512f87e6116d47f4a3d9fa5260f629c979d6bbb23839473670 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..68c17c15294f2a17eefce1027bc156e07915aecc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a64ff8200cb6bb6f30ee4998d6aace8fc8066b3c66b8337b16a24f0b57f4c8de +size 956 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e68da611dd63a6d7d426532a1ebf0e81cf3b9ea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e8beb48203d2108f658644d5cb799fd535d800dde8c722ee8e5bfa2bc21e153 +size 924 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..f1e0cfac11b1db4108d81e074b24ee18d854dc1e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a8db2791e30a92cfd9d3fb5d6186b60cdd93fe10a154ad1d3f6c0d18c1f83e45 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..5bb618075a1cd648a4818610f2382e789cd4864d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9dddbec95d017fd0f2afbfebfcb57b24d887f5f2878e4d732234866172e05cbb +size 304 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..96cf783f5a78a8b7ef0943912a1c8a4e7c1a9b04 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8325b46ce43140b516ff717a80827ea672bd68ac683a1d57bcdc8339d931fac +size 408 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8e34e5dba6cc530710d3f1cf3202447d4f58bc69 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9121c85b1e76356f3655e4188d9df2b4dcbb6da03d44803100e78f535ce1cc90 +size 467 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..96a4fb49c1309ee79dbaf34b2b2bf4d72897937e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ad727af1046c6fda6ee582100b49c9a7ed67c1c0c833b1738d205d0fa7808a +size 922 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cde2235be891eb6caf968e73420ccb7e93804e79 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:21c2d26d84679802f8b4132dc40995239cd6f33e70767dd3bc120baa6823d895 +size 2451 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1d8ea5d488d6df9d75a1923b24f3125b08db535a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e76cff7f9b4eb2fb998b889fc817cf39bb249629db4daa02bb446e67f07508b5 +size 224 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..8caac97df53e7631ff8245ffb7f93f77993cea33 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a03e4df9aabb8171933be16412b46e6b923800570a38e64e5d4eb47678b24dbb +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..637a56dffa6df001c96821966fe51c863121f1f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30af5515640c2f6e99eb4c3c548da06f3655333620c97cfaa8cc8973d656b9b9 +size 613 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b2ffb33dd7f41e85f904227b5db70e908beb69b0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:935545449f1a16d3bad494acb6696a8b7748aabad97ecd0ab08f8207d4720518 +size 466 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..5ba59bcf12636686aec9d51472c29b53e312cda2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93c7fd438e02f13da168a75942fa3f688fe5bcdea85fa36d0d3a7ea9a5166e60 +size 2453 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..90581136fac3b5be5106056730713c1336c10fa5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/insurance/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8cf5e9d409c0e722490f3f7022f1438dd732d50f3ab7f3a4685e8657071060c9 +size 202 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..01b0c1903a668d152e59453c4e4825741590925f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2501990a6f1a9971d56afe74d8325eb72316b430eab61f47c20a4733816718e8 +size 915 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..23caef05e9d2f190d9c86804e5aeae5964c0a74b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0410035c53684e65b6334f5656d05b0f07bea79dacd6572a2b4dd53997c8d9e1 +size 537 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..84a7af1afc2b623f4a2d67bb18f87acbe786e635 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a52646d49fcab248f6444fd18ee3c49d18dc08626d7217040171f968fe3362e9 +size 474 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..f946659046f385d36df7e50003affca94254b83c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5c540660e687338c470bc5aefa1e709ccd01c1670b59f7ecffd2787dd1afc2da +size 2494 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..89dc12ec8c39aba29a00ba8c25104fdbd2ba42ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d0e482c20284d6d6000c0148e8d374cbdb418c41f2c1b3ade6319b328b1a6a02 +size 955 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..5e142ed3b2f59d2438094cbe8677e78e8c04f660 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9549ce6fe83ea01af03e88d8de5fb0005c92f42b572c47b8dee23d8dbfbb67c +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a73dca158c0ad485c1ddf5a609df587a5995ec9b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a54c016ba583d3ef7edabe2b91352de11dba9ddbd0a62b7166ca2494c6277a18 +size 939 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..9d034d585ff4a822b9e63c222e54536ff12c2a57 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c5972998ede37836bda6c5e6eeb12e20c861d3909c4b744f6dd58459495168f3 +size 4945 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..8705207de466575515cb19bb0881cda69d13280d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0087b68b0690a0d317050eab0c6368ce49c6798a84f7bfd43029c2b0cb9cf1aa +size 297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..60be27b26835fa89f9ee4b9579363c81b641519d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f114df937a0945e54dc4283963aced75bcb1e5d5fbd416c5ff5e7e812cd3fe3 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..ca413e55e34e5a914ca4b0ffecfd729517122e63 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d0499695456bfd89bcbb3e16775dfbf3491afb98b31a6aef86406f485bc2165 +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59ce7d1bc92bf414ea62fd8a190b32f3b8ac6c5e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc3ec78379ff2b32d2f5a96626e368cd86dd2f41195097f858a4c7df201405a7 +size 916 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..77acc58bc044cc342c01f2499f0e486614a8f070 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b185de1dadacab2591684c34b38139226160249070984909d5850f69e8be919b +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..7b1cff297b211e9d7fe781917de6cb1832d3ffaa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdd2ac1705b46fa74fd91bb9a9d298ed2c2619522583f2b04e6deec9507da733 +size 300 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..eb3dcf1ba4fab107a4980cc00e2947dae446a951 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04e492ffe3461aaf60a3e057f86b7e53393d186e1056fa50eff7f58f79f10dc7 +size 398 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..8a61230d936a15c4a41d014a7363aeba42516d47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5e598f7893e22d41860ceeafea212a0099f57d612b866a6712780c54f049539b +size 471 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee911fbd3baabd3aa7892d4b0added38441098f1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6611343af6c0bba0fe21919246a40ef932677f1a34a511cfccb5396c6298e73 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..68c9b9046264a2174c9961b75eff74206ed377de --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6857de43e22b45c9e4d371ad7c24ee19a913bd39e60cd16b1a2f3229cf5038a8 +size 222 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..7926254c224b0a0f65174156f0fec386102bb541 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94644b28f3612e23555b0475725f1ad18f9620b7acee9348b501a40852bf5b3c +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..619c2e20cfed2e5293d150b872a5733e1f096c11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4fa9c2b6c9c0379e006e4490691f7ca47d95732a984433835017b5dc8c6a4bc +size 572 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..a96478c5ab30457034d6a7a0e1948a25dedbae3f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b221985167ba83bf9b2e8a913d0e683a9a71701aa8a918d674c292180dbd85b0 +size 475 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..cbeb7697694fa8b8ca4812825c752ecb6083aa7c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:194eeb00b693f9f992dc12f48d96eb1e99ce8fa94baaf7a28bd5ffc83657c390 +size 2477 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d64a357ac891ac429c0627e817cfb03348c611fe --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/king/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df6a2392d8f77f432bb6082ea160213c5e3b07582fb6766f8e6400d2e6d7592e +size 197 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..59217f5e124abdb29822b055764cb2336192324e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d27dd7c459b26f8da75d5d114d757d3504c4e2ff1fabc9145ff0163269268523 +size 925 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..a21b74b88b43869b7621a6fa69ba3cee54f99782 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de9e1c2397774b4f140e72195d67299087201e8f7c3398f553a6ddbedc37dacb +size 548 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..dcb82579a446de24c76a01048e7ee8b45dc416ec --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dcf46d3c26fef0a4bd282a1dd5540c51306a6c6d27a7e021bdc3fa1f04aaba8d +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..b964e2eca120d5390d8dfd54da9bca84a89b0964 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b1ecaf38c6e4e86723eca4b70df721230ea37325f3e31417136f680ab6d60eda +size 3331 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..005f4532ca87e7bad99569be51c03d60c2e731bc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0873d39afcde743c203e38b936cf02263464359ed77ac9a4f897f4f0003ee8cc +size 543 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..95cec34a17bdc318a6f58a5142d836684ca8b741 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f94910601e7921ad016dccf2efd73b43f3ddcebe8222554c961020572046f8b +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..e263b0da0906813ed00fe2505223f178721e46da --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c0ff62cc7415bfa76cfb5f8675f03443908fd52539f49078ea10f6f78f6785e +size 3339 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..f75e316f0a7cdfa1d46f9089211b3bc1790045cb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e11ee201bd58bbd68ed03ac5c6e098db1691d6ba740612efd613d2e21a7eba5 +size 947 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..ecb3c2934097a8b7eb1f1c2e8bfdcc1bb6c25cb9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c24ba2f25d79231cd18c84ab6b5505c3800302f52c60ea4c470761fa0664826 +size 1320 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..318516c152168e5aa47c6ec1b99f2de9abab8478 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f11aad0bf39ecbcdfd2e236f22f5686c5bf53941e2bf72066b650a0495bcfcee +size 6636 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..b877e61d6fccc1cf63a37573330494d8c250a097 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4f4ef7a360cd7c0246258ceccae40c700bff07b1c2450aaea29678ec997c8fb +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..a4c5e18b0426ed2e74a44a403050bf1a5e2be397 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:156845e255990d64868edf68e6e94e4b630a35ef3703908d4658bb4205e6f520 +size 219 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..07359eb10ef90d970d2fd3da8589d23419ba30e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6eb570950be50161b508f032ab7b386834970b1b8320ea009df29b04fb4f59e4 +size 38 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..b71c94cdcd14cfc6ad2b5769feeb0e46b742b038 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d399bad7ab925769e8dfe3077fdab3bc853c456621aa535dbf11b13b649442bf +size 409 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e434db77ae4112e9c66a54159b515bcabbc35500 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:daca0ef299413efeb2fd8bc598c2884ea7fa8e31cce9f5b22453149824003a31 +size 665 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..fe89340b3e1abd6c60af42955bdb945c8c73fd0e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d264ff9ea11ec6a85605548a246318adf764036594d2487c6fcd011e0451f468 +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..4e0b74e541216117ba45eadda4227de72b77a583 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86e468ac66b04c5880e87d36fa4a0d0f3a8ccab2d862ca9b2a087704161aaf5e +size 39 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..8e31eabdede3c3151591a3355d35481bd467ce49 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4fdf1a753db96dd0306665a4fd7ff63d384e63c5e38427c3ea885cde8bc25758 +size 564 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..fc3508af285bfd1620c768ae0ce85d0aefcc3fed --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ee426c8141756e86ed8ce7d5e105d1696811c92fe3065d5f9a542fbcdb2cb41c +size 663 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..65895fb508351e878a6f865720c80608c59f1419 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aae996fb7337a2dba7582f817f088044dd4fb6e356600663f63c85387a24adc +size 3333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..eb27400546288fb6930d800bbdf6cffa9b02a7dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/miniboone/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3274411236a9a8d09943070cab33f440470d28ba5f17ce60a458b588ef17e883 +size 207 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..126909bc3023b69440daf8f5981671a32775db42 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0a8bd128e8d1a59c0fd1a6bb71d659c72bb66d99d25b64a083055aa5ae633481 +size 903 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..48207110d55524677f763b36f2ea6d082538c8e1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:df7a70b973fe406e3364c2b6674fc4be7e63a60edaf4bd81fb74939cca9fb1ea +size 526 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..e47d814bd5c743b65a2e956899c1a85ec99c2971 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdc03d3794d9a6fd78252a8f39e39f6a821f2499675d821b05ff4512e594de7a +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..0d59d5db6217391068a935e4eebbd36a7dfa9797 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1c65acdf11e5ec81bcd0551c6ee0e1bb1da03acdbf8fd61ce8cc84b595e4eeac +size 3326 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan-plus/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..992ed273159fe044446338ef18d20b301c4389fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:abb13507a3bb052941db91eb54f82c61763476196c0f582cac37b54b205a63b7 +size 531 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..113e4f8760a40e53ac65debb316e5334adfdb6dd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14c54983a20fd19a7ba0656cb4ba0882dda6ded11e1a3be406d047acbebabc21 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..ee4457b8f96d7e9890ea1b76a6c65bde78330030 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c10fd9c09819253effcae1c1af19dbdf17bfdc061427e24047454e53e300f57e +size 3316 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..fecfedfed0d23c1f5790b4d32fc72b2b927abf9c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ctabgan/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61cceaf47946a5b94f37258fa4d53bdae5417731ec3cd7969824506746355ef7 +size 221 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..7040f0d2c1d564884b20d1aff4f998c352df6e7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4ec6bd6a69e0b83faae6acdbf6c0d22d33fa77f18fc9aa4dded05cee01d011c +size 958 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..b1489b2408568ef856f9b7691a6de90395656d55 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6760aab482af996cbd94742720668a0a900919957db2413eeb1f18f047330ae3 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..360331f72e267548c985238e8dddb33ecf33efa7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2df86c0b6c8fc0e216a53438e3f26bd9e46670c1f5b3dc77426259c971d210f3 +size 1319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..15b6cea0fb960e83bce61a19c94bef54ea0aaecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2f8ca0f43e784616f459b84a576d98839d9abe41af934709640dc8e81efb4e98 +size 6621 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..6e1b013baf19c0e01499e397492cadb90ffd0cf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04f31ef7049dee20af09577fe45fb41d805af0907e8e137ee3516d0e90d2554f +size 301 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..1a8fd05bfd33b99eb361fba9b6bc1c00e7fa7d35 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f42ff2e01094cd2102a388e7fd6124eb7b7cbf899b465cacf0860127e4c99e78 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..6c0fa171f2c97dde10256df4376995c3177a281e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_cb_best/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c87fcede2165d9a1cc54de5f114c0cfdaa21c0dc8a1dbe6ed1232e8e930df025 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..533af56ce20919d8164fa0093972d0f1209ac88e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:636b5d5b2495c4c123f00fead30911369c615118fbffa66f12610fcfc4c730ba +size 936 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..88505d5882f86ee3507f9e953138a818dc57caa6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:722b3ac7a315c79a1bc37fe46cec8ac815bef9599406c0734cb78c095698f0f8 +size 1318 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..a718382837cf353aa21a2455e5519c638b6aeac8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8e04b6d0b94b457eacd407d0338fa99146f6749339d4b64b48001287daa5b7b5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json new file mode 100644 index 0000000000000000000000000000000000000000..a036f5707506ec7bfea76a21e2ee20a931c05065 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/importance.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9cc24aa23a4db246ab5dfe17125252a50009917323d54e5677507aba6b7f0a38 +size 298 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/ddpm_mlp_best/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..66c9afda1050096fedb7688d56a9a03ea9926b47 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e161c1def56ea993fc1e643c986456388df3cabfae0c4213cb15565a17e0dcd2 +size 400 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..da1d999c49a6040603a6b508b4baa2b9a6719090 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4712ec1d5d364761ad171d82d98b083e0e8b567649793dfa488478beef453c08 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json new file mode 100644 index 0000000000000000000000000000000000000000..956bfdeffb7135603d0fabdaa6c8879918cb2384 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_mlp.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9063998cac822118a02b7b2d2a568d909c04fc994db129345a81a481a4fd0956 +size 1315 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..36dc119e8917134f5fe5bed0b6ea84ccba3c2ad8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61fe10a9440af4534e2826cbc566e5192f7ae8947c598d2e84fe619b37a359ac +size 3319 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacies.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacies.json new file mode 100644 index 0000000000000000000000000000000000000000..188742f3a544abe1953ff5dbd12f1238d1b9ce41 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacies.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a5b6a5e9214b8d7e50524a5e9177419661add5dc4d3b06ecffe68c7cb4c5f392 +size 223 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacy.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacy.json new file mode 100644 index 0000000000000000000000000000000000000000..f3e143c3c192cbda659bcd16a90b1d26c7f3d2e6 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/smote/privacy.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aa03c0df6c8ca6742c1489e8e37ac08f68c342c863bddf7ca3143426920c576 +size 40 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..cc8427f26ad1f9ca2dcb4cc6943fab932096ffc8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:50edc7be21196e9e790fe8990bc332150d0550db1b2c46e60d19810e875a3ece +size 605 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json new file mode 100644 index 0000000000000000000000000000000000000000..021c8067d431ea8362123e590cc238472e801ae5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_catboost.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36cf4c644fe1879a25693cfb68d88db11c3afb7a9c075e3f4d2d1ea201ca67c5 +size 664 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json new file mode 100644 index 0000000000000000000000000000000000000000..bd44eefcc1486f6bd4d79b60858ec5796da81e78 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/eval_simple.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b55d374b6630709cb9d4c5814d856dd2520386b992937a3b24d80d71eb2e035c +size 3307 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/info.json new file mode 100644 index 0000000000000000000000000000000000000000..5a28531bbb83ea1a737c9159d19f13501a54adc0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/exp/wilt/tvae/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511a0dc9860b7587f2382407ae286e4160a320f28a3b2bff6bd85ce88a6550e4 +size 191 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..54d6f6bbd104c00418af09162967e1fde1dea4fc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/__init__.py @@ -0,0 +1,12 @@ +import torch +from icecream import install + +torch.set_num_threads(1) +install() + +from . import env # noqa +from .data import * # noqa +from .deep import * # noqa +from .env import * # noqa +from .metrics import * # noqa +from .util import * # noqa diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/data.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/data.py new file mode 100644 index 0000000000000000000000000000000000000000..de47f283d607c411a23df48a364f19f43d2727d1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/data.py @@ -0,0 +1,719 @@ +import hashlib +from collections import Counter +from copy import deepcopy +from dataclasses import astuple, dataclass, replace +from importlib.resources import path +from pathlib import Path +from typing import Any, Literal, Optional, Union, cast, Tuple, Dict, List + +import numpy as np +import pandas as pd +from sklearn.model_selection import train_test_split +from sklearn.pipeline import make_pipeline +import sklearn.preprocessing +import torch +import os +from category_encoders import LeaveOneOutEncoder +from sklearn.impute import SimpleImputer +from sklearn.preprocessing import StandardScaler +from scipy.spatial.distance import cdist + +from . import env, util +from .metrics import calculate_metrics as calculate_metrics_ +from .util import TaskType, load_json + +ArrayDict = Dict[str, np.ndarray] +TensorDict = Dict[str, torch.Tensor] + + +CAT_MISSING_VALUE = '__nan__' +CAT_RARE_VALUE = '__rare__' +Normalization = Literal['standard', 'quantile', 'minmax'] +NumNanPolicy = Literal['drop-rows', 'mean'] +CatNanPolicy = Literal['most_frequent'] +CatEncoding = Literal['one-hot', 'counter'] +YPolicy = Literal['default'] + + +class StandardScaler1d(StandardScaler): + def partial_fit(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().partial_fit(X[:, None], *args, **kwargs) + + def transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().transform(X[:, None], *args, **kwargs).squeeze(1) + + def inverse_transform(self, X, *args, **kwargs): + assert X.ndim == 1 + return super().inverse_transform(X[:, None], *args, **kwargs).squeeze(1) + + +def get_category_sizes(X: Union[torch.Tensor, np.ndarray]) -> List[int]: + """Return K[i] s.t. F.one_hot(x[:,i], K[i]) is valid. Requires K[i] > max(x[:,i]).""" + XT = X.T.cpu().tolist() if isinstance(X, torch.Tensor) else X.T.tolist() + return [int(np.max(x)) + 1 if len(x) > 0 else 0 for x in XT] + + +@dataclass(frozen=False) +class Dataset: + X_num: Optional[ArrayDict] + X_cat: Optional[ArrayDict] + y: ArrayDict + y_info: Dict[str, Any] + task_type: TaskType + n_classes: Optional[int] + + @classmethod + def from_dir(cls, dir_: Union[Path, str]) -> 'Dataset': + dir_ = Path(dir_) + splits = [k for k in ['train', 'val', 'test'] if dir_.joinpath(f'y_{k}.npy').exists()] + + def load(item) -> ArrayDict: + return { + x: cast(np.ndarray, np.load(dir_ / f'{item}_{x}.npy', allow_pickle=True)) # type: ignore[code] + for x in splits + } + + if Path(dir_ / 'info.json').exists(): + info = util.load_json(dir_ / 'info.json') + else: + info = None + return Dataset( + load('X_num') if dir_.joinpath('X_num_train.npy').exists() else None, + load('X_cat') if dir_.joinpath('X_cat_train.npy').exists() else None, + load('y'), + {}, + TaskType(info['task_type']), + info.get('n_classes'), + ) + + @property + def is_binclass(self) -> bool: + return self.task_type == TaskType.BINCLASS + + @property + def is_multiclass(self) -> bool: + return self.task_type == TaskType.MULTICLASS + + @property + def is_regression(self) -> bool: + return self.task_type == TaskType.REGRESSION + + @property + def n_num_features(self) -> int: + return 0 if self.X_num is None else self.X_num['train'].shape[1] + + @property + def n_cat_features(self) -> int: + return 0 if self.X_cat is None else self.X_cat['train'].shape[1] + + @property + def n_features(self) -> int: + return self.n_num_features + self.n_cat_features + + def size(self, part: Optional[str]) -> int: + return sum(map(len, self.y.values())) if part is None else len(self.y[part]) + + @property + def nn_output_dim(self) -> int: + if self.is_multiclass: + assert self.n_classes is not None + return self.n_classes + else: + return 1 + + def get_category_sizes(self, part: str) -> List[int]: + return [] if self.X_cat is None else get_category_sizes(self.X_cat[part]) + + def calculate_metrics( + self, + predictions: Dict[str, np.ndarray], + prediction_type: Optional[str], + ) -> Dict[str, Any]: + metrics = { + x: calculate_metrics_( + self.y[x], predictions[x], self.task_type, prediction_type, self.y_info + ) + for x in predictions + } + if self.task_type == TaskType.REGRESSION: + score_key = 'rmse' + score_sign = -1 + else: + score_key = 'accuracy' + score_sign = 1 + for part_metrics in metrics.values(): + part_metrics['score'] = score_sign * part_metrics[score_key] + return metrics + +def change_val(dataset: Dataset, val_size: float = 0.2): + # should be done before transformations + + y = np.concatenate([dataset.y['train'], dataset.y['val']], axis=0) + + ixs = np.arange(y.shape[0]) + if dataset.is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + + dataset.y['train'] = y[train_ixs] + dataset.y['val'] = y[val_ixs] + + if dataset.X_num is not None: + X_num = np.concatenate([dataset.X_num['train'], dataset.X_num['val']], axis=0) + dataset.X_num['train'] = X_num[train_ixs] + dataset.X_num['val'] = X_num[val_ixs] + + if dataset.X_cat is not None: + X_cat = np.concatenate([dataset.X_cat['train'], dataset.X_cat['val']], axis=0) + dataset.X_cat['train'] = X_cat[train_ixs] + dataset.X_cat['val'] = X_cat[val_ixs] + + return dataset + +def num_process_nans(dataset: Dataset, policy: Optional[NumNanPolicy]) -> Dataset: + assert dataset.X_num is not None + nan_masks = {k: np.isnan(v) for k, v in dataset.X_num.items()} + if not any(x.any() for x in nan_masks.values()): # type: ignore[code] + assert policy is None + return dataset + + assert policy is not None + if policy == 'drop-rows': + valid_masks = {k: ~v.any(1) for k, v in nan_masks.items()} + assert valid_masks[ + 'test' + ].all(), 'Cannot drop test rows, since this will affect the final metrics.' + new_data = {} + for data_name in ['X_num', 'X_cat', 'y']: + data_dict = getattr(dataset, data_name) + if data_dict is not None: + new_data[data_name] = { + k: v[valid_masks[k]] for k, v in data_dict.items() + } + dataset = replace(dataset, **new_data) + elif policy == 'mean': + new_values = np.nanmean(dataset.X_num['train'], axis=0) + X_num = deepcopy(dataset.X_num) + for k, v in X_num.items(): + num_nan_indices = np.where(nan_masks[k]) + v[num_nan_indices] = np.take(new_values, num_nan_indices[1]) + dataset = replace(dataset, X_num=X_num) + else: + assert util.raise_unknown('policy', policy) + return dataset + + +# Inspired by: https://github.com/yandex-research/rtdl/blob/a4c93a32b334ef55d2a0559a4407c8306ffeeaee/lib/data.py#L20 +def normalize( + X: ArrayDict, normalization: Normalization, seed: Optional[int], return_normalizer : bool = False +) -> ArrayDict: + X_train = X['train'] + if normalization == 'standard': + normalizer = sklearn.preprocessing.StandardScaler() + elif normalization == 'minmax': + normalizer = sklearn.preprocessing.MinMaxScaler() + elif normalization == 'quantile': + normalizer = sklearn.preprocessing.QuantileTransformer( + output_distribution='normal', + n_quantiles=max(min(X['train'].shape[0] // 30, 1000), 10), + subsample=int(1e9), + random_state=seed, + ) + # noise = 1e-3 + # if noise > 0: + # assert seed is not None + # stds = np.std(X_train, axis=0, keepdims=True) + # noise_std = noise / np.maximum(stds, noise) # type: ignore[code] + # X_train = X_train + noise_std * np.random.default_rng(seed).standard_normal( + # X_train.shape + # ) + else: + util.raise_unknown('normalization', normalization) + normalizer.fit(X_train) + if return_normalizer: + return {k: normalizer.transform(v) for k, v in X.items()}, normalizer + return {k: normalizer.transform(v) for k, v in X.items()} + + +def cat_process_nans(X: ArrayDict, policy: Optional[CatNanPolicy]) -> ArrayDict: + assert X is not None + nan_masks = {k: np.asarray(v == CAT_MISSING_VALUE) for k, v in X.items()} + if any(np.asarray(x).any() for x in nan_masks.values()): # type: ignore[code] + if policy is None: + X_new = X + elif policy == 'most_frequent': + imputer = SimpleImputer(missing_values=CAT_MISSING_VALUE, strategy=policy) # type: ignore[code] + imputer.fit(X['train']) + X_new = {k: cast(np.ndarray, imputer.transform(v)) for k, v in X.items()} + else: + util.raise_unknown('categorical NaN policy', policy) + else: + assert policy is None + X_new = X + return X_new + + +def cat_drop_rare(X: ArrayDict, min_frequency: float) -> ArrayDict: + assert 0.0 < min_frequency < 1.0 + min_count = round(len(X['train']) * min_frequency) + X_new = {x: [] for x in X} + for column_idx in range(X['train'].shape[1]): + counter = Counter(X['train'][:, column_idx].tolist()) + popular_categories = {k for k, v in counter.items() if v >= min_count} + for part in X_new: + X_new[part].append( + [ + (x if x in popular_categories else CAT_RARE_VALUE) + for x in X[part][:, column_idx].tolist() + ] + ) + return {k: np.array(v).T for k, v in X_new.items()} + + +def cat_encode( + X: ArrayDict, + encoding: Optional[CatEncoding], + y_train: Optional[np.ndarray], + seed: Optional[int], + return_encoder : bool = False +) -> Tuple[ArrayDict, bool, Optional[Any]]: # (X, is_converted_to_numerical) + if encoding != 'counter': + y_train = None + + # Step 1. Map strings to 0-based ranges + + if encoding is None: + unknown_value = np.iinfo('int64').max - 3 + oe = sklearn.preprocessing.OrdinalEncoder( + handle_unknown='use_encoded_value', # type: ignore[code] + unknown_value=unknown_value, # type: ignore[code] + dtype='int64', # type: ignore[code] + ).fit(X['train']) + encoder = make_pipeline(oe) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + max_values = X['train'].max(axis=0) + for part in X.keys(): + if part == 'train': continue + for column_idx in range(X[part].shape[1]): + X[part][X[part][:, column_idx] == unknown_value, column_idx] = ( + max_values[column_idx] + 1 + ) + if return_encoder: + return (X, False, encoder) + return (X, False) + + # Step 2. Encode. + + elif encoding == 'one-hot': + ohe = sklearn.preprocessing.OneHotEncoder( + handle_unknown='ignore', sparse=False, dtype=np.float32 # type: ignore[code] + ) + encoder = make_pipeline(ohe) + + # encoder.steps.append(('ohe', ohe)) + encoder.fit(X['train']) + X = {k: encoder.transform(v) for k, v in X.items()} + elif encoding == 'counter': + assert y_train is not None + assert seed is not None + loe = LeaveOneOutEncoder(sigma=0.1, random_state=seed, return_df=False) + encoder.steps.append(('loe', loe)) + encoder.fit(X['train'], y_train) + X = {k: encoder.transform(v).astype('float32') for k, v in X.items()} # type: ignore[code] + if not isinstance(X['train'], pd.DataFrame): + X = {k: v.values for k, v in X.items()} # type: ignore[code] + else: + util.raise_unknown('encoding', encoding) + + if return_encoder: + return X, True, encoder # type: ignore[code] + return (X, True) + + +def build_target( + y: ArrayDict, policy: Optional[YPolicy], task_type: TaskType +) -> Tuple[ArrayDict, Dict[str, Any]]: + info: Dict[str, Any] = {'policy': policy} + if policy is None: + pass + elif policy == 'default': + if task_type == TaskType.REGRESSION: + mean, std = float(y['train'].mean()), float(y['train'].std()) + y = {k: (v - mean) / std for k, v in y.items()} + info['mean'] = mean + info['std'] = std + else: + util.raise_unknown('policy', policy) + return y, info + + +@dataclass(frozen=True) +class Transformations: + seed: int = 0 + normalization: Optional[Normalization] = None + num_nan_policy: Optional[NumNanPolicy] = None + cat_nan_policy: Optional[CatNanPolicy] = None + cat_min_frequency: Optional[float] = None + cat_encoding: Optional[CatEncoding] = None + y_policy: Optional[YPolicy] = 'default' + + +def transform_dataset( + dataset: Dataset, + transformations: Transformations, + cache_dir: Optional[Path], + return_transforms: bool = False +) -> Dataset: + # WARNING: the order of transformations matters. Moreover, the current + # implementation is not ideal in that sense. + if cache_dir is not None: + transformations_md5 = hashlib.md5( + str(transformations).encode('utf-8') + ).hexdigest() + transformations_str = '__'.join(map(str, astuple(transformations))) + cache_path = ( + cache_dir / f'cache__{transformations_str}__{transformations_md5}.pickle' + ) + if cache_path.exists(): + cache_transformations, value = util.load_pickle(cache_path) + if transformations == cache_transformations: + print( + f"Using cached features: {cache_dir.name + '/' + cache_path.name}" + ) + return value + else: + raise RuntimeError(f'Hash collision for {cache_path}') + else: + cache_path = None + + if dataset.X_num is not None: + dataset = num_process_nans(dataset, transformations.num_nan_policy) + + num_transform = None + cat_transform = None + X_num = dataset.X_num + + if X_num is not None and transformations.normalization is not None: + X_num, num_transform = normalize( + X_num, + transformations.normalization, + transformations.seed, + return_normalizer=True + ) + num_transform = num_transform + + if dataset.X_cat is None: + assert transformations.cat_nan_policy is None + assert transformations.cat_min_frequency is None + # assert transformations.cat_encoding is None + X_cat = None + else: + X_cat = cat_process_nans(dataset.X_cat, transformations.cat_nan_policy) + if transformations.cat_min_frequency is not None: + X_cat = cat_drop_rare(X_cat, transformations.cat_min_frequency) + X_cat, is_num, cat_transform = cat_encode( + X_cat, + transformations.cat_encoding, + dataset.y['train'], + transformations.seed, + return_encoder=True + ) + if is_num: + X_num = ( + X_cat + if X_num is None + else {x: np.hstack([X_num[x], X_cat[x]]) for x in X_num} + ) + X_cat = None + + y, y_info = build_target(dataset.y, transformations.y_policy, dataset.task_type) + + dataset = replace(dataset, X_num=X_num, X_cat=X_cat, y=y, y_info=y_info) + dataset.num_transform = num_transform + dataset.cat_transform = cat_transform + + if cache_path is not None: + util.dump_pickle((transformations, dataset), cache_path) + # if return_transforms: + # return dataset, num_transform, cat_transform + return dataset + + +def build_dataset( + path: Union[str, Path], + transformations: Transformations, + cache: bool +) -> Dataset: + path = Path(path) + dataset = Dataset.from_dir(path) + return transform_dataset(dataset, transformations, path if cache else None) + + +def prepare_tensors( + dataset: Dataset, device: Union[str, torch.device] +) -> Tuple[Optional[TensorDict], Optional[TensorDict], TensorDict]: + X_num, X_cat, Y = ( + None if x is None else {k: torch.as_tensor(v) for k, v in x.items()} + for x in [dataset.X_num, dataset.X_cat, dataset.y] + ) + if device.type != 'cpu': + X_num, X_cat, Y = ( + None if x is None else {k: v.to(device) for k, v in x.items()} + for x in [X_num, X_cat, Y] + ) + assert X_num is not None + assert Y is not None + if not dataset.is_multiclass: + Y = {k: v.float() for k, v in Y.items()} + return X_num, X_cat, Y + +############### +## DataLoader## +############### + +class TabDataset(torch.utils.data.Dataset): + def __init__( + self, dataset : Dataset, split : Literal['train', 'val', 'test'] + ): + super().__init__() + + self.X_num = torch.from_numpy(dataset.X_num[split]) if dataset.X_num is not None else None + self.X_cat = torch.from_numpy(dataset.X_cat[split]) if dataset.X_cat is not None else None + self.y = torch.from_numpy(dataset.y[split]) + + assert self.y is not None + assert self.X_num is not None or self.X_cat is not None + + def __len__(self): + return len(self.y) + + def __getitem__(self, idx): + out_dict = { + 'y': self.y[idx].long() if self.y is not None else None, + } + + x = np.empty((0,)) + if self.X_num is not None: + x = self.X_num[idx] + if self.X_cat is not None: + x = torch.cat([x, self.X_cat[idx]], dim=0) + return x.float(), out_dict + +def prepare_dataloader( + dataset : Dataset, + split : str, + batch_size: int, +): + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader( + torch_dataset, + batch_size=batch_size, + shuffle=(split == 'train'), + num_workers=1, + ) + while True: + yield from loader + +def prepare_torch_dataloader( + dataset : Dataset, + split : str, + shuffle : bool, + batch_size: int, +) -> torch.utils.data.DataLoader: + + torch_dataset = TabDataset(dataset, split) + loader = torch.utils.data.DataLoader(torch_dataset, batch_size=batch_size, shuffle=shuffle, num_workers=1) + + return loader + +def dataset_from_csv(paths : Dict[str, str], cat_features, target, T): + assert 'train' in paths + y = {} + X_num = {} + X_cat = {} if len(cat_features) else None + for split in paths.keys(): + df = pd.read_csv(paths[split]) + y[split] = df[target].to_numpy().astype(float) + if X_cat is not None: + X_cat[split] = df[cat_features].to_numpy().astype(str) + X_num[split] = df.drop(cat_features + [target], axis=1).to_numpy().astype(float) + + dataset = Dataset(X_num, X_cat, y, {}, None, len(np.unique(y['train']))) + return transform_dataset(dataset, T, None) + +class FastTensorDataLoader: + """ + A DataLoader-like object for a set of tensors that can be much faster than + TensorDataset + DataLoader because dataloader grabs individual indices of + the dataset and calls cat (slow). + Source: https://discuss.pytorch.org/t/dataloader-much-slower-than-manual-batching/27014/6 + """ + def __init__(self, *tensors, batch_size=32, shuffle=False): + """ + Initialize a FastTensorDataLoader. + :param *tensors: tensors to store. Must have the same length @ dim 0. + :param batch_size: batch size to load. + :param shuffle: if True, shuffle the data *in-place* whenever an + iterator is created out of this object. + :returns: A FastTensorDataLoader. + """ + assert all(t.shape[0] == tensors[0].shape[0] for t in tensors) + self.tensors = tensors + + self.dataset_len = self.tensors[0].shape[0] + self.batch_size = batch_size + self.shuffle = shuffle + + # Calculate # batches + n_batches, remainder = divmod(self.dataset_len, self.batch_size) + if remainder > 0: + n_batches += 1 + self.n_batches = n_batches + def __iter__(self): + if self.shuffle: + r = torch.randperm(self.dataset_len) + self.tensors = [t[r] for t in self.tensors] + self.i = 0 + return self + + def __next__(self): + if self.i >= self.dataset_len: + raise StopIteration + batch = tuple(t[self.i:self.i+self.batch_size] for t in self.tensors) + self.i += self.batch_size + return batch + + def __len__(self): + return self.n_batches + +def prepare_fast_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + if D.X_num is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_cat[split]).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + while True: + yield from dataloader + +def prepare_fast_torch_dataloader( + D : Dataset, + split : str, + batch_size: int +): + if D.X_cat is not None: + X = torch.from_numpy(np.concatenate([D.X_num[split], D.X_cat[split]], axis=1)).float() + else: + X = torch.from_numpy(D.X_num[split]).float() + y = torch.from_numpy(D.y[split]) + dataloader = FastTensorDataLoader(X, y, batch_size=batch_size, shuffle=(split=='train')) + return dataloader + +def round_columns(X_real, X_synth, columns): + for col in columns: + uniq = np.unique(X_real[:,col]) + dist = cdist(X_synth[:, col][:, np.newaxis].astype(float), uniq[:, np.newaxis].astype(float)) + X_synth[:, col] = uniq[dist.argmin(axis=1)] + return X_synth + +def concat_features(D : Dataset): + if D.X_num is None: + assert D.X_cat is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_cat.items()} + elif D.X_cat is None: + assert D.X_num is not None + X = {k: pd.DataFrame(v, columns=range(D.n_features)) for k, v in D.X_num.items()} + else: + X = { + part: pd.concat( + [ + pd.DataFrame(D.X_num[part], columns=range(D.n_num_features)), + pd.DataFrame( + D.X_cat[part], + columns=range(D.n_num_features, D.n_features), + ), + ], + axis=1, + ) + for part in D.y.keys() + } + + return X + +def concat_to_pd(X_num, X_cat, y): + if X_num is None: + return pd.concat([ + pd.DataFrame(X_cat, columns=list(range(X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + if X_cat is not None: + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(X_cat, columns=list(range(X_num.shape[1], X_num.shape[1] + X_cat.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + return pd.concat([ + pd.DataFrame(X_num, columns=list(range(X_num.shape[1]))), + pd.DataFrame(y, columns=['y']) + ], axis=1) + +def read_pure_data(path, split='train'): + y = np.load(os.path.join(path, f'y_{split}.npy'), allow_pickle=True) + X_num = None + X_cat = None + if os.path.exists(os.path.join(path, f'X_num_{split}.npy')): + X_num = np.load(os.path.join(path, f'X_num_{split}.npy'), allow_pickle=True) + if os.path.exists(os.path.join(path, f'X_cat_{split}.npy')): + X_cat = np.load(os.path.join(path, f'X_cat_{split}.npy'), allow_pickle=True) + + return X_num, X_cat, y + +def read_changed_val(path, val_size=0.2): + path = Path(path) + X_num_train, X_cat_train, y_train = read_pure_data(path, 'train') + X_num_val, X_cat_val, y_val = read_pure_data(path, 'val') + is_regression = load_json(path / 'info.json')['task_type'] == 'regression' + + y = np.concatenate([y_train, y_val], axis=0) + + ixs = np.arange(y.shape[0]) + if is_regression: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777) + else: + train_ixs, val_ixs = train_test_split(ixs, test_size=val_size, random_state=777, stratify=y) + y_train = y[train_ixs] + y_val = y[val_ixs] + + if X_num_train is not None: + X_num = np.concatenate([X_num_train, X_num_val], axis=0) + X_num_train = X_num[train_ixs] + X_num_val = X_num[val_ixs] + + if X_cat_train is not None: + X_cat = np.concatenate([X_cat_train, X_cat_val], axis=0) + X_cat_train = X_cat[train_ixs] + X_cat_val = X_cat[val_ixs] + + return X_num_train, X_cat_train, y_train, X_num_val, X_cat_val, y_val + +############# + +def load_dataset_info(dataset_dir_name: str) -> Dict[str, Any]: + path = Path("data/" + dataset_dir_name) + info = util.load_json(path / 'info.json') + info['size'] = info['train_size'] + info['val_size'] + info['test_size'] + info['n_features'] = info['n_num_features'] + info['n_cat_features'] + info['path'] = path + return info diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/deep.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/deep.py new file mode 100644 index 0000000000000000000000000000000000000000..aeed3e2ada4f9d0ee1a6f86b7e5d1a35d486149f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/deep.py @@ -0,0 +1,168 @@ +import statistics +from dataclasses import dataclass +from typing import Any, Callable, Literal, cast + +import rtdl +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim as optim +import zero +from torch import Tensor + +from .util import TaskType + + +def cos_sin(x: Tensor) -> Tensor: + return torch.cat([torch.cos(x), torch.sin(x)], -1) + + +@dataclass +class PeriodicOptions: + n: int # the output size is 2 * n + sigma: float + trainable: bool + initialization: Literal['log-linear', 'normal'] + + +class Periodic(nn.Module): + def __init__(self, n_features: int, options: PeriodicOptions) -> None: + super().__init__() + if options.initialization == 'log-linear': + coefficients = options.sigma ** (torch.arange(options.n) / options.n) + coefficients = coefficients[None].repeat(n_features, 1) + else: + assert options.initialization == 'normal' + coefficients = torch.normal(0.0, options.sigma, (n_features, options.n)) + if options.trainable: + self.coefficients = nn.Parameter(coefficients) # type: ignore[code] + else: + self.register_buffer('coefficients', coefficients) + + def forward(self, x: Tensor) -> Tensor: + assert x.ndim == 2 + return cos_sin(2 * torch.pi * self.coefficients[None] * x[..., None]) + + +def get_n_parameters(m: nn.Module): + return sum(x.numel() for x in m.parameters() if x.requires_grad) + + +def get_loss_fn(task_type: TaskType) -> Callable[..., Tensor]: + return ( + F.binary_cross_entropy_with_logits + if task_type == TaskType.BINCLASS + else F.cross_entropy + if task_type == TaskType.MULTICLASS + else F.mse_loss + ) + + +def default_zero_weight_decay_condition(module_name, module, parameter_name, parameter): + del module_name, parameter + return parameter_name.endswith('bias') or isinstance( + module, + ( + nn.BatchNorm1d, + nn.LayerNorm, + nn.InstanceNorm1d, + rtdl.CLSToken, + rtdl.NumericalFeatureTokenizer, + rtdl.CategoricalFeatureTokenizer, + Periodic, + ), + ) + + +def split_parameters_by_weight_decay( + model: nn.Module, zero_weight_decay_condition=default_zero_weight_decay_condition +) -> list[dict[str, Any]]: + parameters_info = {} + for module_name, module in model.named_modules(): + for parameter_name, parameter in module.named_parameters(): + full_parameter_name = ( + f'{module_name}.{parameter_name}' if module_name else parameter_name + ) + parameters_info.setdefault(full_parameter_name, ([], parameter))[0].append( + zero_weight_decay_condition( + module_name, module, parameter_name, parameter + ) + ) + params_with_wd = {'params': []} + params_without_wd = {'params': [], 'weight_decay': 0.0} + for full_parameter_name, (results, parameter) in parameters_info.items(): + (params_without_wd if any(results) else params_with_wd)['params'].append( + parameter + ) + return [params_with_wd, params_without_wd] + + +def make_optimizer( + config: dict[str, Any], + parameter_groups, +) -> optim.Optimizer: + if config['optimizer'] == 'FT-Transformer-default': + return optim.AdamW(parameter_groups, lr=1e-4, weight_decay=1e-5) + return getattr(optim, config['optimizer'])( + parameter_groups, + **{x: config[x] for x in ['lr', 'weight_decay', 'momentum'] if x in config}, + ) + + +def get_lr(optimizer: optim.Optimizer) -> float: + return next(iter(optimizer.param_groups))['lr'] + + +def is_oom_exception(err: RuntimeError) -> bool: + return any( + x in str(err) + for x in [ + 'CUDA out of memory', + 'CUBLAS_STATUS_ALLOC_FAILED', + 'CUDA error: out of memory', + ] + ) + + +def train_with_auto_virtual_batch( + optimizer, + loss_fn, + step, + batch, + chunk_size: int, +) -> tuple[Tensor, int]: + batch_size = len(batch) + random_state = zero.random.get_state() + loss = None + while chunk_size != 0: + try: + zero.random.set_state(random_state) + optimizer.zero_grad() + if batch_size <= chunk_size: + loss = loss_fn(*step(batch)) + loss.backward() + else: + loss = None + for chunk in zero.iter_batches(batch, chunk_size): + chunk_loss = loss_fn(*step(chunk)) + chunk_loss = chunk_loss * (len(chunk) / batch_size) + chunk_loss.backward() + if loss is None: + loss = chunk_loss.detach() + else: + loss += chunk_loss.detach() + except RuntimeError as err: + if not is_oom_exception(err): + raise + chunk_size //= 2 + else: + break + if not chunk_size: + raise RuntimeError('Not enough memory even for batch_size=1') + optimizer.step() + return cast(Tensor, loss), chunk_size + + +def process_epoch_losses(losses: list[Tensor]) -> tuple[list[float], float]: + losses_ = torch.stack(losses).tolist() + return losses_, statistics.mean(losses_) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/env.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/env.py new file mode 100644 index 0000000000000000000000000000000000000000..64be89d7d72c70e2ed9c7e0ecbbe682c14da3517 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/env.py @@ -0,0 +1,39 @@ +""" +Have not used in TabDDPM project. +""" + +import datetime +import os +import shutil +import typing as ty +from pathlib import Path + +PROJ = Path('tab-ddpm/').absolute().resolve() +EXP = PROJ / 'exp' +DATA = PROJ / 'data' + + +def get_path(path: ty.Union[str, Path]) -> Path: + if isinstance(path, str): + path = Path(path) + if not path.is_absolute(): + path = PROJ / path + return path.resolve() + + +def get_relative_path(path: ty.Union[str, Path]) -> Path: + return get_path(path).relative_to(PROJ) + + +def duplicate_path( + src: ty.Union[str, Path], alternative_project_dir: ty.Union[str, Path] +) -> None: + src = get_path(src) + alternative_project_dir = get_path(alternative_project_dir) + dst = alternative_project_dir / src.relative_to(PROJ) + dst.parent.mkdir(parents=True, exist_ok=True) + if dst.exists(): + dst = dst.with_name( + dst.name + '_' + datetime.datetime.now().strftime('%Y%m%dT%H%M%S') + ) + (shutil.copytree if src.is_dir() else shutil.copyfile)(src, dst) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/metrics.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/metrics.py new file mode 100644 index 0000000000000000000000000000000000000000..bdcac8171208065da730e974024aae0dc32b4665 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/metrics.py @@ -0,0 +1,158 @@ +import enum +from typing import Any, Optional, Tuple, Dict, Union, cast +from functools import partial + +import numpy as np +import scipy.special +import sklearn.metrics as skm + +from . import util +from .util import TaskType + + +class PredictionType(enum.Enum): + LOGITS = 'logits' + PROBS = 'probs' + +class MetricsReport: + def __init__(self, report: dict, task_type: TaskType): + self._res = {k: {} for k in report.keys()} + if task_type in (TaskType.BINCLASS, TaskType.MULTICLASS): + self._metrics_names = ["acc", "f1"] + for k in report.keys(): + self._res[k]["acc"] = report[k]["accuracy"] + self._res[k]["f1"] = report[k]["macro avg"]["f1-score"] + if task_type == TaskType.BINCLASS: + self._res[k]["roc_auc"] = report[k]["roc_auc"] + self._metrics_names.append("roc_auc") + + elif task_type == TaskType.REGRESSION: + self._metrics_names = ["r2", "rmse"] + for k in report.keys(): + self._res[k]["r2"] = report[k]["r2"] + self._res[k]["rmse"] = report[k]["rmse"] + else: + raise "Unknown TaskType!" + + def get_splits_names(self) -> list[str]: + return self._res.keys() + + def get_metrics_names(self) -> list[str]: + return self._metrics_names + + def get_metric(self, split: str, metric: str) -> float: + return self._res[split][metric] + + def get_val_score(self) -> float: + return self._res["val"]["r2"] if "r2" in self._res["val"] else self._res["val"]["f1"] + + def get_test_score(self) -> float: + return self._res["test"]["r2"] if "r2" in self._res["test"] else self._res["test"]["f1"] + + def print_metrics(self) -> None: + res = { + "val": {k: np.around(self._res["val"][k], 4) for k in self._res["val"]}, + "test": {k: np.around(self._res["test"][k], 4) for k in self._res["test"]} + } + + print("*"*100) + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + + return res + +class SeedsMetricsReport: + def __init__(self): + self._reports = [] + + def add_report(self, report: MetricsReport) -> None: + self._reports.append(report) + + def get_mean_std(self) -> dict: + res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + res[split][metric] = [x.get_metric(split, metric) for x in self._reports] + + agg_res = {k: {} for k in ["train", "val", "test"]} + for split in self._reports[0].get_splits_names(): + for metric in self._reports[0].get_metrics_names(): + for k, f in [("count", len), ("mean", np.mean), ("std", np.std)]: + agg_res[split][f"{metric}-{k}"] = f(res[split][metric]) + self._res = res + self._agg_res = agg_res + + return agg_res + + def print_result(self) -> dict: + res = {split: {k: float(np.around(self._agg_res[split][k], 4)) for k in self._agg_res[split]} for split in ["val", "test"]} + print("="*100) + print("EVAL RESULTS:") + print("[val]") + print(res["val"]) + print("[test]") + print(res["test"]) + print("="*100) + return res + +def calculate_rmse( + y_true: np.ndarray, y_pred: np.ndarray, std: Optional[float] +) -> float: + rmse = skm.mean_squared_error(y_true, y_pred) ** 0.5 + if std is not None: + rmse *= std + return rmse + + +def _get_labels_and_probs( + y_pred: np.ndarray, task_type: TaskType, prediction_type: Optional[PredictionType] +) -> Tuple[np.ndarray, Optional[np.ndarray]]: + assert task_type in (TaskType.BINCLASS, TaskType.MULTICLASS) + + if prediction_type is None: + return y_pred, None + + if prediction_type == PredictionType.LOGITS: + probs = ( + scipy.special.expit(y_pred) + if task_type == TaskType.BINCLASS + else scipy.special.softmax(y_pred, axis=1) + ) + elif prediction_type == PredictionType.PROBS: + probs = y_pred + else: + util.raise_unknown('prediction_type', prediction_type) + + assert probs is not None + labels = np.round(probs) if task_type == TaskType.BINCLASS else probs.argmax(axis=1) + return labels.astype('int64'), probs + + +def calculate_metrics( + y_true: np.ndarray, + y_pred: np.ndarray, + task_type: Union[str, TaskType], + prediction_type: Optional[Union[str, PredictionType]], + y_info: Dict[str, Any], +) -> Dict[str, Any]: + # Example: calculate_metrics(y_true, y_pred, 'binclass', 'logits', {}) + task_type = TaskType(task_type) + if prediction_type is not None: + prediction_type = PredictionType(prediction_type) + + if task_type == TaskType.REGRESSION: + assert prediction_type is None + assert 'std' in y_info + rmse = calculate_rmse(y_true, y_pred, y_info['std']) + r2 = skm.r2_score(y_true, y_pred) + result = {'rmse': rmse, 'r2': r2} + else: + labels, probs = _get_labels_and_probs(y_pred, task_type, prediction_type) + result = cast( + Dict[str, Any], skm.classification_report(y_true, labels, output_dict=True) + ) + if task_type == TaskType.BINCLASS: + result['roc_auc'] = skm.roc_auc_score(y_true, probs) + return result diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/util.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/util.py new file mode 100644 index 0000000000000000000000000000000000000000..75e05c9c9d1f0f9d6687f6d5fe1e91cad1b4ea20 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/lib/util.py @@ -0,0 +1,433 @@ +import argparse +import atexit +import enum +import json +import os +import pickle +import shutil +import sys +import time +import uuid +from copy import deepcopy +from dataclasses import asdict, fields, is_dataclass +from pathlib import Path +from pprint import pprint +from typing import Any, Callable, List, Dict, Type, Optional, Tuple, TypeVar, Union, cast, get_args, get_origin + +import __main__ +import numpy as np +import tomli +import tomli_w +import torch +import zero + +from . import env + +RawConfig = Dict[str, Any] +Report = Dict[str, Any] +T = TypeVar('T') + + +class Part(enum.Enum): + TRAIN = 'train' + VAL = 'val' + TEST = 'test' + + def __str__(self) -> str: + return self.value + + +class TaskType(enum.Enum): + BINCLASS = 'binclass' + MULTICLASS = 'multiclass' + REGRESSION = 'regression' + + def __str__(self) -> str: + return self.value + + +class Timer(zero.Timer): + @classmethod + def launch(cls) -> 'Timer': + timer = cls() + timer.run() + return timer + + +def update_training_log(training_log, data, metrics): + def _update(log_part, data_part): + for k, v in data_part.items(): + if isinstance(v, dict): + _update(log_part.setdefault(k, {}), v) + elif isinstance(v, list): + log_part.setdefault(k, []).extend(v) + else: + log_part.setdefault(k, []).append(v) + + _update(training_log, data) + transposed_metrics = {} + for part, part_metrics in metrics.items(): + for metric_name, value in part_metrics.items(): + transposed_metrics.setdefault(metric_name, {})[part] = value + _update(training_log, transposed_metrics) + + +def raise_unknown(unknown_what: str, unknown_value: Any): + raise ValueError(f'Unknown {unknown_what}: {unknown_value}') + + +def _replace(data, condition, value): + def do(x): + if isinstance(x, dict): + return {k: do(v) for k, v in x.items()} + elif isinstance(x, list): + return [do(y) for y in x] + else: + return value if condition(x) else x + + return do(data) + + +_CONFIG_NONE = '__none__' + + +def unpack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x == _CONFIG_NONE, None)) + return config + + +def pack_config(config: RawConfig) -> RawConfig: + config = cast(RawConfig, _replace(config, lambda x: x is None, _CONFIG_NONE)) + return config + + +def load_config(path: Union[Path, str]) -> Any: + with open(path, 'rb') as f: + return unpack_config(tomli.load(f)) + + +def dump_config(config: Any, path: Union[Path, str]) -> None: + with open(path, 'wb') as f: + tomli_w.dump(pack_config(config), f) + # check that there are no bugs in all these "pack/unpack" things + assert config == load_config(path) + + +def load_json(path: Union[Path, str], **kwargs) -> Any: + return json.loads(Path(path).read_text(), **kwargs) + + +def dump_json(x: Any, path: Union[Path, str], **kwargs) -> None: + kwargs.setdefault('indent', 4) + Path(path).write_text(json.dumps(x, **kwargs) + '\n') + + +def load_pickle(path: Union[Path, str], **kwargs) -> Any: + return pickle.loads(Path(path).read_bytes(), **kwargs) + + +def dump_pickle(x: Any, path: Union[Path, str], **kwargs) -> None: + Path(path).write_bytes(pickle.dumps(x, **kwargs)) + + +def load(path: Union[Path, str], **kwargs) -> Any: + return globals()[f'load_{Path(path).suffix[1:]}'](Path(path), **kwargs) + + +def dump(x: Any, path: Union[Path, str], **kwargs) -> Any: + return globals()[f'dump_{Path(path).suffix[1:]}'](x, Path(path), **kwargs) + + +def _get_output_item_path( + path: Union[str, Path], filename: str, must_exist: bool +) -> Path: + path = env.get_path(path) + if path.suffix == '.toml': + path = path.with_suffix('') + if path.is_dir(): + path = path / filename + else: + assert path.name == filename + assert path.parent.exists() + if must_exist: + assert path.exists() + return path + + +def load_report(path: Path) -> Report: + return load_json(_get_output_item_path(path, 'report.json', True)) + + +def dump_report(report: dict, path: Path) -> None: + dump_json(report, _get_output_item_path(path, 'report.json', False)) + + +def load_predictions(path: Path) -> Dict[str, np.ndarray]: + with np.load(_get_output_item_path(path, 'predictions.npz', True)) as predictions: + return {x: predictions[x] for x in predictions} + + +def dump_predictions(predictions: Dict[str, np.ndarray], path: Path) -> None: + np.savez(_get_output_item_path(path, 'predictions.npz', False), **predictions) + + +def dump_metrics(metrics: Dict[str, Any], path: Path) -> None: + dump_json(metrics, _get_output_item_path(path, 'metrics.json', False)) + + +def load_checkpoint(path: Path, *args, **kwargs) -> Dict[str, np.ndarray]: + return torch.load( + _get_output_item_path(path, 'checkpoint.pt', True), *args, **kwargs + ) + + +def get_device() -> torch.device: + if torch.cuda.is_available(): + assert os.environ.get('CUDA_VISIBLE_DEVICES') is not None + return torch.device('cuda:0') + else: + return torch.device('cpu') + + +def _print_sep(c, size=100): + print(c * size) + + +def start( + config_cls: Type[T] = RawConfig, + argv: Optional[List[str]] = None, + patch_raw_config: Optional[Callable[[RawConfig], None]] = None, +) -> Tuple[T, Path, Report]: # config # output dir # report + parser = argparse.ArgumentParser() + parser.add_argument('config', metavar='FILE') + parser.add_argument('--force', action='store_true') + parser.add_argument('--continue', action='store_true', dest='continue_') + if argv is None: + program = __main__.__file__ + args = parser.parse_args() + else: + program = argv[0] + try: + args = parser.parse_args(argv[1:]) + except Exception: + print( + 'Failed to parse `argv`.' + ' Remember that the first item of `argv` must be the path (relative to' + ' the project root) to the script/notebook.' + ) + raise + args = parser.parse_args(argv) + + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if snapshot_dir and Path(snapshot_dir).joinpath('CHECKPOINTS_RESTORED').exists(): + assert args.continue_ + + config_path = env.get_path(args.config) + output_dir = config_path.with_suffix('') + _print_sep('=') + print(f'[output] {output_dir}') + _print_sep('=') + + assert config_path.exists() + raw_config = load_config(config_path) + if patch_raw_config is not None: + patch_raw_config(raw_config) + if is_dataclass(config_cls): + config = from_dict(config_cls, raw_config) + full_raw_config = asdict(config) + else: + assert config_cls is dict + full_raw_config = config = raw_config + full_raw_config = asdict(config) + + if output_dir.exists(): + if args.force: + print('Removing the existing output and creating a new one...') + shutil.rmtree(output_dir) + output_dir.mkdir() + elif not args.continue_: + backup_output(output_dir) + print('The output directory already exists. Done!\n') + sys.exit() + elif output_dir.joinpath('DONE').exists(): + backup_output(output_dir) + print('The "DONE" file already exists. Done!') + sys.exit() + else: + print('Continuing with the existing output...') + else: + print('Creating the output...') + output_dir.mkdir() + + report = { + 'program': str(env.get_relative_path(program)), + 'environment': {}, + 'config': full_raw_config, + } + if torch.cuda.is_available(): # type: ignore[code] + report['environment'].update( + { + 'CUDA_VISIBLE_DEVICES': os.environ.get('CUDA_VISIBLE_DEVICES'), + 'gpus': zero.hardware.get_gpus_info(), + 'torch.version.cuda': torch.version.cuda, + 'torch.backends.cudnn.version()': torch.backends.cudnn.version(), # type: ignore[code] + 'torch.cuda.nccl.version()': torch.cuda.nccl.version(), # type: ignore[code] + } + ) + dump_report(report, output_dir) + dump_json(raw_config, output_dir / 'raw_config.json') + _print_sep('-') + pprint(full_raw_config, width=100) + _print_sep('-') + return cast(config_cls, config), output_dir, report + + +_LAST_SNAPSHOT_TIME = None + + +def backup_output(output_dir: Path) -> None: + backup_dir = os.environ.get('TMP_OUTPUT_PATH') + snapshot_dir = os.environ.get('SNAPSHOT_PATH') + if backup_dir is None: + assert snapshot_dir is None + return + assert snapshot_dir is not None + + try: + relative_output_dir = output_dir.relative_to(env.PROJ) + except ValueError: + return + + for dir_ in [backup_dir, snapshot_dir]: + new_output_dir = dir_ / relative_output_dir + prev_backup_output_dir = new_output_dir.with_name(new_output_dir.name + '_prev') + new_output_dir.parent.mkdir(exist_ok=True, parents=True) + if new_output_dir.exists(): + new_output_dir.rename(prev_backup_output_dir) + shutil.copytree(output_dir, new_output_dir) + # the case for evaluate.py which automatically creates configs + if output_dir.with_suffix('.toml').exists(): + shutil.copyfile( + output_dir.with_suffix('.toml'), new_output_dir.with_suffix('.toml') + ) + if prev_backup_output_dir.exists(): + shutil.rmtree(prev_backup_output_dir) + + global _LAST_SNAPSHOT_TIME + if _LAST_SNAPSHOT_TIME is None or time.time() - _LAST_SNAPSHOT_TIME > 10 * 60: + import nirvana_dl.snapshot # type: ignore[code] + + nirvana_dl.snapshot.dump_snapshot() + _LAST_SNAPSHOT_TIME = time.time() + print('The snapshot was saved!') + + +def _get_scores(metrics: Dict[str, Dict[str, Any]]) -> Optional[Dict[str, float]]: + return ( + {k: v['score'] for k, v in metrics.items()} + if 'score' in next(iter(metrics.values())) + else None + ) + + +def format_scores(metrics: Dict[str, Dict[str, Any]]) -> str: + return ' '.join( + f"[{x}] {metrics[x]['score']:.3f}" + for x in ['test', 'val', 'train'] + if x in metrics + ) + + +def finish(output_dir: Path, report: dict) -> None: + print() + _print_sep('=') + + metrics = report.get('metrics') + if metrics is not None: + scores = _get_scores(metrics) + if scores is not None: + dump_json(scores, output_dir / 'scores.json') + print(format_scores(metrics)) + _print_sep('-') + + dump_report(report, output_dir) + json_output_path = os.environ.get('JSON_OUTPUT_FILE') + if json_output_path: + try: + key = str(output_dir.relative_to(env.PROJ)) + except ValueError: + pass + else: + json_output_path = Path(json_output_path) + try: + json_data = json.loads(json_output_path.read_text()) + except (FileNotFoundError, json.decoder.JSONDecodeError): + json_data = {} + json_data[key] = load_json(output_dir / 'report.json') + json_output_path.write_text(json.dumps(json_data, indent=4)) + shutil.copyfile( + json_output_path, + os.path.join(os.environ['SNAPSHOT_PATH'], 'json_output.json'), + ) + + output_dir.joinpath('DONE').touch() + backup_output(output_dir) + print(f'Done! | {report.get("time")} | {output_dir}') + _print_sep('=') + print() + + +def from_dict(datacls: Type[T], data: dict) -> T: + assert is_dataclass(datacls) + data = deepcopy(data) + for field in fields(datacls): + if field.name not in data: + continue + if is_dataclass(field.type): + data[field.name] = from_dict(field.type, data[field.name]) + elif ( + get_origin(field.type) is Union + and len(get_args(field.type)) == 2 + and get_args(field.type)[1] is type(None) + and is_dataclass(get_args(field.type)[0]) + ): + if data[field.name] is not None: + data[field.name] = from_dict(get_args(field.type)[0], data[field.name]) + return datacls(**data) + + +def replace_factor_with_value( + config: RawConfig, + key: str, + reference_value: int, + bounds: Tuple[float, float], +) -> None: + factor_key = key + '_factor' + if factor_key not in config: + assert key in config + else: + assert key not in config + factor = config.pop(factor_key) + assert bounds[0] <= factor <= bounds[1] + config[key] = int(factor * reference_value) + + +def get_temporary_copy(path: Union[str, Path]) -> Path: + path = env.get_path(path) + assert not path.is_dir() and not path.is_symlink() + tmp_path = path.with_name( + path.stem + '___' + str(uuid.uuid4()).replace('-', '') + path.suffix + ) + shutil.copyfile(path, tmp_path) + atexit.register(lambda: tmp_path.unlink()) + return tmp_path + + +def get_python(): + python = Path('python3.9') + return str(python) if python.exists() else 'python' + +def get_catboost_config(real_data_path, is_cv=False): + ds_name = Path(real_data_path).name + C = load_json(f'tuned_models/catboost/{ds_name}_cv.json') + return C \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/requirements.txt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/requirements.txt new file mode 100644 index 0000000000000000000000000000000000000000..0ce34ec62c2c3c306ad6b26213187ebdaedf8c60 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/requirements.txt @@ -0,0 +1,22 @@ +catboost==1.0.3 +category-encoders==2.3.0 +dython==0.5.1 +icecream==2.1.2 +libzero==0.0.8 +numpy==1.21.4 +optuna==2.10.1 +pandas==1.3.4 +pyarrow==6.0.0 +rtdl==0.0.9 +scikit-learn==1.0.2 +scipy==1.7.2 +skorch==0.11.0 +tomli-w==0.4.0 +tomli==1.2.2 +tqdm==4.62.3 + +# smote +imbalanced-learn==0.7.0 + +# tvae +rdt==0.6.4 \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_catboost.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_catboost.py new file mode 100644 index 0000000000000000000000000000000000000000..55066c2176c33c8fec14416d34736899e039a64f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_catboost.py @@ -0,0 +1,145 @@ +from catboost import CatBoostClassifier, CatBoostRegressor +from sklearn.metrics import classification_report, r2_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from pprint import pprint +from lib import concat_features, read_pure_data, get_catboost_config, read_changed_val + +def train_catboost( + parent_dir, + real_data_path, + eval_type, + T_dict, + seed = 0, + params = None, + change_val = True, + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + catboost_config = get_catboost_config(real_data_path, is_cv=True) + else: + catboost_config = params + + if 'cat_features' not in catboost_config: + catboost_config['cat_features'] = list(range(D.n_num_features, D.n_features)) + + for col in range(D.n_features): + for split in X.keys(): + if col in catboost_config['cat_features']: + X[split][col] = X[split][col].astype(str) + else: + X[split][col] = X[split][col].astype(float) + print(T_dict) + pprint(catboost_config, width=100) + print('-'*100) + + if D.is_regression: + model = CatBoostRegressor( + **catboost_config, + eval_metric='RMSE', + random_seed=seed + ) + predict = model.predict + else: + model = CatBoostClassifier( + loss_function="MultiClass" if D.is_multiclass else "Logloss", + **catboost_config, + eval_metric='TotalF1', + random_seed=seed, + class_names=[str(i) for i in range(D.n_classes)] if D.is_multiclass else ["0", "1"] + ) + predict = ( + model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit( + X['train'], D.y['train'], + eval_set=(X['val'], D.y['val']), + verbose=100 + ) + predictions = {k: predict(v) for k, v in X.items()} + print(predictions['train'].shape) + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_mlp.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_mlp.py new file mode 100644 index 0000000000000000000000000000000000000000..396de4ef30589ff3c115b3bff7daa0bddeb9a57b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_mlp.py @@ -0,0 +1,176 @@ +from sklearn.metrics import classification_report, r2_score, f1_score +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from tab_ddpm.modules import MLP +from skorch.regressor import NeuralNetRegressor +from skorch.classifier import NeuralNetClassifier +from skorch.dataset import Dataset as SkDataset +from skorch.callbacks import EarlyStopping, EpochScoring +from skorch.helper import predefined_split +from torch.optim import AdamW +from torch.nn import MSELoss, BCEWithLogitsLoss, CrossEntropyLoss + +def train_mlp( + parent_dir, + real_data_path, + eval_type, + T_dict, + params = None, + change_val = False, + seed = 0, + device = "cuda:0" +): + zero.improve_reproducibility(seed) + synthetic_data_path = os.path.join(parent_dir) if parent_dir is not None else None + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + T = lib.Transformations(**T_dict) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = lib.read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(synthetic_data_path) + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print('loading synthetic data...') + X_num, X_cat, y = lib.read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = lib.read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = lib.read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = lib.read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = lib.concat_features(D) + + X["train"], D.y["train"] = shuffle(X["train"], D.y["train"], random_state=seed) + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + + if params is None: + params = lib.load_json(f"tuned_models/mlp/{Path(real_data_path).name}_cv.json") + + mlp_params = {} + if params is not None: + mlp_params["d_layers"] = params["d_layers"] + mlp_params["dropout"] = params["dropout"] + # mlp_params["n_blocks"] = params["n_blocks"] + # mlp_params["d_main"] = params["d_main"] + # mlp_params["d_hidden"] = params["d_hidden"] + # mlp_params["dropout_first"] = params["dropout_first"] + # mlp_params["dropout_second"] = params["dropout_second"] + mlp_params["d_in"] = X["train"].shape[1] + mlp_params["d_out"] = D.nn_output_dim + + model = MLP.make_baseline(**mlp_params) + + if D.is_regression: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + elif D.is_binclass: + y = {k: D.y[k].reshape(-1, 1).astype(np.float32) for k in D.y} + else: + y = {k: D.y[k].astype(np.int64) for k in D.y} + + train_ds = SkDataset(X = X["train"].to_numpy(), y = y["train"]) + val_ds = SkDataset(X = X["val"].to_numpy(), y = y["val"]) + es = EarlyStopping(monitor="valid_loss", patience=16) + + print('-'*100) + + def f1(net, X, y): + y_pred = net.predict(X) + return f1_score(y, y_pred, average="macro") + + def r2(net, X, y): + y_pred = net.predict(X) + return r2_score(y, y_pred) + + if D.is_regression: + net = NeuralNetRegressor( + model, + criterion=MSELoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(r2, lower_is_better=False)], + ) + + else: + net = NeuralNetClassifier( + model, + criterion=BCEWithLogitsLoss if D.is_binclass else CrossEntropyLoss, + optimizer=AdamW, + lr=params["lr"], + optimizer__weight_decay=params["weight_decay"], + batch_size=128 if len(D.y["train"]) < 10_000 else 256, + max_epochs=1000, + train_split=predefined_split(val_ds), + iterator_train__shuffle=True, + device=device, + callbacks=[es, EpochScoring(f1, lower_is_better=False)], + ) + + net.fit( + X=train_ds.X, + y=train_ds.y + ) + + print("LAST:", len(net.history)) + + predictions = {k: net.predict_proba(v.to_numpy())[:, 1] if D.is_binclass else + net.predict_proba(v.to_numpy()) if D.is_multiclass else + net.predict(v.to_numpy()) + for k, v in X.items() + } + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + metrics_report.print_metrics() + + if parent_dir is not None: + lib.dump_json(report, os.path.join(parent_dir, "results_mlp.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds.py new file mode 100644 index 0000000000000000000000000000000000000000..cc4970e2a7293234d9d08afba2798719499bfc75 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds.py @@ -0,0 +1,121 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import shutil +from pathlib import Path +from copy import deepcopy +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabgan.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="catboost", + n_datasets=1, + dump=True, + change_val=False +): + + metrics_seeds_report = lib.SeedsMetricsReport() + parent_dir = Path(raw_config["parent_dir"]) + + if eval_type == 'real': + n_datasets = 1 + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real' and n_datasets > 1: + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + T_dict = deepcopy(raw_config['eval']['T']) + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + if model_type == "catboost": + T_dict["normalization"] = None + T_dict["cat_encoding"] = None + metric_report = train_catboost( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + elif model_type == "mlp": + T_dict["normalization"] = "quantile" + T_dict["cat_encoding"] = "one-hot" + metric_report = train_mlp( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report.add_report(metric_report) + + metrics_seeds_report.get_mean_std() + res = metrics_seeds_report.print_result() + if os.path.exists(parent_dir/ f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..187c88d31abc73efd4744bc1aa37bcc21d8c117f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_seeds_simple.py @@ -0,0 +1,130 @@ +import argparse +import subprocess +import tempfile +import lib +import os +import pandas as pd +import numpy as np +from pathlib import Path +from eval_simple import train_simple +from copy import deepcopy +import shutil + +pipeline = { + 'ddpm': 'scripts/pipeline.py', + 'smote': 'smote/pipeline_smote.py', + 'ctabgan': 'CTAB-GAN/pipeline_ctabgan.py', + 'ctabgan-plus': 'CTAB-GAN-Plus/pipeline_ctabganp.py', + 'tvae': 'CTGAN/pipeline_tvae.py' +} + + +def eval_seeds( + raw_config, + n_seeds, + eval_type, + sampling_method="ddpm", + model_type="simple", + n_datasets=1, + dump=True, + change_val=False +): + parent_dir = Path(raw_config["parent_dir"]) + models = ["tree", "lr", "rf", "mlp"] + metrics_seeds_report = { + k: lib.SeedsMetricsReport() for k in models + } + + if eval_type == 'real': + n_datasets = 1 + + T_dict = deepcopy(raw_config['eval']['T']) + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + + temp_config = deepcopy(raw_config) + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + temp_config["parent_dir"] = str(dir_) + if sampling_method == "ddpm": + shutil.copy2(parent_dir / "model.pt", temp_config["parent_dir"]) + elif sampling_method in ["ctabgan", "ctabgan-plus"]: + shutil.copy2(parent_dir / "ctabgan.obj", temp_config["parent_dir"]) + elif sampling_method == "tvae": + shutil.copy2(parent_dir / "tvae.obj", temp_config["parent_dir"]) + + for sample_seed in range(n_datasets): + temp_config['sample']['seed'] = sample_seed + lib.dump_config(temp_config, dir_ / "config.toml") + if eval_type != 'real': + subprocess.run(['python3.9', f'{pipeline[sampling_method]}', '--config', f'{str(dir_ / "config.toml")}', '--sample'], check=True) + + for seed in range(n_seeds): + print(f'**Eval Iter: {sample_seed*n_seeds + (seed + 1)}/{n_seeds * n_datasets}**') + for model in models: + metric_report = train_simple( + parent_dir=temp_config['parent_dir'], + real_data_path=temp_config['real_data_path'], + model_name=model, + eval_type=eval_type, + T_dict=T_dict, + seed=seed, + change_val=change_val + ) + + metrics_seeds_report[model].add_report(metric_report) + for k in models: + metrics_seeds_report[k].get_mean_std() + res = { + k: metrics_seeds_report[k].print_result() for k in models + } + + m1, m2 = ("r2-mean", "rmse-mean") if "r2-mean" in res["tree"]["val"] else ("f1-mean", "acc-mean") + res["avg"] = { + "val": { + m1: np.around(np.mean([res[k]["val"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["val"][m2] for k in models]), 4) + }, + "test": { + m1: np.around(np.mean([res[k]["test"][m1] for k in models]), 4), + m2: np.around(np.mean([res[k]["test"][m2] for k in models]), 4) + }, + } + + if os.path.exists(parent_dir / f"eval_{model_type}.json"): + eval_dict = lib.load_json(parent_dir / f"eval_{model_type}.json") + eval_dict = eval_dict | {eval_type: res} + else: + eval_dict = {eval_type: res} + + if dump: + lib.dump_json(eval_dict, parent_dir / f"eval_{model_type}.json") + + raw_config['sample']['seed'] = 0 + lib.dump_config(raw_config, parent_dir / 'config.toml') + return res + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('n_seeds', type=int, default=10) + parser.add_argument('sampling_method', type=str, default="ddpm") + parser.add_argument('eval_type', type=str, default='synthetic') + parser.add_argument('model_type', type=str, default='catboost') + parser.add_argument('n_datasets', type=int, default=1) + parser.add_argument('--no_dump', action='store_false', default=True) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + eval_seeds( + raw_config, + n_seeds=args.n_seeds, + sampling_method=args.sampling_method, + eval_type=args.eval_type, + model_type=args.model_type, + n_datasets=args.n_datasets, + dump=args.no_dump + ) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_simple.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_simple.py new file mode 100644 index 0000000000000000000000000000000000000000..5e58199394b29839052de5abde1194530150abf8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/eval_simple.py @@ -0,0 +1,141 @@ +import numpy as np +import os +from sklearn.utils import shuffle +import zero +from pathlib import Path +import lib +from lib import concat_features, read_pure_data, read_changed_val +from sklearn.utils import shuffle +import lib +from sklearn.tree import DecisionTreeClassifier, DecisionTreeRegressor +from sklearn.ensemble import RandomForestClassifier, RandomForestRegressor +from sklearn.linear_model import LogisticRegression, Ridge +from sklearn.neural_network import MLPClassifier, MLPRegressor + +def train_simple( + parent_dir, + real_data_path, + eval_type, + T_dict, + model_name = "tree", + seed = 0, + change_val = True, + params = None, # dummy + device = None # dummy +): + zero.improve_reproducibility(seed) + if eval_type != "real": + synthetic_data_path = os.path.join(parent_dir) + + T_dict["normalization"] = "minmax" + T_dict["cat_encoding"] = None + T = lib.Transformations(**T_dict) + info = lib.load_json(os.path.join(real_data_path, 'info.json')) + + if change_val: + X_num_real, X_cat_real, y_real, X_num_val, X_cat_val, y_val = read_changed_val(real_data_path, val_size=0.2) + + X = None + print('-'*100) + if eval_type == 'merged': + print('loading merged data...') + if not change_val: + X_num_real, X_cat_real, y_real = read_pure_data(real_data_path) + X_num_fake, X_cat_fake, y_fake = read_pure_data(synthetic_data_path) + + ### + # dists = privacy_metrics(real_data_path, synthetic_data_path) + # bad_fakes = dists.argsort()[:int(0.25 * len(y_fake))] + # X_num_fake = np.delete(X_num_fake, bad_fakes, axis=0) + # X_cat_fake = np.delete(X_cat_fake, bad_fakes, axis=0) if X_cat_fake is not None else None + # y_fake = np.delete(y_fake, bad_fakes, axis=0) + ### + + y = np.concatenate([y_real, y_fake], axis=0) + + X_num = None + if X_num_real is not None: + X_num = np.concatenate([X_num_real, X_num_fake], axis=0) + + X_cat = None + if X_cat_real is not None: + X_cat = np.concatenate([X_cat_real, X_cat_fake], axis=0) + + elif eval_type == 'synthetic': + print(f'loading synthetic data: {parent_dir}') + X_num, X_cat, y = read_pure_data(synthetic_data_path) + + elif eval_type == 'real': + print('loading real data...') + if not change_val: + X_num, X_cat, y = read_pure_data(real_data_path) + else: + raise "Choose eval method" + + if not change_val: + X_num_val, X_cat_val, y_val = read_pure_data(real_data_path, 'val') + X_num_test, X_cat_test, y_test = read_pure_data(real_data_path, 'test') + + D = lib.Dataset( + {'train': X_num, 'val': X_num_val, 'test': X_num_test} if X_num is not None else None, + {'train': X_cat, 'val': X_cat_val, 'test': X_cat_test} if X_cat is not None else None, + {'train': y, 'val': y_val, 'test': y_test}, + {}, + lib.TaskType(info['task_type']), + info.get('n_classes') + ) + + D = lib.transform_dataset(D, T, None) + X = concat_features(D) + # ixs = np.random.choice(len(D.y["train"]), min(info["train_size"], len(D.y["train"])), replace=False) + # X["train"] = X["train"].iloc[ixs] + # D.y["train"] = D.y["train"][ixs] + + print(f'Train size: {X["train"].shape}, Val size {X["val"].shape}') + print(T_dict) + print('-'*100) + + if D.is_regression: + models = { + "tree": DecisionTreeRegressor(max_depth=28, random_state=seed), + "rf": RandomForestRegressor(max_depth=28, random_state=seed), + "lr": Ridge(max_iter=500, random_state=seed), + "mlp": MLPRegressor(max_iter=100, random_state=seed) + } + else: + models = { + "tree": DecisionTreeClassifier(max_depth=28, random_state=seed), + "rf": RandomForestClassifier(max_depth=28, random_state=seed), + "lr": LogisticRegression(max_iter=500, n_jobs=2, random_state=seed), + "mlp": MLPClassifier(max_iter=100, random_state=seed) + } + + model = models[model_name] + + predict = ( + model.predict + if D.is_regression + else model.predict_proba + if D.is_multiclass + else lambda x: model.predict_proba(x)[:, 1] + ) + + model.fit(X['train'], D.y['train']) + + predictions = {k: predict(v) for k, v in X.items()} + + report = {} + report['eval_type'] = eval_type + report['dataset'] = real_data_path + report['metrics'] = D.calculate_metrics(predictions, None if D.is_regression else 'probs') + + metrics_report = lib.MetricsReport(report['metrics'], D.task_type) + print(model.__class__.__name__) + metrics_report.print_metrics() + + # if parent_dir is not None: + # lib.dump_json(report, os.path.join(parent_dir, "results_catboost.json")) + + return metrics_report + + \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/pipeline.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/pipeline.py new file mode 100644 index 0000000000000000000000000000000000000000..64a297813fd582cb86438f00981939571b53c162 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/pipeline.py @@ -0,0 +1,112 @@ +import tomli +import shutil +import os +import argparse +from scripts.train import train +from scripts.sample import sample +from scripts.eval_catboost import train_catboost +from scripts.eval_mlp import train_mlp +from scripts.eval_simple import train_simple +import pandas as pd +import matplotlib.pyplot as plt +import zero +import lib +import torch + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--train', action='store_true', default=False) + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + if 'device' in raw_config: + device = torch.device(raw_config['device']) + else: + device = torch.device('cuda:1') + + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + + if args.train: + train( + **raw_config['train']['main'], + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + change_val=args.change_val + ) + if args.sample: + sample( + num_samples=raw_config['sample']['num_samples'], + batch_size=raw_config['sample']['batch_size'], + disbalance=raw_config['sample'].get('disbalance', None), + **raw_config['diffusion_params'], + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + model_path=os.path.join(raw_config['parent_dir'], 'model.pt'), + model_type=raw_config['model_type'], + model_params=raw_config['model_params'], + T_dict=raw_config['train']['T'], + num_numerical_features=raw_config['num_numerical_features'], + device=device, + seed=raw_config['sample'].get('seed', 0), + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + elif raw_config['eval']['type']['eval_model'] == 'mlp': + train_mlp( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val, + device=device + ) + elif raw_config['eval']['type']['eval_model'] == 'simple': + train_simple( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/resample_privacy.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/resample_privacy.py new file mode 100644 index 0000000000000000000000000000000000000000..54d320c3bb19ce5275d25704ad82f086601ee65d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/resample_privacy.py @@ -0,0 +1,257 @@ +""" +Adapted from https://github.com/Team-TUD/CTAB-GAN/tree/main/model/eval +""" + +import argparse +import lib +import os +import shutil +import zero +from sample import sample +from smote.sample_smote import sample_smote +from sklearn.preprocessing import MinMaxScaler, OneHotEncoder +from sklearn.metrics import pairwise_distances +from pathlib import Path +import tempfile +from eval_seeds import eval_seeds +import numpy as np +import subprocess +import warnings +import torch + +zero.improve_reproducibility(0) + +warnings.filterwarnings("ignore", category=FutureWarning) + + +def privacy_metrics(real_path,fake_path, data_percent=15): + + """ + Returns privacy metrics + + Inputs: + 1) real_path -> path to real data + 2) fake_path -> path to corresponding synthetic data + 3) data_percent -> percentage of data to be sampled from real and synthetic datasets for computing privacy metrics + Outputs: + 1) List containing the 5th percentile distance to closest record (DCR) between real and synthetic as well as within real and synthetic datasets + along with 5th percentile of nearest neighbour distance ratio (NNDR) between real and synthetic as well as within real and synthetic datasets + + """ + task_type = lib.load_json(real_path + "/info.json")["task_type"] + X_num_real, X_cat_real, y_real = lib.read_pure_data(real_path, 'train') + X_num_fake, X_cat_fake, y_fake = lib.read_pure_data(fake_path, 'train') + + if task_type == 'regression': + X_num_real = np.concatenate([X_num_real, y_real[:, np.newaxis]], axis=1) + X_num_fake = np.concatenate([X_num_fake, y_fake[:, np.newaxis]], axis=1) + else: + if X_cat_fake is None: + X_cat_real = y_real[:, np.newaxis].astype(int).astype(str) + X_cat_fake = y_fake[:, np.newaxis].astype(int).astype(str) + else: + X_cat_real = np.concatenate([X_cat_real, y_real[:, np.newaxis].astype(int).astype(str)], axis=1) + X_cat_fake = np.concatenate([X_cat_fake, y_fake[:, np.newaxis].astype(int).astype(str)], axis=1) + + if len(y_real) > 50000: + ixs = np.random.choice(len(y_real), 50000, replace=False) + X_num_real = X_num_real[ixs] + X_cat_real = X_cat_real[ixs] if X_cat_real is not None else None + + if len(y_fake) > 50000: + ixs = np.random.choice(len(y_fake), 50000, replace=False) + X_num_fake = X_num_fake[ixs] + X_cat_fake = X_cat_fake[ixs] if X_cat_fake is not None else None + + + mm = MinMaxScaler().fit(X_num_real) + X_real = mm.transform(X_num_real) + X_fake = mm.transform(X_num_fake) + if X_cat_real is not None: + ohe = OneHotEncoder().fit(X_cat_real) + X_cat_real = ohe.transform(X_cat_real) / np.sqrt(2) + X_cat_fake = ohe.transform(X_cat_fake) / np.sqrt(2) + + X_real = np.concatenate([X_real, X_cat_real.todense()], axis=1) + X_fake = np.concatenate([X_fake, X_cat_fake.todense()], axis=1) + + # X_real = np.unique(X_real, axis=0) + # X_fake = np.unique(X_fake, axis=0) + + # Computing pair-wise distances between real and synthetic + dist_rf = pairwise_distances(X_fake, Y=X_real, metric='l2', n_jobs=-1) + # Computing pair-wise distances within real + # dist_rr = pairwise_distances(X_real, Y=None, metric='l2', n_jobs=-1) + # Computing pair-wise distances within synthetic + # dist_ff = pairwise_distances(X_fake, Y=None, metric='l2', n_jobs=-1) + + + # Removes distances of data points to themselves to avoid 0s within real and synthetic + # rd_dist_rr = dist_rr[~np.eye(dist_rr.shape[0],dtype=bool)].reshape(dist_rr.shape[0],-1) + # rd_dist_ff = dist_ff[~np.eye(dist_ff.shape[0],dtype=bool)].reshape(dist_ff.shape[0],-1) + + # Computing first and second smallest nearest neighbour distances between real and synthetic + smallest_two_indexes_rf = [dist_rf[i].argsort()[:2] for i in range(len(dist_rf))] + smallest_two_rf = [dist_rf[i][smallest_two_indexes_rf[i]] for i in range(len(dist_rf))] + # Computing first and second smallest nearest neighbour distances within real + # smallest_two_indexes_rr = [rd_dist_rr[i].argsort()[:2] for i in range(len(rd_dist_rr))] + # smallest_two_rr = [rd_dist_rr[i][smallest_two_indexes_rr[i]] for i in range(len(rd_dist_rr))] + # Computing first and second smallest nearest neighbour distances within synthetic + # smallest_two_indexes_ff = [rd_dist_ff[i].argsort()[:2] for i in range(len(rd_dist_ff))] + # smallest_two_ff = [rd_dist_ff[i][smallest_two_indexes_ff[i]] for i in range(len(rd_dist_ff))] + + + # Computing 5th percentiles for DCR and NNDR between and within real and synthetic datasets + min_dist_rf = np.array([i[0] for i in smallest_two_rf]) + fifth_perc_rf = np.percentile(min_dist_rf,5) + # min_dist_rr = np.array([i[0] for i in smallest_two_rr]) + # fifth_perc_rr = np.percentile(min_dist_rr,5) + # min_dist_ff = np.array([i[0] for i in smallest_two_ff]) + # fifth_perc_ff = np.percentile(min_dist_ff,5) + # nn_ratio_rf = np.array([i[0]/i[1] for i in smallest_two_rf]) + # nn_fifth_perc_rf = np.percentile(nn_ratio_rf,5) + # nn_ratio_rr = np.array([i[0]/i[1] for i in smallest_two_rr]) + # nn_fifth_perc_rr = np.percentile(nn_ratio_rr,5) + # nn_ratio_ff = np.array([i[0]/i[1] for i in smallest_two_ff]) + # nn_fifth_perc_ff = np.percentile(nn_ratio_ff,5) + + # return np.array([fifth_perc_rf,fifth_perc_rr,fifth_perc_ff,nn_fifth_perc_rf,nn_fifth_perc_rr,nn_fifth_perc_ff]).reshape(1,6) + return min_dist_rf # , min_dist_rr + +def sample_wrapper(method, config, num_samples=None, seed=0): + if method == "ddpm": + sample( + num_samples=num_samples, + batch_size=config['sample']['batch_size'], + disbalance=config['sample'].get('disbalance', None), + **config['diffusion_params'], + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + model_path=os.path.join(config['parent_dir'], 'model.pt'), + model_type=config['model_type'], + model_params=config['model_params'], + T_dict=config['train']['T'], + num_numerical_features=config['num_numerical_features'], + seed=seed, + change_val=False, + device=torch.device(config["device"]) + ) + elif method == "smote": + sample_smote( + parent_dir=config['parent_dir'], + real_data_path=config['real_data_path'], + **config['smote_params'], + seed=seed, + change_val=False + ) + +def resample_privacy(config_path, method, q): + with tempfile.TemporaryDirectory() as dir_: + config = lib.load_config(config_path) + if method == "ddpm": + shutil.copy2(os.path.join(config['parent_dir'], 'model.pt'), os.path.join(dir_, 'model.pt')) + config["parent_dir"] = str(dir_) + parent_dir = config["parent_dir"] + + sample_wrapper(method, config, num_samples=config["sample"].get("num_samples", 0)) + + dists = privacy_metrics(config["real_data_path"], parent_dir) + old_privacy = np.median(dists) + + q10 = np.quantile(dists, q=q) + print(f"Q: {q10}") + to_drop = np.where(dists < q10) + + X_num, X_cat, y = lib.read_pure_data(parent_dir) + num_samples = len(y) + X_num = np.delete(X_num, to_drop, axis=0) + X_cat = np.delete(X_cat, to_drop, axis=0) if X_cat is not None else None + y = np.delete(y, to_drop, axis=0) + i = 1 + + while len(y) < num_samples and i <= 10: + print(f"{len(y)}/{num_samples}") + + sample_wrapper(method, config, num_samples=config["sample"].get("batch_size", 0), seed=i) + + i += 1 + + X_num_t, X_cat_t, y_t = lib.read_pure_data(parent_dir) + dists = privacy_metrics(config["real_data_path"], parent_dir) + to_drop = np.where(dists < q10) + X_num_t = np.delete(X_num_t, to_drop, axis=0) + X_cat_t = np.delete(X_cat_t, to_drop, axis=0) if X_cat is not None else None + y_t = np.delete(y_t, to_drop, axis=0) + + X_num = np.concatenate([X_num, X_num_t], axis=0)[:num_samples] + X_cat = np.concatenate([X_cat, X_cat_t], axis=0)[:num_samples] if X_cat is not None else None + y = np.concatenate([y, y_t], axis=0)[:num_samples] + + # np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + # if X_cat is not None: + # np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + # np.save(os.path.join(parent_dir, 'y_train'), y) + + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if X_cat is not None: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y) + + new_dists = privacy_metrics(config["real_data_path"], parent_dir) + + res = eval_seeds( + config, + n_seeds=10, + eval_type="synthetic", + model_type="catboost", + n_datasets=1, + dump=False + ) + print(f"Old: {old_privacy:.4f}, New: {np.median(new_dists):.4f}") + + metric = "r2-mean" if "r2-mean" in res["test"] else "f1-mean" + return res["test"][metric], np.around(np.median(new_dists), 4) + +def resample_privacy_qs(config_path, method): + config = lib.load_config(config_path) + scores = [] + privacies = [] + + eval_res = lib.load_json(Path(config["parent_dir"]) / "eval_catboost.json")["synthetic"]["test"] + metric = "r2-mean" if "r2-mean" in eval_res else "f1-mean" + scores.append(eval_res[metric]) + privacies.append(np.median(privacy_metrics(config["real_data_path"], config["parent_dir"]))) + + for q in [0.1, 0.2, 0.3, 0.4]: + score, privacy = resample_privacy(config_path, method, q) + scores.append(score) + privacies.append(privacy) + + lib.dump_json( + {"scores": scores, "privacies": privacies}, + Path(config["parent_dir"]) / "privacies.json" + ) + +def calc_privacy(config_path, method, seed=0): + config = lib.load_config(config_path) + sample_wrapper(method, config, num_samples=config["sample"]["num_samples"], seed=seed) + timer = zero.Timer() + timer.run() + dists = privacy_metrics(config["real_data_path"], config["parent_dir"]) + privacy_val = np.median(dists) + lib.dump_json({"privacy": privacy_val}, os.path.join(config["parent_dir"], "privacy.json")) + print(f"Elapsed tine:{str(timer)}") + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('method', type=str) + args = parser.parse_args() + + calc_privacy( + args.config, + args.method + ) + +if __name__ == "__main__": + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py new file mode 100644 index 0000000000000000000000000000000000000000..118592f7979bde1047cafcd90b555fbd826060d4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py @@ -0,0 +1,161 @@ +import torch +import numpy as np +import zero +import os +from tab_ddpm.gaussian_multinomial_diffsuion import GaussianMultinomialDiffusion +from tab_ddpm.utils import FoundNANsError +from scripts.utils_train import get_model, make_dataset +from lib import round_columns +import lib + +def to_good_ohe(ohe, X): + indices = np.cumsum([0] + ohe._n_features_outs) + Xres = [] + for i in range(1, len(indices)): + x_ = np.max(X[:, indices[i - 1]:indices[i]], axis=1) + t = X[:, indices[i - 1]:indices[i]] - x_.reshape(-1, 1) + Xres.append(np.where(t >= 0, 1, 0)) + return np.hstack(Xres) + +def sample( + parent_dir, + real_data_path = 'data/higgs-small', + batch_size = 2000, + num_samples = 0, + model_type = 'mlp', + model_params = None, + model_path = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + disbalance = None, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + zero.improve_reproducibility(seed) + use_ddim = os.environ.get('TABDDPM_SAMPLE_DDIM', '').strip().lower() in ('1', 'true', 'yes') + + T = lib.Transformations(**T_dict) + D = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(D.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + + num_numerical_features_ = D.X_num['train'].shape[1] if D.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features_ + model_params['d_in'] = int(d_in) + model = get_model( + model_type, + model_params, + num_numerical_features_, + category_sizes=D.get_category_sizes('train') + ) + + model.load_state_dict( + torch.load(model_path, map_location="cpu") + ) + + diffusion = GaussianMultinomialDiffusion( + K, + num_numerical_features=num_numerical_features_, + denoise_fn=model, num_timesteps=num_timesteps, + gaussian_loss_type=gaussian_loss_type, scheduler=scheduler, device=device + ) + + diffusion.to(device) + diffusion.eval() + + _, empirical_class_dist = torch.unique(torch.from_numpy(D.y['train']), return_counts=True) + # empirical_class_dist = empirical_class_dist.float() + torch.tensor([-5000., 10000.]).float() + if disbalance == 'fix': + empirical_class_dist[0], empirical_class_dist[1] = empirical_class_dist[1], empirical_class_dist[0] + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim) + + elif disbalance == 'fill': + ix_major = empirical_class_dist.argmax().item() + val_major = empirical_class_dist[ix_major].item() + x_gen, y_gen = [], [] + for i in range(empirical_class_dist.shape[0]): + if i == ix_major: + continue + distrib = torch.zeros_like(empirical_class_dist) + distrib[i] = 1 + num_samples = val_major - empirical_class_dist[i].item() + x_temp, y_temp = diffusion.sample_all(num_samples, batch_size, distrib.float(), ddim=use_ddim) + x_gen.append(x_temp) + y_gen.append(y_temp) + + x_gen = torch.cat(x_gen, dim=0) + y_gen = torch.cat(y_gen, dim=0) + + else: + x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim) + + + # try: + # except FoundNANsError as ex: + # print("Found NaNs during sampling!") + # loader = lib.prepare_fast_dataloader(D, 'train', 8) + # x_gen = next(loader)[0] + # y_gen = torch.multinomial( + # empirical_class_dist.float(), + # num_samples=8, + # replacement=True + # ) + X_gen, y_gen = x_gen.numpy(), y_gen.numpy() + + ### + # X_num_unnorm = X_gen[:, :num_numerical_features] + # lo = np.percentile(X_num_unnorm, 2.5, axis=0) + # hi = np.percentile(X_num_unnorm, 97.5, axis=0) + # idx = (lo < X_num_unnorm) & (hi > X_num_unnorm) + # X_gen = X_gen[np.all(idx, axis=1)] + # y_gen = y_gen[np.all(idx, axis=1)] + ### + + num_numerical_features = num_numerical_features + int(D.is_regression and not model_params["is_y_cond"]) + + X_num_ = X_gen + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_unnorm'), X_gen[:, num_numerical_features:]) + # _, _, cat_encoder = lib.cat_encode({'train': X_cat_real}, T_dict['cat_encoding'], y_real, T_dict['seed'], True) + if T_dict['cat_encoding'] == 'one-hot': + X_gen[:, num_numerical_features:] = to_good_ohe(D.cat_transform.steps[0][1], X_num_[:, num_numerical_features:]) + X_cat = D.cat_transform.inverse_transform(X_gen[:, num_numerical_features:]) + + if num_numerical_features_ != 0: + # _, normalize = lib.normalize({'train' : X_num_real}, T_dict['normalization'], T_dict['seed'], True) + np.save(os.path.join(parent_dir, 'X_num_unnorm'), X_gen[:, :num_numerical_features]) + X_num_ = D.num_transform.inverse_transform(X_gen[:, :num_numerical_features]) + X_num = X_num_[:, :num_numerical_features] + + X_num_real = np.load(os.path.join(real_data_path, "X_num_train.npy"), allow_pickle=True) + disc_cols = [] + for col in range(X_num_real.shape[1]): + uniq_vals = np.unique(X_num_real[:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + print("Discrete cols:", disc_cols) + # 仅当 regression 且 y 在 X_num 中(非 is_y_cond)时才提取 y;否则 y_gen 已由 sample_all 返回 + if model_params['num_classes'] == 0 and not model_params.get('is_y_cond', True): + y_gen = X_num[:, 0] + X_num = X_num[:, 1:] + if len(disc_cols): + X_num = round_columns(X_num_real, X_num, disc_cols) + + if num_numerical_features != 0: + print("Num shape: ", X_num.shape) + np.save(os.path.join(parent_dir, 'X_num_train'), X_num) + if num_numerical_features < X_gen.shape[1]: + np.save(os.path.join(parent_dir, 'X_cat_train'), X_cat) + np.save(os.path.join(parent_dir, 'y_train'), y_gen) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/train.py new file mode 100644 index 0000000000000000000000000000000000000000..84a4eef3c97b080d1cf1b122c7d4117b74a1cefd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/train.py @@ -0,0 +1,158 @@ +from copy import deepcopy +import torch +import os +import numpy as np +import zero +from tab_ddpm import GaussianMultinomialDiffusion +from scripts.utils_train import get_model, make_dataset, update_ema +import lib +import pandas as pd + +class Trainer: + def __init__(self, diffusion, train_iter, lr, weight_decay, steps, device=torch.device('cuda:1')): + self.diffusion = diffusion + self.ema_model = deepcopy(self.diffusion._denoise_fn) + for param in self.ema_model.parameters(): + param.detach_() + + self.train_iter = train_iter + self.steps = steps + self.init_lr = lr + self.optimizer = torch.optim.AdamW(self.diffusion.parameters(), lr=lr, weight_decay=weight_decay) + self.device = device + self.loss_history = pd.DataFrame(columns=['step', 'mloss', 'gloss', 'loss']) + self.log_every = 100 + self.print_every = 500 + self.ema_every = 1000 + + def _anneal_lr(self, step): + frac_done = step / self.steps + lr = self.init_lr * (1 - frac_done) + for param_group in self.optimizer.param_groups: + param_group["lr"] = lr + + def _run_step(self, x, out_dict): + x = x.to(self.device) + for k in out_dict: + out_dict[k] = out_dict[k].long().to(self.device) + self.optimizer.zero_grad() + loss_multi, loss_gauss = self.diffusion.mixed_loss(x, out_dict) + loss = loss_multi + loss_gauss + loss.backward() + self.optimizer.step() + + return loss_multi, loss_gauss + + def run_loop(self): + step = 0 + curr_loss_multi = 0.0 + curr_loss_gauss = 0.0 + + curr_count = 0 + while step < self.steps: + x, out_dict = next(self.train_iter) + out_dict = {'y': out_dict} + batch_loss_multi, batch_loss_gauss = self._run_step(x, out_dict) + + self._anneal_lr(step) + + curr_count += len(x) + curr_loss_multi += batch_loss_multi.item() * len(x) + curr_loss_gauss += batch_loss_gauss.item() * len(x) + + if (step + 1) % self.log_every == 0: + mloss = np.around(curr_loss_multi / curr_count, 4) + gloss = np.around(curr_loss_gauss / curr_count, 4) + if (step + 1) % self.print_every == 0: + print(f'Step {(step + 1)}/{self.steps} MLoss: {mloss} GLoss: {gloss} Sum: {mloss + gloss}') + self.loss_history.loc[len(self.loss_history)] =[step + 1, mloss, gloss, mloss + gloss] + curr_count = 0 + curr_loss_gauss = 0.0 + curr_loss_multi = 0.0 + + update_ema(self.ema_model.parameters(), self.diffusion._denoise_fn.parameters()) + + step += 1 + +def train( + parent_dir, + real_data_path = 'data/higgs-small', + steps = 1000, + lr = 0.002, + weight_decay = 1e-4, + batch_size = 1024, + model_type = 'mlp', + model_params = None, + num_timesteps = 1000, + gaussian_loss_type = 'mse', + scheduler = 'cosine', + T_dict = None, + num_numerical_features = 0, + device = torch.device('cuda:1'), + seed = 0, + change_val = False +): + real_data_path = os.path.normpath(real_data_path) + parent_dir = os.path.normpath(parent_dir) + + zero.improve_reproducibility(seed) + + T = lib.Transformations(**T_dict) + + dataset = make_dataset( + real_data_path, + T, + num_classes=model_params['num_classes'], + is_y_cond=model_params['is_y_cond'], + change_val=change_val + ) + + K = np.array(dataset.get_category_sizes('train')) + if len(K) == 0 or T_dict['cat_encoding'] == 'one-hot': + K = np.array([0]) + print(K) + + num_numerical_features = dataset.X_num['train'].shape[1] if dataset.X_num is not None else 0 + d_in = np.sum(K) + num_numerical_features + model_params['d_in'] = d_in + print(d_in) + + print(model_params) + model = get_model( + model_type, + model_params, + num_numerical_features, + category_sizes=dataset.get_category_sizes('train') + ) + model.to(device) + + # train_loader = lib.prepare_beton_loader(dataset, split='train', batch_size=batch_size) + train_loader = lib.prepare_fast_dataloader(dataset, split='train', batch_size=batch_size) + + + + diffusion = GaussianMultinomialDiffusion( + num_classes=K, + num_numerical_features=num_numerical_features, + denoise_fn=model, + gaussian_loss_type=gaussian_loss_type, + num_timesteps=num_timesteps, + scheduler=scheduler, + device=device + ) + diffusion.to(device) + diffusion.train() + + trainer = Trainer( + diffusion, + train_loader, + lr=lr, + weight_decay=weight_decay, + steps=steps, + device=device + ) + trainer.run_loop() + + trainer.loss_history.to_csv(os.path.join(parent_dir, 'loss.csv'), index=False) + torch.save(diffusion._denoise_fn.state_dict(), os.path.join(parent_dir, 'model.pt')) + torch.save(trainer.ema_model.state_dict(), os.path.join(parent_dir, 'model_ema.pt')) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_ddpm.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_ddpm.py new file mode 100644 index 0000000000000000000000000000000000000000..5a95dc23cab775a9ca7b7eb496bcefef58691dce --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_ddpm.py @@ -0,0 +1,127 @@ +import subprocess +import lib +import os +import optuna +from copy import deepcopy +import shutil +import argparse +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('train_size', type=int) +parser.add_argument('eval_type', type=str) +parser.add_argument('eval_model', type=str) +parser.add_argument('prefix', type=str) +parser.add_argument('--eval_seeds', action='store_true', default=False) + +args = parser.parse_args() +train_size = args.train_size +ds_name = args.ds_name +eval_type = args.eval_type +assert eval_type in ('merged', 'synthetic') +prefix = str(args.prefix) + +pipeline = f'scripts/pipeline.py' +base_config_path = f'exp/{ds_name}/config.toml' +parent_path = Path(f'exp/{ds_name}/') +exps_path = Path(f'exp/{ds_name}/many-exps/') # temporary dir. maybe will be replaced with tempdiвdr +eval_seeds = f'scripts/eval_seeds.py' + +os.makedirs(exps_path, exist_ok=True) + +def _suggest_mlp_layers(trial): + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + min_n_layers, max_n_layers, d_min, d_max = 1, 4, 7, 10 + n_layers = 2 * trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + return d_layers + +def objective(trial): + + lr = trial.suggest_loguniform('lr', 0.00001, 0.003) + d_layers = _suggest_mlp_layers(trial) + weight_decay = 0.0 + batch_size = trial.suggest_categorical('batch_size', [256, 4096]) + steps = trial.suggest_categorical('steps', [5000, 20000, 30000]) + # steps = trial.suggest_categorical('steps', [500]) # for debug + gaussian_loss_type = 'mse' + # scheduler = trial.suggest_categorical('scheduler', ['cosine', 'linear']) + num_timesteps = trial.suggest_categorical('num_timesteps', [100, 1000]) + num_samples = int(train_size * (2 ** trial.suggest_int('num_samples', -2, 1))) + + base_config = lib.load_config(base_config_path) + + base_config['train']['main']['lr'] = lr + base_config['train']['main']['steps'] = steps + base_config['train']['main']['batch_size'] = batch_size + base_config['train']['main']['weight_decay'] = weight_decay + base_config['model_params']['rtdl_params']['d_layers'] = d_layers + base_config['eval']['type']['eval_type'] = eval_type + base_config['sample']['num_samples'] = num_samples + base_config['diffusion_params']['gaussian_loss_type'] = gaussian_loss_type + base_config['diffusion_params']['num_timesteps'] = num_timesteps + # base_config['diffusion_params']['scheduler'] = scheduler + + base_config['parent_dir'] = str(exps_path / f"{trial.number}") + base_config['eval']['type']['eval_model'] = args.eval_model + if args.eval_model == "mlp": + base_config['eval']['T']['normalization'] = "quantile" + base_config['eval']['T']['cat_encoding'] = "one-hot" + + trial.set_user_attr("config", base_config) + + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--train', '--change_val'], check=True) + + n_datasets = 5 + score = 0.0 + + for sample_seed in range(n_datasets): + base_config['sample']['seed'] = sample_seed + lib.dump_config(base_config, exps_path / 'config.toml') + + subprocess.run(['python3.9', f'{pipeline}', '--config', f'{exps_path / "config.toml"}', '--sample', '--eval', '--change_val'], check=True) + + report_path = str(Path(base_config['parent_dir']) / f'results_{args.eval_model}.json') + report = lib.load_json(report_path) + + if 'r2' in report['metrics']['val']: + score += report['metrics']['val']['r2'] + else: + score += report['metrics']['val']['macro avg']['f1-score'] + + shutil.rmtree(exps_path / f"{trial.number}") + + return score / n_datasets + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=50, show_progress_bar=True) + +best_config_path = parent_path / f'{prefix}_best/config.toml' +best_config = study.best_trial.user_attrs['config'] +best_config["parent_dir"] = str(parent_path / f'{prefix}_best/') + +os.makedirs(parent_path / f'{prefix}_best', exist_ok=True) +lib.dump_config(best_config, best_config_path) +lib.dump_json(optuna.importance.get_param_importances(study), parent_path / f'{prefix}_best/importance.json') + +subprocess.run(['python3.9', f'{pipeline}', '--config', f'{best_config_path}', '--train', '--sample'], check=True) + +if args.eval_seeds: + best_exp = str(parent_path / f'{prefix}_best/config.toml') + subprocess.run(['python3.9', f'{eval_seeds}', '--config', f'{best_exp}', '10', "ddpm", eval_type, args.eval_model, '5'], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_evaluation_model.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_evaluation_model.py new file mode 100644 index 0000000000000000000000000000000000000000..8def5fd6cd1f609893e4de5f5c9708edb0a2efb7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/tune_evaluation_model.py @@ -0,0 +1,145 @@ +import optuna +import lib +import argparse +from eval_catboost import train_catboost +from eval_mlp import train_mlp +from pathlib import Path + +parser = argparse.ArgumentParser() +parser.add_argument('ds_name', type=str) +parser.add_argument('model', type=str) +parser.add_argument('tune_type', type=str) +parser.add_argument('device', type=str) + +args = parser.parse_args() +data_path = Path(f"data/{args.ds_name}") +best_params = None + +assert args.tune_type in ("cv", "val") + +def _suggest(trial: optuna.trial.Trial, distribution: str, label: str, *args): + return getattr(trial, f'suggest_{distribution}')(label, *args) + +def _suggest_optional(trial: optuna.trial.Trial, distribution: str, label: str, *args): + if trial.suggest_categorical(f"optional_{label}", [True, False]): + return _suggest(trial, distribution, label, *args) + else: + return 0.0 + +def _suggest_mlp_layers(trial: optuna.trial.Trial, mlp_d_layers: list[int]): + + min_n_layers, max_n_layers = mlp_d_layers[0], mlp_d_layers[1] + d_min, d_max = mlp_d_layers[2], mlp_d_layers[3] + + def suggest_dim(name): + t = trial.suggest_int(name, d_min, d_max) + return 2 ** t + + + n_layers = trial.suggest_int('n_layers', min_n_layers, max_n_layers) + d_first = [suggest_dim('d_first')] if n_layers else [] + d_middle = ( + [suggest_dim('d_middle')] * (n_layers - 2) + if n_layers > 2 + else [] + ) + d_last = [suggest_dim('d_last')] if n_layers > 1 else [] + d_layers = d_first + d_middle + d_last + + return d_layers + +def suggest_mlp_params(trial): + params = {} + params["lr"] = trial.suggest_loguniform("lr", 5e-5, 0.005) + params["dropout"] = _suggest_optional(trial, "uniform", "dropout", 0.0, 0.5) + params["weight_decay"] = _suggest_optional(trial, "loguniform", "weight_decay", 1e-6, 1e-2) + params["d_layers"] = _suggest_mlp_layers(trial, [1, 8, 6, 10]) + + return params + +def suggest_catboost_params(trial): + params = {} + params["learning_rate"] = trial.suggest_loguniform("learning_rate", 0.001, 1.0) + params["depth"] = trial.suggest_int("depth", 3, 10) + params["l2_leaf_reg"] = trial.suggest_uniform("l2_leaf_reg", 0.1, 10.0) + params["bagging_temperature"] = trial.suggest_uniform("bagging_temperature", 0.0, 1.0) + params["leaf_estimation_iterations"] = trial.suggest_int("leaf_estimation_iterations", 1, 10) + + params = params | { + "iterations": 2000, + "early_stopping_rounds": 50, + "od_pval": 0.001, + "task_type": "CPU", # "GPU", may affect performance + "thread_count": 4, + # "devices": "0", # for GPU + } + + return params + +def objective(trial): + if args.model == "mlp": + params = suggest_mlp_params(trial) + train_func = train_mlp + T_dict = { + "seed": 0, + "normalization": "quantile", + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": "one-hot", + "y_policy": "default" + } + else: + params = suggest_catboost_params(trial) + train_func = train_catboost + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + trial.set_user_attr("params", params) + if args.tune_type == "cv": + score = 0.0 + for fold in range(5): + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path / f"kfolds/{fold}", + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score += metrics_report.get_val_score() + score /= 5 + + elif args.tune_type == "val": + metrics_report = train_func( + parent_dir=None, + real_data_path=data_path, + eval_type="real", + T_dict=T_dict, + params=params, + change_val=False, + device=args.device + ) + score = metrics_report.get_val_score() + + return score + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=100, show_progress_bar=True) + +bets_params = study.best_trial.user_attrs['params'] + +best_params_path = f"tuned_models/{args.model}/{args.ds_name}_{args.tune_type}.json" + +lib.dump_json(bets_params, best_params_path) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/utils_train.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/utils_train.py new file mode 100644 index 0000000000000000000000000000000000000000..4132ca56fb8e063111f916f903ef4e99206486e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/utils_train.py @@ -0,0 +1,89 @@ +import numpy as np +import os +import lib +from tab_ddpm.modules import MLPDiffusion, ResNetDiffusion + +def get_model( + model_name, + model_params, + n_num_features, + category_sizes +): + print(model_name) + if model_name == 'mlp': + model = MLPDiffusion(**model_params) + elif model_name == 'resnet': + model = ResNetDiffusion(**model_params) + else: + raise "Unknown model!" + return model + +def update_ema(target_params, source_params, rate=0.999): + """ + Update target parameters to be closer to those of source parameters using + an exponential moving average. + :param target_params: the target parameter sequence. + :param source_params: the source parameter sequence. + :param rate: the EMA rate (closer to 1 means slower). + """ + for targ, src in zip(target_params, source_params): + targ.detach().mul_(rate).add_(src.detach(), alpha=1 - rate) + +def concat_y_to_X(X, y): + if X is None: + return y.reshape(-1, 1) + return np.concatenate([y.reshape(-1, 1), X], axis=1) + +def make_dataset( + data_path: str, + T: lib.Transformations, + num_classes: int, + is_y_cond: bool, + change_val: bool +): + # classification + if num_classes > 0: + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) or not is_y_cond else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if X_num is not None: + X_num[split] = X_num_t + if not is_y_cond: + X_cat_t = concat_y_to_X(X_cat_t, y_t) + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + else: + # regression + X_cat = {} if os.path.exists(os.path.join(data_path, 'X_cat_train.npy')) else None + X_num = {} if os.path.exists(os.path.join(data_path, 'X_num_train.npy')) or not is_y_cond else None + y = {} + + for split in ['train']: + X_num_t, X_cat_t, y_t = lib.read_pure_data(data_path, split) + if not is_y_cond: + X_num_t = concat_y_to_X(X_num_t, y_t) + if X_num is not None: + X_num[split] = X_num_t + if X_cat is not None: + X_cat[split] = X_cat_t + y[split] = y_t + + info = lib.load_json(os.path.join(data_path, 'info.json')) + + D = lib.Dataset( + X_num, + X_cat, + y, + y_info={}, + task_type=lib.TaskType(info['task_type']), + n_classes=info.get('n_classes') + ) + + if change_val: + D = lib.change_val(D) + + return lib.transform_dataset(D, T, None) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/pipeline_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/pipeline_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..4a6775493e975104c268a2cd177f953ea9589d0a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/pipeline_smote.py @@ -0,0 +1,68 @@ +import tomli +import shutil +import os +import argparse +from sample_smote import sample_smote +from scripts.eval_catboost import train_catboost +# from scripts.eval_mlp import train_mlp +import zero +import lib + +def load_config(path) : + with open(path, 'rb') as f: + return tomli.load(f) + +def save_file(parent_dir, config_path): + try: + dst = os.path.join(parent_dir) + os.makedirs(os.path.dirname(dst), exist_ok=True) + shutil.copyfile(os.path.abspath(config_path), dst) + except shutil.SameFileError: + pass + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('--config', metavar='FILE') + parser.add_argument('--sample', action='store_true', default=False) + parser.add_argument('--eval', action='store_true', default=False) + parser.add_argument('--change_val', action='store_true', default=False) + + args = parser.parse_args() + raw_config = lib.load_config(args.config) + timer = zero.Timer() + timer.run() + save_file(os.path.join(raw_config['parent_dir'], 'config.toml'), args.config) + if args.sample: + sample_smote( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + **raw_config['smote_params'], + seed=raw_config['seed'], + change_val=args.change_val + ) + + save_file(os.path.join(raw_config['parent_dir'], 'info.json'), os.path.join(raw_config['real_data_path'], 'info.json')) + if args.eval: + if raw_config['eval']['type']['eval_model'] == 'catboost': + train_catboost( + parent_dir=raw_config['parent_dir'], + real_data_path=raw_config['real_data_path'], + eval_type=raw_config['eval']['type']['eval_type'], + T_dict=raw_config['eval']['T'], + seed=raw_config['seed'], + change_val=args.change_val + ) + # elif raw_config['eval']['type']['eval_model'] == 'mlp': + # train_mlp( + # parent_dir=raw_config['parent_dir'], + # real_data_path=raw_config['real_data_path'], + # eval_type=raw_config['eval']['type']['eval_type'], + # T_dict=raw_config['eval']['T'], + # seed=raw_config['seed'], + # change_val=args.change_val + # ) + + print(f'Elapsed time: {str(timer)}') + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/sample_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/sample_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..63674186c3f1524d57bb4882f0c3dd432147230f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/sample_smote.py @@ -0,0 +1,210 @@ +import os +import lib +import argparse +import numpy as np +from pathlib import Path +from typing import Union, Any +from imblearn.over_sampling import SMOTE, SMOTENC +from sklearn.model_selection import train_test_split +from sklearn.preprocessing import MinMaxScaler +from sklearn.utils import check_random_state + +class MySMOTE(SMOTE): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None, + ): + super().__init__( + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=lam1 + self.lam2=lam2 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +class MySMOTENC(SMOTENC): + def __init__( + self, + lam1=0.0, + lam2=1.0, + *, + categorical_features, + sampling_strategy="auto", + random_state=None, + k_neighbors=5, + n_jobs=None + ): + super().__init__( + categorical_features=categorical_features, + sampling_strategy=sampling_strategy, + random_state=random_state, + k_neighbors=k_neighbors, + n_jobs=n_jobs, + ) + + self.lam1=0.0 + self.lam2=1.0 + + def _make_samples( + self, X, y_dtype, y_type, nn_data, nn_num, n_samples, step_size=1.0, lam1=0.0, lam2=1.0 + ): + random_state = check_random_state(self.random_state) + samples_indices = random_state.randint(low=0, high=nn_num.size, size=n_samples) + + # np.newaxis for backwards compatability with random_state + steps = step_size * random_state.uniform(low=self.lam1, high=self.lam2, size=n_samples)[:, np.newaxis] + rows = np.floor_divide(samples_indices, nn_num.shape[1]) + cols = np.mod(samples_indices, nn_num.shape[1]) + + X_new = self._generate_samples(X, nn_data, nn_num, rows, cols, steps) + y_new = np.full(n_samples, fill_value=y_type, dtype=y_dtype) + return X_new, y_new + +def save_data(X, y, path, n_cat_features=0): + if n_cat_features > 0: + X_num = X[:, :-n_cat_features] + X_cat = X[:, -n_cat_features:] + else: + X_num = X + X_cat = None + + + np.save(path / "X_num_train", X_num.astype(float), allow_pickle=True) + np.save(path / "y_train", y, allow_pickle=True) + if X_cat is not None: + np.save(path / "X_cat_train", X_cat, allow_pickle=True) + +def sample_smote( + parent_dir, + real_data_path, + eval_type = "synthetic", + k_neighbours = 5, + frac_samples = 1.0, + frac_lam_del = 0.0, + change_val = False, + save = True, + seed = 0 +): + lam1 = 0.0 + frac_lam_del / 2 + lam2 = 1.0 - frac_lam_del / 2 + + real_data_path = Path(real_data_path) + info = lib.load_json(real_data_path / 'info.json') + is_regression = info['task_type'] == 'regression' + + X_num = {} + X_cat = {} + y = {} + + if change_val: + X_num['train'], X_cat['train'], y['train'], X_num['val'], X_cat['val'], y['val'] = lib.read_changed_val(real_data_path) + else: + X_num['train'], X_cat['train'], y['train'] = lib.read_pure_data(real_data_path, 'train') + X_num['val'], X_cat['val'], y['val'] = lib.read_pure_data(real_data_path, 'val') + X_num['test'], X_cat['test'], y['test'] = lib.read_pure_data(real_data_path, 'test') + + + X = {k: X_num[k] for k in X_num.keys()} + + if is_regression: + X['train'] = np.concatenate([X["train"], y["train"].reshape(-1, 1)], axis=1, dtype=object) + y['train'] = np.where(y["train"] > np.median(y["train"]), 1, 0) + + n_num_features = X['train'].shape[1] + n_cat_features = X_cat['train'].shape[1] if X_cat['train'] is not None else 0 + cat_features = list(range(n_num_features, n_num_features+n_cat_features)) + print(cat_features) + + scaler = MinMaxScaler().fit(X["train"]) + X["train"] = scaler.transform(X["train"]).astype(object) + + if X_cat['train'] is not None: + for k in X_num.keys(): + X[k] = np.concatenate([X[k], X_cat[k]], axis=1, dtype=object) + + print("Before:", X['train'].shape) + + if eval_type != 'real': + strat = {k: int((1 + frac_samples) * np.sum(y['train'] == k)) for k in np.unique(y['train'])} + print(strat) + if n_cat_features > 0: + sm = MySMOTENC( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + categorical_features=cat_features, + sampling_strategy=strat + ) + else: + sm = MySMOTE( + lam1=lam1, + lam2=lam2, + random_state=seed, + k_neighbors=k_neighbours, + sampling_strategy=strat + ) + + X_res, y_res = sm.fit_resample(X['train'], y['train']) + if is_regression: + X_res[:, :X_num["train"].shape[1]+1] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]+1]) + y_res = X_res[:, X_num["train"].shape[1]] + X_res = np.delete(X_res, [X_num["train"].shape[1]], axis=1) + else: + X_res[:, :X_num["train"].shape[1]] = scaler.inverse_transform(X_res[:, :X_num["train"].shape[1]]) + y_res = y_res.astype(int) + + if eval_type == "synthetic": + X_res = X_res[X['train'].shape[0]:] + y_res = y_res[X['train'].shape[0]:] + + disc_cols = [] + for col in range(X_num["train"].shape[1]): + uniq_vals = np.unique(X_num["train"][:, col]) + if len(uniq_vals) <= 32 and ((uniq_vals - np.round(uniq_vals)) == 0).all(): + disc_cols.append(col) + if len(disc_cols): + X_res[:, :X_num["train"].shape[1]] = lib.round_columns(X_num["train"], X_res[:, :X_num["train"].shape[1]], disc_cols) + + if save: + save_data(X_res, y_res, Path(parent_dir), n_cat_features) + + X['train'] = X_res + y['train'] = y_res + + return X, y + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument('data_path', type=str) + parser.add_argument('method', type=str) + + args = parser.parse_args() + + sample_smote(args.data_path, args.method, save=False) + +if __name__ == '__main__': + main() \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/tune_smote.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/tune_smote.py new file mode 100644 index 0000000000000000000000000000000000000000..9c98e205150bd02fee9ce399280714101bd427c3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/smote/tune_smote.py @@ -0,0 +1,98 @@ +import optuna +import lib +from copy import deepcopy +import argparse +import tempfile +from pathlib import Path +import os +from scripts.eval_catboost import train_catboost +from sample_smote import sample_smote +import subprocess + +parser = argparse.ArgumentParser() +parser.add_argument('data_path', type=str) +parser.add_argument('eval_type', type=str) + +args = parser.parse_args() +real_data_path = args.data_path +eval_type = args.eval_type + +def objective(trial): + + k_neighbours = trial.suggest_int("k_neighbours", 5, 20) + frac_samples = 2 ** trial.suggest_int('frac_samples', -2, 3) + + # z = \lam*x + (1 - \lam)*y, \lam ~ U[frac_lam_del/2, 1-frac_lam_del/2] + frac_lam_del = trial.suggest_float("frac_lam_del", 0.0, 0.95, step=0.05) + + score = 0.0 + with tempfile.TemporaryDirectory() as dir_: + dir_ = Path(dir_) + for seed in range(5): + sample_smote( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + frac_samples=frac_samples, + frac_lam_del=frac_lam_del, + k_neighbours=k_neighbours, + change_val=True, + seed=seed + ) + T_dict = { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + } + metrics = train_catboost( + parent_dir=dir_, + real_data_path=real_data_path, + eval_type=eval_type, + T_dict=T_dict, + change_val=True, + seed = 0 + ) + + score += metrics.get_val_score() + + return score / 5 + +study = optuna.create_study( + direction='maximize', + sampler=optuna.samplers.TPESampler(seed=0), +) + +study.optimize(objective, n_trials=5, show_progress_bar=True) + +os.makedirs(f"exp/{Path(real_data_path).name}/smote/", exist_ok=True) +config = { + "parent_dir": f"exp/{Path(real_data_path).name}/smote/", + "real_data_path": real_data_path, + "seed": 0, + "smote_params": {}, + "sample": {"seed": 0}, + "eval": { + "type": {"eval_model": "catboost", "eval_type": eval_type}, + "T": { + "seed": 0, + "normalization": None, + "num_nan_policy": None, + "cat_nan_policy": None, + "cat_min_frequency": None, + "cat_encoding": None, + "y_policy": "default" + }, + } +} + +config["smote_params"] = study.best_params +config["smote_params"]["frac_samples"] = 2 ** config["smote_params"]["frac_samples"] + +lib.dump_config(config, config["parent_dir"]+"config.toml") + +subprocess.run(['python3.9', "scripts/eval_seeds.py", '--config', f'{config["parent_dir"]+"config.toml"}', + '10', "smote", eval_type, "catboost", "5"], check=True) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/__init__.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..8ad340c806b61da5a372186d04f2e7ab88a74daa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/__init__.py @@ -0,0 +1,2 @@ +from .gaussian_multinomial_diffsuion import * # noqa +from .modules import * # noqa \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py new file mode 100644 index 0000000000000000000000000000000000000000..5e3cb1c3086b2fa5862552e91e648677bb673dd9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py @@ -0,0 +1,993 @@ +""" +Based on https://github.com/openai/guided-diffusion/blob/main/guided_diffusion +and https://github.com/ehoogeboom/multinomial_diffusion +""" + +import torch.nn.functional as F +import torch +import math + +import numpy as np +from .utils import * + +""" +Based in part on: https://github.com/lucidrains/denoising-diffusion-pytorch/blob/5989f4c77eafcdc6be0fb4739f0f277a6dd7f7d8/denoising_diffusion_pytorch/denoising_diffusion_pytorch.py#L281 +""" +eps = 1e-8 + +def get_named_beta_schedule(schedule_name, num_diffusion_timesteps): + """ + Get a pre-defined beta schedule for the given name. + The beta schedule library consists of beta schedules which remain similar + in the limit of num_diffusion_timesteps. + Beta schedules may be added, but should not be removed or changed once + they are committed to maintain backwards compatibility. + """ + if schedule_name == "linear": + # Linear schedule from Ho et al, extended to work for any number of + # diffusion steps. + scale = 1000 / num_diffusion_timesteps + beta_start = scale * 0.0001 + beta_end = scale * 0.02 + return np.linspace( + beta_start, beta_end, num_diffusion_timesteps, dtype=np.float64 + ) + elif schedule_name == "cosine": + return betas_for_alpha_bar( + num_diffusion_timesteps, + lambda t: math.cos((t + 0.008) / 1.008 * math.pi / 2) ** 2, + ) + else: + raise NotImplementedError(f"unknown beta schedule: {schedule_name}") + + +def betas_for_alpha_bar(num_diffusion_timesteps, alpha_bar, max_beta=0.999): + """ + Create a beta schedule that discretizes the given alpha_t_bar function, + which defines the cumulative product of (1-beta) over time from t = [0,1]. + :param num_diffusion_timesteps: the number of betas to produce. + :param alpha_bar: a lambda that takes an argument t from 0 to 1 and + produces the cumulative product of (1-beta) up to that + part of the diffusion process. + :param max_beta: the maximum beta to use; use values lower than 1 to + prevent singularities. + """ + betas = [] + for i in range(num_diffusion_timesteps): + t1 = i / num_diffusion_timesteps + t2 = (i + 1) / num_diffusion_timesteps + betas.append(min(1 - alpha_bar(t2) / alpha_bar(t1), max_beta)) + return np.array(betas) + +class GaussianMultinomialDiffusion(torch.nn.Module): + def __init__( + self, + num_classes: np.array, + num_numerical_features: int, + denoise_fn, + num_timesteps=1000, + gaussian_loss_type='mse', + gaussian_parametrization='eps', + multinomial_loss_type='vb_stochastic', + parametrization='x0', + scheduler='cosine', + device=torch.device('cpu') + ): + + super(GaussianMultinomialDiffusion, self).__init__() + assert multinomial_loss_type in ('vb_stochastic', 'vb_all') + assert parametrization in ('x0', 'direct') + + if multinomial_loss_type == 'vb_all': + print('Computing the loss using the bound on _all_ timesteps.' + ' This is expensive both in terms of memory and computation.') + + self.num_numerical_features = num_numerical_features + self.num_classes = num_classes # it as a vector [K1, K2, ..., Km] + self.num_classes_expanded = torch.from_numpy( + np.concatenate([num_classes[i].repeat(num_classes[i]) for i in range(len(num_classes))]) + ).to(device) + + self.slices_for_classes = [np.arange(self.num_classes[0])] + offsets = np.cumsum(self.num_classes) + for i in range(1, len(offsets)): + self.slices_for_classes.append(np.arange(offsets[i - 1], offsets[i])) + self.offsets = torch.from_numpy(np.append([0], offsets)).to(device) + + self._denoise_fn = denoise_fn + self.gaussian_loss_type = gaussian_loss_type + self.gaussian_parametrization = gaussian_parametrization + self.multinomial_loss_type = multinomial_loss_type + self.num_timesteps = num_timesteps + self.parametrization = parametrization + self.scheduler = scheduler + + alphas = 1. - get_named_beta_schedule(scheduler, num_timesteps) + alphas = torch.tensor(alphas.astype('float64')) + betas = 1. - alphas + + log_alpha = np.log(alphas) + log_cumprod_alpha = np.cumsum(log_alpha) + + log_1_min_alpha = log_1_min_a(log_alpha) + log_1_min_cumprod_alpha = log_1_min_a(log_cumprod_alpha) + + alphas_cumprod = np.cumprod(alphas, axis=0) + alphas_cumprod_prev = torch.tensor(np.append(1.0, alphas_cumprod[:-1])) + alphas_cumprod_next = torch.tensor(np.append(alphas_cumprod[1:], 0.0)) + sqrt_alphas_cumprod = np.sqrt(alphas_cumprod) + sqrt_one_minus_alphas_cumprod = np.sqrt(1.0 - alphas_cumprod) + sqrt_recip_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod) + sqrt_recipm1_alphas_cumprod = np.sqrt(1.0 / alphas_cumprod - 1) + + # Gaussian diffusion + + self.posterior_variance = ( + betas * (1.0 - alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ) + self.posterior_log_variance_clipped = torch.from_numpy( + np.log(np.append(self.posterior_variance[1], self.posterior_variance[1:])) + ).float().to(device) + self.posterior_mean_coef1 = ( + betas * np.sqrt(alphas_cumprod_prev) / (1.0 - alphas_cumprod) + ).float().to(device) + self.posterior_mean_coef2 = ( + (1.0 - alphas_cumprod_prev) + * np.sqrt(alphas.numpy()) + / (1.0 - alphas_cumprod) + ).float().to(device) + + assert log_add_exp(log_alpha, log_1_min_alpha).abs().sum().item() < 1.e-5 + assert log_add_exp(log_cumprod_alpha, log_1_min_cumprod_alpha).abs().sum().item() < 1e-5 + assert (np.cumsum(log_alpha) - log_cumprod_alpha).abs().sum().item() < 1.e-5 + + # Convert to float32 and register buffers. + self.register_buffer('alphas', alphas.float().to(device)) + self.register_buffer('log_alpha', log_alpha.float().to(device)) + self.register_buffer('log_1_min_alpha', log_1_min_alpha.float().to(device)) + self.register_buffer('log_1_min_cumprod_alpha', log_1_min_cumprod_alpha.float().to(device)) + self.register_buffer('log_cumprod_alpha', log_cumprod_alpha.float().to(device)) + self.register_buffer('alphas_cumprod', alphas_cumprod.float().to(device)) + self.register_buffer('alphas_cumprod_prev', alphas_cumprod_prev.float().to(device)) + self.register_buffer('alphas_cumprod_next', alphas_cumprod_next.float().to(device)) + self.register_buffer('sqrt_alphas_cumprod', sqrt_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_one_minus_alphas_cumprod', sqrt_one_minus_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recip_alphas_cumprod', sqrt_recip_alphas_cumprod.float().to(device)) + self.register_buffer('sqrt_recipm1_alphas_cumprod', sqrt_recipm1_alphas_cumprod.float().to(device)) + + self.register_buffer('Lt_history', torch.zeros(num_timesteps)) + self.register_buffer('Lt_count', torch.zeros(num_timesteps)) + + # Gaussian part + def gaussian_q_mean_variance(self, x_start, t): + mean = ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + ) + variance = extract(1.0 - self.alphas_cumprod, t, x_start.shape) + log_variance = extract( + self.log_1_min_cumprod_alpha, t, x_start.shape + ) + return mean, variance, log_variance + + def gaussian_q_sample(self, x_start, t, noise=None): + if noise is None: + noise = torch.randn_like(x_start) + assert noise.shape == x_start.shape + return ( + extract(self.sqrt_alphas_cumprod, t, x_start.shape) * x_start + + extract(self.sqrt_one_minus_alphas_cumprod, t, x_start.shape) + * noise + ) + + def gaussian_q_posterior_mean_variance(self, x_start, x_t, t): + assert x_start.shape == x_t.shape + posterior_mean = ( + extract(self.posterior_mean_coef1, t, x_t.shape) * x_start + + extract(self.posterior_mean_coef2, t, x_t.shape) * x_t + ) + posterior_variance = extract(self.posterior_variance, t, x_t.shape) + posterior_log_variance_clipped = extract( + self.posterior_log_variance_clipped, t, x_t.shape + ) + assert ( + posterior_mean.shape[0] + == posterior_variance.shape[0] + == posterior_log_variance_clipped.shape[0] + == x_start.shape[0] + ) + return posterior_mean, posterior_variance, posterior_log_variance_clipped + + def gaussian_p_mean_variance( + self, model_output, x, t, clip_denoised=False, denoised_fn=None, model_kwargs=None + ): + if model_kwargs is None: + model_kwargs = {} + + B, C = x.shape[:2] + assert t.shape == (B,) + + model_variance = torch.cat([self.posterior_variance[1].unsqueeze(0).to(x.device), (1. - self.alphas)[1:]], dim=0) + # model_variance = self.posterior_variance.to(x.device) + model_log_variance = torch.log(model_variance) + + model_variance = extract(model_variance, t, x.shape) + model_log_variance = extract(model_log_variance, t, x.shape) + + + if self.gaussian_parametrization == 'eps': + pred_xstart = self._predict_xstart_from_eps(x_t=x, t=t, eps=model_output) + elif self.gaussian_parametrization == 'x0': + pred_xstart = model_output + else: + raise NotImplementedError + + model_mean, _, _ = self.gaussian_q_posterior_mean_variance( + x_start=pred_xstart, x_t=x, t=t + ) + + assert ( + model_mean.shape == model_log_variance.shape == pred_xstart.shape == x.shape + ), f'{model_mean.shape}, {model_log_variance.shape}, {pred_xstart.shape}, {x.shape}' + + return { + "mean": model_mean, + "variance": model_variance, + "log_variance": model_log_variance, + "pred_xstart": pred_xstart, + } + + def _vb_terms_bpd( + self, model_output, x_start, x_t, t, clip_denoised=False, model_kwargs=None + ): + true_mean, _, true_log_variance_clipped = self.gaussian_q_posterior_mean_variance( + x_start=x_start, x_t=x_t, t=t + ) + out = self.gaussian_p_mean_variance( + model_output, x_t, t, clip_denoised=clip_denoised, model_kwargs=model_kwargs + ) + kl = normal_kl( + true_mean, true_log_variance_clipped, out["mean"], out["log_variance"] + ) + kl = mean_flat(kl) / np.log(2.0) + + decoder_nll = -discretized_gaussian_log_likelihood( + x_start, means=out["mean"], log_scales=0.5 * out["log_variance"] + ) + assert decoder_nll.shape == x_start.shape + decoder_nll = mean_flat(decoder_nll) / np.log(2.0) + + # At the first timestep return the decoder NLL, + # otherwise return KL(q(x_{t-1}|x_t,x_0) || p(x_{t-1}|x_t)) + output = torch.where((t == 0), decoder_nll, kl) + return {"output": output, "pred_xstart": out["pred_xstart"], "out_mean": out["mean"], "true_mean": true_mean} + + def _prior_gaussian(self, x_start): + """ + Get the prior KL term for the variational lower-bound, measured in + bits-per-dim. + + This term can't be optimized, as it only depends on the encoder. + + :param x_start: the [N x C x ...] tensor of inputs. + :return: a batch of [N] KL values (in bits), one per batch element. + """ + batch_size = x_start.shape[0] + t = torch.tensor([self.num_timesteps - 1] * batch_size, device=x_start.device) + qt_mean, _, qt_log_variance = self.gaussian_q_mean_variance(x_start, t) + kl_prior = normal_kl( + mean1=qt_mean, logvar1=qt_log_variance, mean2=0.0, logvar2=0.0 + ) + return mean_flat(kl_prior) / np.log(2.0) + + def _gaussian_loss(self, model_out, x_start, x_t, t, noise, model_kwargs=None): + if model_kwargs is None: + model_kwargs = {} + + terms = {} + if self.gaussian_loss_type == 'mse': + terms["loss"] = mean_flat((noise - model_out) ** 2) + elif self.gaussian_loss_type == 'kl': + terms["loss"] = self._vb_terms_bpd( + model_output=model_out, + x_start=x_start, + x_t=x_t, + t=t, + clip_denoised=False, + model_kwargs=model_kwargs, + )["output"] + + + return terms['loss'] + + def _predict_xstart_from_eps(self, x_t, t, eps): + assert x_t.shape == eps.shape + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) * eps + ) + + def _predict_eps_from_xstart(self, x_t, t, pred_xstart): + return ( + extract(self.sqrt_recip_alphas_cumprod, t, x_t.shape) * x_t + - pred_xstart + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x_t.shape) + + def gaussian_p_sample( + self, + model_out, + x, + t, + clip_denoised=False, + denoised_fn=None, + model_kwargs=None, + ): + out = self.gaussian_p_mean_variance( + model_out, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=model_kwargs, + ) + noise = torch.randn_like(x) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + + sample = out["mean"] + nonzero_mask * torch.exp(0.5 * out["log_variance"]) * noise + return {"sample": sample, "pred_xstart": out["pred_xstart"]} + + # Multinomial part + + def multinomial_kl(self, log_prob1, log_prob2): + kl = (log_prob1.exp() * (log_prob1 - log_prob2)).sum(dim=1) + return kl + + def q_pred_one_timestep(self, log_x_t, t): + log_alpha_t = extract(self.log_alpha, t, log_x_t.shape) + log_1_min_alpha_t = extract(self.log_1_min_alpha, t, log_x_t.shape) + + # alpha_t * E[xt] + (1 - alpha_t) 1 / K + log_probs = log_add_exp( + log_x_t + log_alpha_t, + log_1_min_alpha_t - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def q_pred(self, log_x_start, t): + log_cumprod_alpha_t = extract(self.log_cumprod_alpha, t, log_x_start.shape) + log_1_min_cumprod_alpha = extract(self.log_1_min_cumprod_alpha, t, log_x_start.shape) + + log_probs = log_add_exp( + log_x_start + log_cumprod_alpha_t, + log_1_min_cumprod_alpha - torch.log(self.num_classes_expanded) + ) + + return log_probs + + def predict_start(self, model_out, log_x_t, t, out_dict): + + # model_out = self._denoise_fn(x_t, t.to(x_t.device), **out_dict) + + assert model_out.size(0) == log_x_t.size(0) + assert model_out.size(1) == self.num_classes.sum(), f'{model_out.size()}' + + log_pred = torch.empty_like(model_out) + for ix in self.slices_for_classes: + log_pred[:, ix] = F.log_softmax(model_out[:, ix], dim=1) + return log_pred + + def q_posterior(self, log_x_start, log_x_t, t): + # q(xt-1 | xt, x0) = q(xt | xt-1, x0) * q(xt-1 | x0) / q(xt | x0) + # where q(xt | xt-1, x0) = q(xt | xt-1). + + # EV_log_qxt_x0 = self.q_pred(log_x_start, t) + + # print('sum exp', EV_log_qxt_x0.exp().sum(1).mean()) + # assert False + + # log_qxt_x0 = (log_x_t.exp() * EV_log_qxt_x0).sum(dim=1) + t_minus_1 = t - 1 + # Remove negative values, will not be used anyway for final decoder + t_minus_1 = torch.where(t_minus_1 < 0, torch.zeros_like(t_minus_1), t_minus_1) + log_EV_qxtmin_x0 = self.q_pred(log_x_start, t_minus_1) + + num_axes = (1,) * (len(log_x_start.size()) - 1) + t_broadcast = t.to(log_x_start.device).view(-1, *num_axes) * torch.ones_like(log_x_start) + log_EV_qxtmin_x0 = torch.where(t_broadcast == 0, log_x_start, log_EV_qxtmin_x0.to(torch.float32)) + + # unnormed_logprobs = log_EV_qxtmin_x0 + + # log q_pred_one_timestep(x_t, t) + # Note: _NOT_ x_tmin1, which is how the formula is typically used!!! + # Not very easy to see why this is true. But it is :) + unnormed_logprobs = log_EV_qxtmin_x0 + self.q_pred_one_timestep(log_x_t, t) + + log_EV_xtmin_given_xt_given_xstart = \ + unnormed_logprobs \ + - sliced_logsumexp(unnormed_logprobs, self.offsets) + + return log_EV_xtmin_given_xt_given_xstart + + def p_pred(self, model_out, log_x, t, out_dict): + if self.parametrization == 'x0': + log_x_recon = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + log_model_pred = self.q_posterior( + log_x_start=log_x_recon, log_x_t=log_x, t=t) + elif self.parametrization == 'direct': + log_model_pred = self.predict_start(model_out, log_x, t=t, out_dict=out_dict) + else: + raise ValueError + return log_model_pred + + @torch.no_grad() + def p_sample(self, model_out, log_x, t, out_dict): + model_log_prob = self.p_pred(model_out, log_x=log_x, t=t, out_dict=out_dict) + out = self.log_sample_categorical(model_log_prob) + return out + + @torch.no_grad() + def p_sample_loop(self, shape, out_dict): + device = self.log_alpha.device + + b = shape[0] + # start with random normal image. + img = torch.randn(shape, device=device) + + for i in reversed(range(1, self.num_timesteps)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long), out_dict) + return img + + @torch.no_grad() + def _sample(self, image_size, out_dict, batch_size = 16): + return self.p_sample_loop((batch_size, 3, image_size, image_size), out_dict) + + @torch.no_grad() + def interpolate(self, x1, x2, t = None, lam = 0.5): + b, *_, device = *x1.shape, x1.device + t = default(t, self.num_timesteps - 1) + + assert x1.shape == x2.shape + + t_batched = torch.stack([torch.tensor(t, device=device)] * b) + xt1, xt2 = map(lambda x: self.q_sample(x, t=t_batched), (x1, x2)) + + img = (1 - lam) * xt1 + lam * xt2 + for i in reversed(range(0, t)): + img = self.p_sample(img, torch.full((b,), i, device=device, dtype=torch.long)) + + return img + + def log_sample_categorical(self, logits): + full_sample = [] + for i in range(len(self.num_classes)): + one_class_logits = logits[:, self.slices_for_classes[i]] + uniform = torch.rand_like(one_class_logits) + gumbel_noise = -torch.log(-torch.log(uniform + 1e-30) + 1e-30) + sample = (gumbel_noise + one_class_logits).argmax(dim=1) + full_sample.append(sample.unsqueeze(1)) + full_sample = torch.cat(full_sample, dim=1) + log_sample = index_to_log_onehot(full_sample, self.num_classes) + return log_sample + + def q_sample(self, log_x_start, t): + log_EV_qxt_x0 = self.q_pred(log_x_start, t) + + log_sample = self.log_sample_categorical(log_EV_qxt_x0) + + return log_sample + + def nll(self, log_x_start, out_dict): + b = log_x_start.size(0) + device = log_x_start.device + loss = 0 + for t in range(0, self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + + kl = self.compute_Lt( + log_x_start=log_x_start, + log_x_t=self.q_sample(log_x_start=log_x_start, t=t_array), + t=t_array, + out_dict=out_dict) + + loss += kl + + loss += self.kl_prior(log_x_start) + + return loss + + def kl_prior(self, log_x_start): + b = log_x_start.size(0) + device = log_x_start.device + ones = torch.ones(b, device=device).long() + + log_qxT_prob = self.q_pred(log_x_start, t=(self.num_timesteps - 1) * ones) + log_half_prob = -torch.log(self.num_classes_expanded * torch.ones_like(log_qxT_prob)) + + kl_prior = self.multinomial_kl(log_qxT_prob, log_half_prob) + return sum_except_batch(kl_prior) + + def compute_Lt(self, model_out, log_x_start, log_x_t, t, out_dict, detach_mean=False): + log_true_prob = self.q_posterior( + log_x_start=log_x_start, log_x_t=log_x_t, t=t) + log_model_prob = self.p_pred(model_out, log_x=log_x_t, t=t, out_dict=out_dict) + + if detach_mean: + log_model_prob = log_model_prob.detach() + + kl = self.multinomial_kl(log_true_prob, log_model_prob) + kl = sum_except_batch(kl) + + decoder_nll = -log_categorical(log_x_start, log_model_prob) + decoder_nll = sum_except_batch(decoder_nll) + + mask = (t == torch.zeros_like(t)).float() + loss = mask * decoder_nll + (1. - mask) * kl + + return loss + + def sample_time(self, b, device, method='uniform'): + if method == 'importance': + if not (self.Lt_count > 10).all(): + return self.sample_time(b, device, method='uniform') + + Lt_sqrt = torch.sqrt(self.Lt_history + 1e-10) + 0.0001 + Lt_sqrt[0] = Lt_sqrt[1] # Overwrite decoder term with L1. + pt_all = (Lt_sqrt / Lt_sqrt.sum()).to(device) + + t = torch.multinomial(pt_all, num_samples=b, replacement=True).to(device) + + pt = pt_all.gather(dim=0, index=t) + + return t, pt + + elif method == 'uniform': + t = torch.randint(0, self.num_timesteps, (b,), device=device).long() + + pt = torch.ones_like(t).float() / self.num_timesteps + return t, pt + else: + raise ValueError + + def _multinomial_loss(self, model_out, log_x_start, log_x_t, t, pt, out_dict): + + if self.multinomial_loss_type == 'vb_stochastic': + kl = self.compute_Lt( + model_out, log_x_start, log_x_t, t, out_dict + ) + kl_prior = self.kl_prior(log_x_start) + # Upweigh loss term of the kl + vb_loss = kl / pt + kl_prior + + return vb_loss + + elif self.multinomial_loss_type == 'vb_all': + # Expensive, dont do it ;). + # DEPRECATED + return -self.nll(log_x_start) + else: + raise ValueError() + + def log_prob(self, x, out_dict): + b, device = x.size(0), x.device + if self.training: + return self._multinomial_loss(x, out_dict) + + else: + log_x_start = index_to_log_onehot(x, self.num_classes) + + t, pt = self.sample_time(b, device, 'importance') + + kl = self.compute_Lt( + log_x_start, self.q_sample(log_x_start=log_x_start, t=t), t, out_dict) + + kl_prior = self.kl_prior(log_x_start) + + # Upweigh loss term of the kl + loss = kl / pt + kl_prior + + return -loss + + def mixed_loss(self, x, out_dict): + b = x.shape[0] + device = x.device + t, pt = self.sample_time(b, device, 'uniform') + + x_num = x[:, :self.num_numerical_features] + x_cat = x[:, self.num_numerical_features:] + + x_num_t = x_num + log_x_cat_t = x_cat + if x_num.shape[1] > 0: + noise = torch.randn_like(x_num) + x_num_t = self.gaussian_q_sample(x_num, t, noise=noise) + if x_cat.shape[1] > 0: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes) + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t) + + x_in = torch.cat([x_num_t, log_x_cat_t], dim=1) + + model_out = self._denoise_fn( + x_in, + t, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + loss_multi = torch.zeros((1,)).float() + loss_gauss = torch.zeros((1,)).float() + if x_cat.shape[1] > 0: + loss_multi = self._multinomial_loss(model_out_cat, log_x_cat, log_x_cat_t, t, pt, out_dict) / len(self.num_classes) + + if x_num.shape[1] > 0: + loss_gauss = self._gaussian_loss(model_out_num, x_num, x_num_t, t, noise) + + # loss_multi = torch.where(out_dict['y'] == 1, loss_multi, 2 * loss_multi) + # loss_gauss = torch.where(out_dict['y'] == 1, loss_gauss, 2 * loss_gauss) + + return loss_multi.mean(), loss_gauss.mean() + + @torch.no_grad() + def mixed_elbo(self, x0, out_dict): + b = x0.size(0) + device = x0.device + + x_num = x0[:, :self.num_numerical_features] + x_cat = x0[:, self.num_numerical_features:] + has_cat = x_cat.shape[1] > 0 + if has_cat: + log_x_cat = index_to_log_onehot(x_cat.long(), self.num_classes).to(device) + + gaussian_loss = [] + xstart_mse = [] + mse = [] + mu_mse = [] + out_mean = [] + true_mean = [] + multinomial_loss = [] + for t in range(self.num_timesteps): + t_array = (torch.ones(b, device=device) * t).long() + noise = torch.randn_like(x_num) + + x_num_t = self.gaussian_q_sample(x_start=x_num, t=t_array, noise=noise) + if has_cat: + log_x_cat_t = self.q_sample(log_x_start=log_x_cat, t=t_array) + else: + log_x_cat_t = x_cat + + model_out = self._denoise_fn( + torch.cat([x_num_t, log_x_cat_t], dim=1), + t_array, + **out_dict + ) + + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + + kl = torch.tensor([0.0]) + if has_cat: + kl = self.compute_Lt( + model_out=model_out_cat, + log_x_start=log_x_cat, + log_x_t=log_x_cat_t, + t=t_array, + out_dict=out_dict + ) + + out = self._vb_terms_bpd( + model_out_num, + x_start=x_num, + x_t=x_num_t, + t=t_array, + clip_denoised=False + ) + + multinomial_loss.append(kl) + gaussian_loss.append(out["output"]) + xstart_mse.append(mean_flat((out["pred_xstart"] - x_num) ** 2)) + # mu_mse.append(mean_flat(out["mean_mse"])) + out_mean.append(mean_flat(out["out_mean"])) + true_mean.append(mean_flat(out["true_mean"])) + + eps = self._predict_eps_from_xstart(x_num_t, t_array, out["pred_xstart"]) + mse.append(mean_flat((eps - noise) ** 2)) + + gaussian_loss = torch.stack(gaussian_loss, dim=1) + multinomial_loss = torch.stack(multinomial_loss, dim=1) + xstart_mse = torch.stack(xstart_mse, dim=1) + mse = torch.stack(mse, dim=1) + # mu_mse = torch.stack(mu_mse, dim=1) + out_mean = torch.stack(out_mean, dim=1) + true_mean = torch.stack(true_mean, dim=1) + + + + prior_gauss = self._prior_gaussian(x_num) + + prior_multin = torch.tensor([0.0]) + if has_cat: + prior_multin = self.kl_prior(log_x_cat) + + total_gauss = gaussian_loss.sum(dim=1) + prior_gauss + total_multin = multinomial_loss.sum(dim=1) + prior_multin + return { + "total_gaussian": total_gauss, + "total_multinomial": total_multin, + "losses_gaussian": gaussian_loss, + "losses_multinimial": multinomial_loss, + "xstart_mse": xstart_mse, + "mse": mse, + # "mu_mse": mu_mse + "out_mean": out_mean, + "true_mean": true_mean + } + + @torch.no_grad() + def gaussian_ddim_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + denoised_fn=None, + eta=0.0 + ): + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=denoised_fn, + model_kwargs=None, + ) + + eps = self._predict_eps_from_xstart(x, t, out["pred_xstart"]) + + alpha_bar = extract(self.alphas_cumprod, t, x.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, x.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + noise = torch.randn_like(x) + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_prev) + + torch.sqrt(1 - alpha_bar_prev - sigma ** 2) * eps + ) + nonzero_mask = ( + (t != 0).float().view(-1, *([1] * (len(x.shape) - 1))) + ) # no noise when t == 0 + sample = mean_pred + nonzero_mask * sigma * noise + + return sample + + @torch.no_grad() + def gaussian_ddim_sample( + self, + noise, + T, + out_dict, + eta=0.0 + ): + x = noise + b = x.shape[0] + device = x.device + for t in reversed(range(T)): + print(f'Sample timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_step( + out_num, + x, + t_array + ) + print() + return x + + + @torch.no_grad() + def gaussian_ddim_reverse_step( + self, + model_out_num, + x, + t, + clip_denoised=False, + eta=0.0 + ): + assert eta == 0.0, "Eta must be zero." + out = self.gaussian_p_mean_variance( + model_out_num, + x, + t, + clip_denoised=clip_denoised, + denoised_fn=None, + model_kwargs=None, + ) + + eps = ( + extract(self.sqrt_recip_alphas_cumprod, t, x.shape) * x + - out["pred_xstart"] + ) / extract(self.sqrt_recipm1_alphas_cumprod, t, x.shape) + alpha_bar_next = extract(self.alphas_cumprod_next, t, x.shape) + + mean_pred = ( + out["pred_xstart"] * torch.sqrt(alpha_bar_next) + + torch.sqrt(1 - alpha_bar_next) * eps + ) + + return mean_pred + + @torch.no_grad() + def gaussian_ddim_reverse_sample( + self, + x, + T, + out_dict, + ): + b = x.shape[0] + device = x.device + for t in range(T): + print(f'Reverse timestep {t:4d}', end='\r') + t_array = (torch.ones(b, device=device) * t).long() + out_num = self._denoise_fn(x, t_array, **out_dict) + x = self.gaussian_ddim_reverse_step( + out_num, + x, + t_array, + eta=0.0 + ) + print() + + return x + + + @torch.no_grad() + def multinomial_ddim_step( + self, + model_out_cat, + log_x_t, + t, + out_dict, + eta=0.0 + ): + # not ddim, essentially + log_x0 = self.predict_start(model_out_cat, log_x_t=log_x_t, t=t, out_dict=out_dict) + + alpha_bar = extract(self.alphas_cumprod, t, log_x_t.shape) + alpha_bar_prev = extract(self.alphas_cumprod_prev, t, log_x_t.shape) + sigma = ( + eta + * torch.sqrt((1 - alpha_bar_prev) / (1 - alpha_bar)) + * torch.sqrt(1 - alpha_bar / alpha_bar_prev) + ) + + coef1 = sigma + coef2 = alpha_bar_prev - sigma * alpha_bar + coef3 = 1 - coef1 - coef2 + + + log_ps = torch.stack([ + torch.log(coef1) + log_x_t, + torch.log(coef2) + log_x0, + torch.log(coef3) - torch.log(self.num_classes_expanded) + ], dim=2) + + log_prob = torch.logsumexp(log_ps, dim=2) + + out = self.log_sample_categorical(log_prob) + + return out + + @torch.no_grad() + def sample_ddim(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_ddim_step(model_out_num, z_norm, t, clip_denoised=False) + if has_cat: + log_z = self.multinomial_ddim_step(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + + @torch.no_grad() + def sample(self, num_samples, y_dist): + b = num_samples + device = self.log_alpha.device + z_norm = torch.randn((b, self.num_numerical_features), device=device) + + has_cat = self.num_classes[0] != 0 + log_z = torch.zeros((b, 0), device=device).float() + if has_cat: + uniform_logits = torch.zeros((b, len(self.num_classes_expanded)), device=device) + log_z = self.log_sample_categorical(uniform_logits) + + y = torch.multinomial( + y_dist, + num_samples=b, + replacement=True + ) + out_dict = {'y': y.long().to(device)} + for i in reversed(range(0, self.num_timesteps)): + print(f'Sample timestep {i:4d}', end='\r') + t = torch.full((b,), i, device=device, dtype=torch.long) + model_out = self._denoise_fn( + torch.cat([z_norm, log_z], dim=1).float(), + t, + **out_dict + ) + model_out_num = model_out[:, :self.num_numerical_features] + model_out_cat = model_out[:, self.num_numerical_features:] + z_norm = self.gaussian_p_sample(model_out_num, z_norm, t, clip_denoised=False)['sample'] + if has_cat: + log_z = self.p_sample(model_out_cat, log_z, t, out_dict) + + print() + z_ohe = torch.exp(log_z).round() + z_cat = log_z + if has_cat: + z_cat = ohe_to_categories(z_ohe, self.num_classes) + sample = torch.cat([z_norm, z_cat], dim=1).cpu() + return sample, out_dict + + def sample_all(self, num_samples, batch_size, y_dist, ddim=False): + if ddim: + print('Sample using DDIM.') + sample_fn = self.sample_ddim + else: + sample_fn = self.sample + + b = batch_size + + all_y = [] + all_samples = [] + num_generated = 0 + while num_generated < num_samples: + sample, out_dict = sample_fn(b, y_dist) + mask_nan = torch.any(sample.isnan(), dim=1) + sample = sample[~mask_nan] + out_dict['y'] = out_dict['y'][~mask_nan] + + all_samples.append(sample) + all_y.append(out_dict['y'].cpu()) + if sample.shape[0] != b: + raise FoundNANsError + num_generated += sample.shape[0] + + x_gen = torch.cat(all_samples, dim=0)[:num_samples] + y_gen = torch.cat(all_y, dim=0)[:num_samples] + + return x_gen, y_gen \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/modules.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/modules.py new file mode 100644 index 0000000000000000000000000000000000000000..472ba5b5f44b646e83d429f0d6272a8fe6d7130d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/modules.py @@ -0,0 +1,486 @@ +""" +Code was adapted from https://github.com/Yura52/rtdl +""" + +import math +from typing import Any, Callable, Dict, List, Optional, Tuple, Type, Union, cast + +import torch +import torch.nn as nn +import torch.nn.functional as F +import torch.optim +from torch import Tensor + +ModuleType = Union[str, Callable[..., nn.Module]] + +class SiLU(nn.Module): + def forward(self, x): + return x * torch.sigmoid(x) + +def timestep_embedding(timesteps, dim, max_period=10000): + """ + Create sinusoidal timestep embeddings. + + :param timesteps: a 1-D Tensor of N indices, one per batch element. + These may be fractional. + :param dim: the dimension of the output. + :param max_period: controls the minimum frequency of the embeddings. + :return: an [N x dim] Tensor of positional embeddings. + """ + half = dim // 2 + freqs = torch.exp( + -math.log(max_period) * torch.arange(start=0, end=half, dtype=torch.float32) / half + ).to(device=timesteps.device) + args = timesteps[:, None].float() * freqs[None] + embedding = torch.cat([torch.cos(args), torch.sin(args)], dim=-1) + if dim % 2: + embedding = torch.cat([embedding, torch.zeros_like(embedding[:, :1])], dim=-1) + return embedding + +def _is_glu_activation(activation: ModuleType): + return ( + isinstance(activation, str) + and activation.endswith('GLU') + or activation in [ReGLU, GEGLU] + ) + + +def _all_or_none(values): + assert all(x is None for x in values) or all(x is not None for x in values) + +def reglu(x: Tensor) -> Tensor: + """The ReGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.relu(b) + + +def geglu(x: Tensor) -> Tensor: + """The GEGLU activation function from [1]. + References: + [1] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + assert x.shape[-1] % 2 == 0 + a, b = x.chunk(2, dim=-1) + return a * F.gelu(b) + +class ReGLU(nn.Module): + """The ReGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = ReGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return reglu(x) + + +class GEGLU(nn.Module): + """The GEGLU activation function from [shazeer2020glu]. + + Examples: + .. testcode:: + + module = GEGLU() + x = torch.randn(3, 4) + assert module(x).shape == (3, 2) + + References: + * [shazeer2020glu] Noam Shazeer, "GLU Variants Improve Transformer", 2020 + """ + + def forward(self, x: Tensor) -> Tensor: + return geglu(x) + +def _make_nn_module(module_type: ModuleType, *args) -> nn.Module: + return ( + ( + ReGLU() + if module_type == 'ReGLU' + else GEGLU() + if module_type == 'GEGLU' + else getattr(nn, module_type)(*args) + ) + if isinstance(module_type, str) + else module_type(*args) + ) + + +class MLP(nn.Module): + """The MLP model used in [gorishniy2021revisiting]. + + The following scheme describes the architecture: + + .. code-block:: text + + MLP: (in) -> Block -> ... -> Block -> Linear -> (out) + Block: (in) -> Linear -> Activation -> Dropout -> (out) + + Examples: + .. testcode:: + + x = torch.randn(4, 2) + module = MLP.make_baseline(x.shape[1], [3, 5], 0.1, 1) + assert module(x).shape == (len(x), 1) + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `MLP`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + activation: ModuleType, + dropout: float, + ) -> None: + super().__init__() + self.linear = nn.Linear(d_in, d_out, bias) + self.activation = _make_nn_module(activation) + self.dropout = nn.Dropout(dropout) + + def forward(self, x: Tensor) -> Tensor: + return self.dropout(self.activation(self.linear(x))) + + def __init__( + self, + *, + d_in: int, + d_layers: List[int], + dropouts: Union[float, List[float]], + activation: Union[str, Callable[[], nn.Module]], + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + if isinstance(dropouts, float): + dropouts = [dropouts] * len(d_layers) + assert len(d_layers) == len(dropouts) + assert activation not in ['ReGLU', 'GEGLU'] + + self.blocks = nn.ModuleList( + [ + MLP.Block( + d_in=d_layers[i - 1] if i else d_in, + d_out=d, + bias=True, + activation=activation, + dropout=dropout, + ) + for i, (d, dropout) in enumerate(zip(d_layers, dropouts)) + ] + ) + self.head = nn.Linear(d_layers[-1] if d_layers else d_in, d_out) + + @classmethod + def make_baseline( + cls: Type['MLP'], + d_in: int, + d_layers: List[int], + dropout: float, + d_out: int, + ) -> 'MLP': + """Create a "baseline" `MLP`. + + This variation of MLP was used in [gorishniy2021revisiting]. Features: + + * :code:`Activation` = :code:`ReLU` + * all linear layers except for the first one and the last one are of the same dimension + * the dropout rate is the same for all dropout layers + + Args: + d_in: the input size + d_layers: the dimensions of the linear layers. If there are more than two + layers, then all of them except for the first and the last ones must + have the same dimension. Valid examples: :code:`[]`, :code:`[8]`, + :code:`[8, 16]`, :code:`[2, 2, 2, 2]`, :code:`[1, 2, 2, 4]`. Invalid + example: :code:`[1, 2, 3, 4]`. + dropout: the dropout rate for all hidden layers + d_out: the output size + Returns: + MLP + + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + assert isinstance(dropout, float) + if len(d_layers) > 2: + assert len(set(d_layers[1:-1])) == 1, ( + 'if d_layers contains more than two elements, then' + ' all elements except for the first and the last ones must be equal.' + ) + return MLP( + d_in=d_in, + d_layers=d_layers, # type: ignore + dropouts=dropout, + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + for block in self.blocks: + x = block(x) + x = self.head(x) + return x + + +class ResNet(nn.Module): + """The ResNet model used in [gorishniy2021revisiting]. + The following scheme describes the architecture: + .. code-block:: text + ResNet: (in) -> Linear -> Block -> ... -> Block -> Head -> (out) + |-> Norm -> Linear -> Activation -> Dropout -> Linear -> Dropout ->| + | | + Block: (in) ------------------------------------------------------------> Add -> (out) + Head: (in) -> Norm -> Activation -> Linear -> (out) + Examples: + .. testcode:: + x = torch.randn(4, 2) + module = ResNet.make_baseline( + d_in=x.shape[1], + n_blocks=2, + d_main=3, + d_hidden=4, + dropout_first=0.25, + dropout_second=0.0, + d_out=1 + ) + assert module(x).shape == (len(x), 1) + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + + class Block(nn.Module): + """The main building block of `ResNet`.""" + + def __init__( + self, + *, + d_main: int, + d_hidden: int, + bias_first: bool, + bias_second: bool, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + skip_connection: bool, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_main) + self.linear_first = nn.Linear(d_main, d_hidden, bias_first) + self.activation = _make_nn_module(activation) + self.dropout_first = nn.Dropout(dropout_first) + self.linear_second = nn.Linear(d_hidden, d_main, bias_second) + self.dropout_second = nn.Dropout(dropout_second) + self.skip_connection = skip_connection + + def forward(self, x: Tensor) -> Tensor: + x_input = x + x = self.normalization(x) + x = self.linear_first(x) + x = self.activation(x) + x = self.dropout_first(x) + x = self.linear_second(x) + x = self.dropout_second(x) + if self.skip_connection: + x = x_input + x + return x + + class Head(nn.Module): + """The final module of `ResNet`.""" + + def __init__( + self, + *, + d_in: int, + d_out: int, + bias: bool, + normalization: ModuleType, + activation: ModuleType, + ) -> None: + super().__init__() + self.normalization = _make_nn_module(normalization, d_in) + self.activation = _make_nn_module(activation) + self.linear = nn.Linear(d_in, d_out, bias) + + def forward(self, x: Tensor) -> Tensor: + if self.normalization is not None: + x = self.normalization(x) + x = self.activation(x) + x = self.linear(x) + return x + + def __init__( + self, + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + normalization: ModuleType, + activation: ModuleType, + d_out: int, + ) -> None: + """ + Note: + `make_baseline` is the recommended constructor. + """ + super().__init__() + + self.first_layer = nn.Linear(d_in, d_main) + if d_main is None: + d_main = d_in + self.blocks = nn.Sequential( + *[ + ResNet.Block( + d_main=d_main, + d_hidden=d_hidden, + bias_first=True, + bias_second=True, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization=normalization, + activation=activation, + skip_connection=True, + ) + for _ in range(n_blocks) + ] + ) + self.head = ResNet.Head( + d_in=d_main, + d_out=d_out, + bias=True, + normalization=normalization, + activation=activation, + ) + + @classmethod + def make_baseline( + cls: Type['ResNet'], + *, + d_in: int, + n_blocks: int, + d_main: int, + d_hidden: int, + dropout_first: float, + dropout_second: float, + d_out: int, + ) -> 'ResNet': + """Create a "baseline" `ResNet`. + This variation of ResNet was used in [gorishniy2021revisiting]. Features: + * :code:`Activation` = :code:`ReLU` + * :code:`Norm` = :code:`BatchNorm1d` + Args: + d_in: the input size + n_blocks: the number of Blocks + d_main: the input size (or, equivalently, the output size) of each Block + d_hidden: the output size of the first linear layer in each Block + dropout_first: the dropout rate of the first dropout layer in each Block. + dropout_second: the dropout rate of the second dropout layer in each Block. + References: + * [gorishniy2021revisiting] Yury Gorishniy, Ivan Rubachev, Valentin Khrulkov, Artem Babenko, "Revisiting Deep Learning Models for Tabular Data", 2021 + """ + return cls( + d_in=d_in, + n_blocks=n_blocks, + d_main=d_main, + d_hidden=d_hidden, + dropout_first=dropout_first, + dropout_second=dropout_second, + normalization='BatchNorm1d', + activation='ReLU', + d_out=d_out, + ) + + def forward(self, x: Tensor) -> Tensor: + x = x.float() + x = self.first_layer(x) + x = self.blocks(x) + x = self.head(x) + return x +#### For diffusion + +class MLPDiffusion(nn.Module): + def __init__(self, d_in, num_classes, is_y_cond, rtdl_params, dim_t = 128): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + self.is_y_cond = is_y_cond + + # d0 = rtdl_params['d_layers'][0] + + rtdl_params['d_in'] = dim_t + rtdl_params['d_out'] = d_in + + self.mlp = MLP.make_baseline(**rtdl_params) + + if self.num_classes > 0 and is_y_cond: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + elif self.num_classes == 0 and is_y_cond: + self.label_emb = nn.Linear(1, dim_t) + + self.proj = nn.Linear(d_in, dim_t) + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if self.is_y_cond and y is not None: + if self.num_classes > 0: + y = y.squeeze() + else: + y = y.resize(y.size(0), 1).float() + emb += F.silu(self.label_emb(y)) + x = self.proj(x) + emb + return self.mlp(x) + +class ResNetDiffusion(nn.Module): + def __init__(self, d_in, num_classes, rtdl_params, dim_t = 256): + super().__init__() + self.dim_t = dim_t + self.num_classes = num_classes + + rtdl_params['d_in'] = d_in + rtdl_params['d_out'] = d_in + rtdl_params['emb_d'] = dim_t + self.resnet = ResNet.make_baseline(**rtdl_params) + + if self.num_classes > 0: + self.label_emb = nn.Embedding(self.num_classes, dim_t) + + self.time_embed = nn.Sequential( + nn.Linear(dim_t, dim_t), + nn.SiLU(), + nn.Linear(dim_t, dim_t) + ) + + def forward(self, x, timesteps, y=None): + emb = self.time_embed(timestep_embedding(timesteps, self.dim_t)) + if y is not None and self.num_classes > 0: + emb += self.label_emb(y.squeeze()) + return self.resnet(x, emb) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/utils.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/utils.py new file mode 100644 index 0000000000000000000000000000000000000000..6376bfbfb6971c3e465fafe9d56320d92a5f508a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/utils.py @@ -0,0 +1,174 @@ +import torch +import numpy as np +import torch.nn.functional as F +from torch.profiler import record_function +from inspect import isfunction + +def normal_kl(mean1, logvar1, mean2, logvar2): + """ + Compute the KL divergence between two gaussians. + + Shapes are automatically broadcasted, so batches can be compared to + scalars, among other use cases. + """ + tensor = None + for obj in (mean1, logvar1, mean2, logvar2): + if isinstance(obj, torch.Tensor): + tensor = obj + break + assert tensor is not None, "at least one argument must be a Tensor" + + # Force variances to be Tensors. Broadcasting helps convert scalars to + # Tensors, but it does not work for torch.exp(). + logvar1, logvar2 = [ + x if isinstance(x, torch.Tensor) else torch.tensor(x).to(tensor) + for x in (logvar1, logvar2) + ] + + return 0.5 * ( + -1.0 + + logvar2 + - logvar1 + + torch.exp(logvar1 - logvar2) + + ((mean1 - mean2) ** 2) * torch.exp(-logvar2) + ) + +def approx_standard_normal_cdf(x): + """ + A fast approximation of the cumulative distribution function of the + standard normal. + """ + return 0.5 * (1.0 + torch.tanh(np.sqrt(2.0 / np.pi) * (x + 0.044715 * torch.pow(x, 3)))) + + +def discretized_gaussian_log_likelihood(x, *, means, log_scales): + """ + Compute the log-likelihood of a Gaussian distribution discretizing to a + given image. + + :param x: the target images. It is assumed that this was uint8 values, + rescaled to the range [-1, 1]. + :param means: the Gaussian mean Tensor. + :param log_scales: the Gaussian log stddev Tensor. + :return: a tensor like x of log probabilities (in nats). + """ + assert x.shape == means.shape == log_scales.shape + centered_x = x - means + inv_stdv = torch.exp(-log_scales) + plus_in = inv_stdv * (centered_x + 1.0 / 255.0) + cdf_plus = approx_standard_normal_cdf(plus_in) + min_in = inv_stdv * (centered_x - 1.0 / 255.0) + cdf_min = approx_standard_normal_cdf(min_in) + log_cdf_plus = torch.log(cdf_plus.clamp(min=1e-12)) + log_one_minus_cdf_min = torch.log((1.0 - cdf_min).clamp(min=1e-12)) + cdf_delta = cdf_plus - cdf_min + log_probs = torch.where( + x < -0.999, + log_cdf_plus, + torch.where(x > 0.999, log_one_minus_cdf_min, torch.log(cdf_delta.clamp(min=1e-12))), + ) + assert log_probs.shape == x.shape + return log_probs + +def sum_except_batch(x, num_dims=1): + ''' + Sums all dimensions except the first. + + Args: + x: Tensor, shape (batch_size, ...) + num_dims: int, number of batch dims (default=1) + + Returns: + x_sum: Tensor, shape (batch_size,) + ''' + return x.reshape(*x.shape[:num_dims], -1).sum(-1) + +def mean_flat(tensor): + """ + Take the mean over all non-batch dimensions. + """ + return tensor.mean(dim=list(range(1, len(tensor.shape)))) + +def ohe_to_categories(ohe, K): + K = torch.from_numpy(K) + indices = torch.cat([torch.zeros((1,)), K.cumsum(dim=0)], dim=0).int().tolist() + res = [] + for i in range(len(indices) - 1): + res.append(ohe[:, indices[i]:indices[i+1]].argmax(dim=1)) + return torch.stack(res, dim=1) + +def log_1_min_a(a): + return torch.log(1 - a.exp() + 1e-40) + + +def log_add_exp(a, b): + maximum = torch.max(a, b) + return maximum + torch.log(torch.exp(a - maximum) + torch.exp(b - maximum)) + +def exists(x): + return x is not None + +def extract(a, t, x_shape): + b, *_ = t.shape + t = t.to(a.device) + out = a.gather(-1, t) + while len(out.shape) < len(x_shape): + out = out[..., None] + return out.expand(x_shape) + +def default(val, d): + if exists(val): + return val + return d() if isfunction(d) else d + +def log_categorical(log_x_start, log_prob): + return (log_x_start.exp() * log_prob).sum(dim=1) + +def index_to_log_onehot(x, num_classes): + onehots = [] + for i in range(len(num_classes)): + onehots.append(F.one_hot(x[:, i], num_classes[i])) + + x_onehot = torch.cat(onehots, dim=1) + log_onehot = torch.log(x_onehot.float().clamp(min=1e-30)) + return log_onehot + +def log_sum_exp_by_classes(x, slices): + device = x.device + res = torch.zeros_like(x) + for ixs in slices: + res[:, ixs] = torch.logsumexp(x[:, ixs], dim=1, keepdim=True) + + assert x.size() == res.size() + + return res + +@torch.jit.script +def log_sub_exp(a: torch.Tensor, b: torch.Tensor) -> torch.Tensor: + m = torch.maximum(a, b) + return torch.log(torch.exp(a - m) - torch.exp(b - m)) + m + +@torch.jit.script +def sliced_logsumexp(x, slices): + lse = torch.logcumsumexp( + torch.nn.functional.pad(x, [1, 0, 0, 0], value=-float('inf')), + dim=-1) + + slice_starts = slices[:-1] + slice_ends = slices[1:] + + slice_lse = log_sub_exp(lse[:, slice_ends], lse[:, slice_starts]) + slice_lse_repeated = torch.repeat_interleave( + slice_lse, + slice_ends - slice_starts, + dim=-1 + ) + return slice_lse_repeated + +def log_onehot_to_index(log_x): + return log_x.argmax(1) + +class FoundNANsError(BaseException): + """Found NANs during sampling""" + def __init__(self, message='Found NANs during sampling.'): + super(FoundNANsError, self).__init__(message) \ No newline at end of file diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/convert_synth_to_csv.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/convert_synth_to_csv.py new file mode 100644 index 0000000000000000000000000000000000000000..be1bb6180758714a938e9c5c73a51029523e20f0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/convert_synth_to_csv.py @@ -0,0 +1,89 @@ +#!/usr/bin/env python3 +""" +Convert generated synthetic data from npy files to CSV format. +""" +import os +import sys +import numpy as np +import pandas as pd +import argparse + +def convert_to_csv(parent_dir, output_path=None): + """ + Convert generated synthetic data to CSV. + + Args: + parent_dir: Directory containing X_num_train.npy, X_cat_train.npy, y_train.npy + output_path: Output CSV file path (default: parent_dir/synth_train.csv) + """ + parent_dir = os.path.abspath(parent_dir) + + # Load npy files + x_num_path = os.path.join(parent_dir, 'X_num_train.npy') + x_cat_path = os.path.join(parent_dir, 'X_cat_train.npy') + y_path = os.path.join(parent_dir, 'y_train.npy') + + data_parts = [] + column_names = [] + + # Load numerical features + if os.path.exists(x_num_path): + X_num = np.load(x_num_path, allow_pickle=True) + print(f"Loaded X_num: shape {X_num.shape}") + data_parts.append(X_num) + # Create column names for numerical features + for i in range(X_num.shape[1]): + column_names.append(f'num_{i}') + + # Load categorical features + if os.path.exists(x_cat_path): + X_cat = np.load(x_cat_path, allow_pickle=True) + print(f"Loaded X_cat: shape {X_cat.shape}") + data_parts.append(X_cat) + # Create column names for categorical features + for i in range(X_cat.shape[1]): + column_names.append(f'cat_{i}') + + # Load target + if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + print(f"Loaded y: shape {y.shape}") + # Reshape if needed + if y.ndim == 1: + y = y.reshape(-1, 1) + data_parts.append(y) + column_names.append('y') + + if not data_parts: + raise ValueError(f"No data files found in {parent_dir}") + + # Concatenate all parts + data = np.hstack(data_parts) + print(f"Combined data shape: {data.shape}") + print(f"Number of columns: {len(column_names)}") + + # Create DataFrame + df = pd.DataFrame(data, columns=column_names) + + # Determine output path + if output_path is None: + output_path = os.path.join(parent_dir, 'synth_train.csv') + + # Save to CSV + df.to_csv(output_path, index=False) + print(f"[OK] Saved synthetic data to: {output_path}") + print(f"[OK] Total samples: {len(df)}, Total columns: {len(df.columns)}") + + # Print summary statistics + print("\n=== Data Summary ===") + print(df.describe()) + + return output_path + +if __name__ == '__main__': + parser = argparse.ArgumentParser(description='Convert synthetic npy files to CSV') + parser.add_argument('parent_dir', type=str, help='Directory containing generated npy files') + parser.add_argument('--output', '-o', type=str, default=None, help='Output CSV file path (default: parent_dir/synth_train.csv)') + + args = parser.parse_args() + convert_to_csv(args.parent_dir, args.output) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/make_tabddpm_info.py b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/make_tabddpm_info.py new file mode 100644 index 0000000000000000000000000000000000000000..30acf64d04521bfa8fc1810c893395eed5bd57a4 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tools/make_tabddpm_info.py @@ -0,0 +1,97 @@ +import os, json +import numpy as np + +def load(path): + return np.load(path, allow_pickle=True) + +def main(data_dir: str): + # required files + req = [ + "X_num_train.npy","X_num_val.npy","X_num_test.npy", + "X_cat_train.npy","X_cat_val.npy","X_cat_test.npy", + "y_train.npy","y_val.npy","y_test.npy" + ] + for f in req: + p = os.path.join(data_dir, f) + if not os.path.exists(p): + raise FileNotFoundError(p) + + Xn_tr = load(os.path.join(data_dir,"X_num_train.npy")) + Xc_tr = load(os.path.join(data_dir,"X_cat_train.npy")) + y_tr = load(os.path.join(data_dir,"y_train.npy")) + + # basic dims + n_num = 0 if Xn_tr.ndim < 2 else int(Xn_tr.shape[1]) + n_cat = 0 if Xc_tr.ndim < 2 else int(Xc_tr.shape[1]) + + # infer task / y info + y_flat = y_tr.reshape(-1) + uniq = np.unique(y_flat) + # if y is integer and has few unique values, could be classification + is_int = np.issubdtype(y_flat.dtype, np.integer) + num_classes = int(len(uniq)) if is_int else 0 + + # determine task_type + if is_int and num_classes == 2: + task_type = "binclass" + elif is_int and num_classes > 2 and num_classes <= 100: + task_type = "multiclass" + else: + task_type = "regression" + + # cat sizes (per categorical column) + cat_sizes = [] + if n_cat > 0: + # compute max+1 per column (assume categories encoded 0..K-1) + for j in range(n_cat): + col = Xc_tr[:, j].reshape(-1) + if col.size == 0: + cat_sizes.append(0) + else: + mx = int(np.max(col)) + cat_sizes.append(mx + 1) + + # numeric stats (optional but useful) + num_stats = {} + if n_num > 0: + # mean/std/min/max over train numeric + num_stats = { + "mean": np.mean(Xn_tr, axis=0).tolist(), + "std": (np.std(Xn_tr, axis=0) + 1e-12).tolist(), + "min": np.min(Xn_tr, axis=0).tolist(), + "max": np.max(Xn_tr, axis=0).tolist(), + } + + # This repo expects info.json. Keep fields simple & robust. + info = { + "task_type": task_type, + "n_num_features": n_num, + "n_cat_features": n_cat, + "cat_sizes": cat_sizes, + "y_dtype": str(y_flat.dtype), + "y_unique_count": int(len(uniq)), + "y_unique_head": uniq[:20].tolist(), + # heuristics: user can override in config.toml + "is_classification_like": bool(is_int and len(uniq) <= 100), + "num_classes_like": num_classes, + } + + # write files + with open(os.path.join(data_dir, "info.json"), "w", encoding="utf-8") as f: + json.dump(info, f, ensure_ascii=False, indent=2) + + # some codepaths may look for these (harmless if unused) + with open(os.path.join(data_dir, "cat_sizes.json"), "w", encoding="utf-8") as f: + json.dump({"cat_sizes": cat_sizes}, f, ensure_ascii=False, indent=2) + + with open(os.path.join(data_dir, "num_stats.json"), "w", encoding="utf-8") as f: + json.dump(num_stats, f, ensure_ascii=False, indent=2) + + print("[OK] wrote:", os.path.join(data_dir,"info.json")) + print("[OK] n_num =", n_num, "n_cat =", n_cat, "cat_sizes =", cat_sizes) + print("[OK] y unique count =", len(uniq), "head =", uniq[:20]) + +if __name__ == "__main__": + data_dir = "data/Tab-Cate-1" + main(data_dir) + diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7641bbf14b10338ac870e2a999866a64a3e119fa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aad08aabbf726ab65389e42c3a524f407e6bc791edcb5af304c31ba9037f6c10 +size 351 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..51f7cdde4deeb5adf383c063ca60fe69af2092a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:956a488f34e502db9975d86ef25b75cf5c01c08a3e5a47c7ade4f72cbf11374c +size 432 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bc1fcb92e6fb025976224ef2fbf1335d1b1518a1 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4577f6d2af34360bff6faf7a01af5501463e8b13ff0fc0c18bf2bfa67c6c63b +size 393 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19e1861532e4b5e50495f5444496fb558f45e875 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0508cdc40c02386321976c9537fbe54a5f2b0fa0e8e7dde72a6d4d289ced862c +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7fc8cd71e630bcadef6c582f458d3e328dfc7024 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a411285e39c4cb685233ec73375cfd023fb834897dd6b5a8f99cf7a7ec1c6656 +size 403 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d646aac53ef0d8ad9f508fb14f561739d52441a9 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e4dea09bdea9006ce44f71eef0e1740f639eceff44dd021c351ece84a428a00a +size 380 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..53328b6729355daaba91f378caca2944b08dfb82 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb7ad47bb5b1c9fbe54cf14cc854581b22ed72f9dbc47f0a022e48fa572b5ffc +size 372 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..91aa99b5999ba8561744b73f036584956aa27735 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0d1265117a3d8688b7878c62656b6d85bb543e723b1f5f01a2ed5bd4b12878dc +size 335 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..8b118aadedc57bcea9ed8af0ac0318b17bd3850d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/fb-comments_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:18ccbc230cd0959834d3155e67c29d259af90720d29bc4284b3209df5374886e +size 519 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..39add46e4bb47ed0bb1e451e680788465aefa231 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:efa67605a7699adf3cd46bb7d7d5512516ab3e5da3e01451004aadf9ee4f9d62 +size 333 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6d0379ccd1631f30b7983ee0ed809a88c422aed2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4c67d2f9937dc5548b3c3a1ae71846e5fccc66853b8067670b979ff2a4f0201 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..9d636369299b13991976af26b6337be2c6c88494 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852eea0c2f88f7032cebc5dc7c9422be385d231f1ce8b5c9364a534d64fdf4f3 +size 332 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..0951c97fd762261760bf64abeee35635ac8b3277 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2201078a643eb78c649a3d4a9e897ecf39c2d7f35c5a9fdb055c91251694b808 +size 369 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..b95d7e8aecc468014085b8c0959aa9e7be64812c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a94473811e28035ef4781122c3da6e4f81b232b68a0042b64c30a1df648e02d3 +size 374 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..19ec2cc100638b21b99c87f453a4d6d356803ecb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:14dcf192aa15f491f147b30e2312b55889a146c546d72d89ee2d07ff26cc2103 +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..ea8143610c6a60053cbac687cb32b2c7b203ebc7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/catboost/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f6989397bf0029ee07b2ca9ab9335645ea3402bd6b782f2cec4cb40ad70b2ed +size 334 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..f497e044f1e3a1ffd35f852d285ab43b841e7fc2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/abalone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f99f28009311b8bb5413fbdbf72af25d1d384eec3c079c156e6a6eafa93e46bb +size 157 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/adult_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/adult_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..db818565ea71189907985b9a9424a41dec1b5261 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/adult_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1d4d4e1b062e420ce1838117b872e1794a632ea7f1dd8220eb640b71f793cd3a +size 229 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..d12f3fe28d7b352a4bb737f24abf65feb094b39a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/buddy_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bfe610df17eb46233b0dbba7fb71ea6117e9992763ae8ccd789159c296f3cc43 +size 165 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/california_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/california_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cb7256f2b264df6ee73bb260e84d4cafd983c2ad --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/california_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b9970d5c42859dce6fded5b3fb285bba98181076d8db75b8ef78e5e0167c7b0c +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..cfa75fad250058c3798cb53873aaef3e60289b3e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/cardio_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc9642d070f056675cd4d004c0b446576eb162e2819dec052325fe7da59ce85d +size 148 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..3e15732f32083afa27c5290d88430aab1fadf294 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/churn2_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ebea18b44a2d33a6643f283adf68961099d44d7e4f11e29148b501ddabb5894a +size 152 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/default_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/default_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..45eb9feca3f3f48f560a1c136037e0e83e9acda7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/default_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2d6082a82af0fb59906d778c57e4229eeff861066c1e24bea9c5e721f804214c +size 201 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..69cfdc546559ac76088c0ce9e2abea88323bcd09 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/diabetes_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:243a914fe90215cab4867d415cb82078366b5d2472264c91ea46d3e0e3291534 +size 147 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..27781e4df360af0c233babc28485990447ee59e8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/gesture_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3a819ad5093581e1b94eeddb0655b99cccce3bb121f405b0b7e3b230c3c1a11 +size 190 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..826c0e4d0b890d21ac21a2b6b9015d2e80b88b1f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/higgs-small_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3520fe130d4570aa07a79031b6016f31a4f36cd5fdc9ff7167f0c7e1768a6697 +size 230 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/house_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/house_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..5f13b453f1c8978346138fbfae950bc48f8f419a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/house_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:22f1903d9a59e6cc1df1a643b9bc216392fbb3549cb6555482898d4a7ac936aa +size 164 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..00d8f78622f81428c7c94021982ae59c8890fa84 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/insurance_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:381e76611b072a0fb5fa41a7c640740453293a6d0cda8210697d4b9833d715e4 +size 171 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/king_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/king_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..7c7fcaf8ef05cdad5022fb1430047318c48d2107 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/king_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:afbbb1a2be60833c9468ded47ba78228e5a00c42bed93681e4e2aa0c6b68278d +size 163 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..6a2fa20fe823c8adf1023a889e918326997a7b8a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/miniboone_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:896a60d6ce4628cacdf5a3ec5a4c70b9fcff7944e373082ca34a6b55d7c6871a +size 175 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json new file mode 100644 index 0000000000000000000000000000000000000000..bfd0c2cc0dc2b572be260a3ec20b74139efd885c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tuned_models/mlp/wilt_cv.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1489c33a341492905b3145370808bd2201a18fe8a1ae604df8917408821f57de +size 144 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/config.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..43ee3099541f832cc3311f458884b4d30fd6208e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/config.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:922a3210dba1e4254beb152bf1bb4a04aa625d8389d7c0386afa5864e33e03ca +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/info.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/info.json new file mode 100644 index 0000000000000000000000000000000000000000..d81ab6d13ff8932c1b47822a5508c046d9fd6f6b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce0d1648e7f4633f3c9aa6e2f8c5460ec86f01d4bfa155e977a71e9640744427 +size 51619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/loss.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/loss.csv new file mode 100644 index 0000000000000000000000000000000000000000..761e53a1ab2ec6281d1cfd7011c64221e0e14fcf --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/loss.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:31104b671dc50871390b6ecf82a5368e1f7cf3157fbdcf23c7ec93b0c42ef279 +size 113 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model.pt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model.pt new file mode 100644 index 0000000000000000000000000000000000000000..51a3dadbd6c6fe885bcc176bc9be6398c0c5dcb8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c756ff1a56a0fa1273eb8fa05957de2f68bbebe1a13ac8741e9023303ac0487 +size 5327574 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model_ema.pt b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model_ema.pt new file mode 100644 index 0000000000000000000000000000000000000000..7b836985e03a33c39574e2c304d273c1cee2990d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/output/model_ema.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a155d4d44c0a19c8fce10f4137fd98ddd2689b5d2f3c29e2971f3348dc8bd4c +size 5328418 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/public_gate_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..6149fd7e9072d46eb6a55463f7cfb6b244ea1c03 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86d39b3b6ac093a1fa21d725c03d64a5dc27d9f00f5d6d106fc6ad34225fa96a +size 658435 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/run_config.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..3e4057d7800ed75baf60ef193bbf43645ee4134b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f84f8fec6016d7ed6b56ee263886fb7fdd97b42bcc919db787af3b7513540509 +size 2297 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/runtime_result.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..65f5e6ea5499d0d185fcf14350ed0f033fc8f2b5 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a9291bbc49ce2492aa14498f934adad7aa9aa2e2f960d677a32a62ebd417f102 +size 1131 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/staged_features.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/test.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/train.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/val.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..1c719395d4a9c5b1f7f701828998aba9c248dbb3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8d5ed03151a0d2ceae98d1045651c2d34d8a27247c9c9f7ecd45ec5123650f70 +size 323 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_transforms_applied.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/model_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..5b93ad5e688d5f385a4c1278f3c2a54c884c6d7d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/staged/tabddpm/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1ae3b5ef43a4310679d59b4b5f7cdacecef46578efd44ead97f59b3e4f44cf57 +size 658634 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/train_20260511_031430.log b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/train_20260511_031430.log new file mode 100644 index 0000000000000000000000000000000000000000..74e8f212ded8025807a21524efaad90e67718350 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-20260511_031424/train_20260511_031430.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:215bb491ab0ba5c1ffd9fb7a2c36650ee2bec65cfc0f4ab7411491fe97f1c532 +size 661 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/input_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..ea0c7955c35965e09281e7ad72e7f9722a3d793b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:754197615fcbb84d31c0a54a0fd62ded7a78578807874b50d4c73f62b7e80ef5 +size 1367 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/public_gate_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..838799bb48adcdd8bd16f33b2962bbcc04a44d23 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:99fb372bac6f2ebbb0c06cfcecdd028b0498a0402bfc6ce7a30dd653c6a7e02b +size 658465 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/run_config.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..14891c7672897f77acc53bc49defe92ef5afec15 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dcb8d22bcdd9d2eee779c230bc9b6a290b8a80ff775157131d3b85582d28dfbf +size 2439 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/runtime_result.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..81621a196dbb608a7256bea03bace8e2bc8d2139 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0afff0b3b700b75b1d127cb21189869ff59188b3d8abaa9a1ec6de9ed94296f3 +size 637 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/staged_features.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/test.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/train.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/val.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..3a591d897fb1b5164193181387d94fa8f5d4208a --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8dd6896a004a49226bc4c062f0650f778cb91d1dd0822e6a5cf40d18e0f1ba0f +size 329 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_transforms_applied.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/model_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..73a3d2dcae2144229fb07e2024e506a9d7294e48 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen-20260511_044900/staged/tabddpm/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:52da7f1504055932722f1e6a2bf851b9d1122a1cb4e8d569b24ffbb9b247c8dc +size 658670 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r0.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r0.py new file mode 100644 index 0000000000000000000000000000000000000000..5a9cca13eb53e3e35803a4d7d0f63b87cccb34e3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r0.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r0.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r1.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r1.py new file mode 100644 index 0000000000000000000000000000000000000000..2ee1b6e78bc7f557d78df79ac7e369a1790eed18 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r1.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r1.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r2.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r2.py new file mode 100644 index 0000000000000000000000000000000000000000..3be23afa27c21cbb2cca16c1a079a9e6f3d1ed2d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r2.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r2.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r3.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r3.py new file mode 100644 index 0000000000000000000000000000000000000000..b99d049232e9b9c3a504a1b30bb5d2dd8fbdbffa --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r3.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r3.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r4.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r4.py new file mode 100644 index 0000000000000000000000000000000000000000..fd3a7c06c60b43d328589edc5022b66591b94a03 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r4.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r4.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r5.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r5.py new file mode 100644 index 0000000000000000000000000000000000000000..ab569022a5784f367e097920bd3380d0636bae11 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r5.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r5.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r6.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r6.py new file mode 100644 index 0000000000000000000000000000000000000000..a8812b7ed63e0a6c9c54de6c109d2c8e57117d6d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r6.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r6.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r7.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r7.py new file mode 100644 index 0000000000000000000000000000000000000000..b11664f88a94d05df898b2f86e7068c8b32241ac --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r7.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r7.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r8.py b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r8.py new file mode 100644 index 0000000000000000000000000000000000000000..e8e4ca27e458d59921687619911628c096b758a2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r8.py @@ -0,0 +1,75 @@ +import os, sys, subprocess, json +import numpy as np +import pandas as pd + +tabddpm_root = "/workspace/tabddpm/code" +runtime_root = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime" +assert os.path.isdir(tabddpm_root), f"TabDDPM source not mounted: {tabddpm_root}" + +if not os.path.exists(runtime_root): + def _ignore(_, names): + skip = {"__pycache__", "data", "synthetic", "result", "results", "ckpt"} + return [n for n in names if n in skip or n.endswith(".pyc")] + import shutil + shutil.copytree(tabddpm_root, runtime_root, ignore=_ignore) + +env = os.environ.copy() +env["PYTHONPATH"] = runtime_root + (os.pathsep + env.get("PYTHONPATH", "")) + +# Reuse the compat wrapper (patches collections.Sequence for skorch) +wrapper = os.path.join(runtime_root, "_compat_run.py") +if not os.path.exists(wrapper): + with open(wrapper, "w") as f: + f.write( + "import collections, collections.abc\n" + "for _a in ('Sequence','MutableSequence','MutableMapping','Mapping'," + "'MutableSet','Set','Callable','Iterable','Iterator'):\n" + " if not hasattr(collections, _a): setattr(collections, _a, getattr(collections.abc, _a, None))\n" + "import sys, runpy\n" + "sys.argv = sys.argv[1:]\n" + "runpy.run_path(sys.argv[0], run_name='__main__')\n" + ) + +print(f"[TabDDPM] Sampling 2623 rows") +ret = subprocess.run( + [sys.executable, wrapper, "scripts/pipeline.py", + "--config", "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r8.toml", + "--sample"], + cwd=runtime_root, + env=env +) +if ret.returncode != 0: + sys.exit(ret.returncode) + +# 将 .npy 输出转为 CSV(npy 在 TabDDPM 的 parent_dir,即 npy_dir) +info_path = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/data/info.json" +with open(info_path) as f: + info = json.load(f) + +output_dir = "/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output" +col_names = info.get("column_names", []) + +parts = [] +x_num_path = os.path.join(output_dir, "X_num_train.npy") +x_cat_path = os.path.join(output_dir, "X_cat_train.npy") +y_path = os.path.join(output_dir, "y_train.npy") + +if os.path.exists(x_num_path): + parts.append(np.load(x_num_path, allow_pickle=True)) +if os.path.exists(x_cat_path): + parts.append(np.load(x_cat_path, allow_pickle=True).astype(float)) +if os.path.exists(y_path): + y = np.load(y_path, allow_pickle=True) + parts.append(y.reshape(-1, 1) if y.ndim == 1 else y) + +if parts: + combined = np.concatenate(parts, axis=1) + if col_names and len(col_names) == combined.shape[1]: + df = pd.DataFrame(combined, columns=col_names) + else: + df = pd.DataFrame(combined) + df.to_csv("/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv", index=False) + print(f"[TabDDPM] Saved {len(df)} rows -> /work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm-c12-2623-20260511_051616.csv") +else: + print("[TabDDPM] WARNING: No output .npy files found") + sys.exit(1) diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r0.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r0.toml new file mode 100644 index 0000000000000000000000000000000000000000..ceabce068da10960059994dbdc108dd5fde49265 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r0.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9ca8d796f51ec359e1b7bda28569e66b44f3c74044ea0d857eac526b5d5fac7e +size 776 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r1.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r1.toml new file mode 100644 index 0000000000000000000000000000000000000000..0b2998703d235d033b4ddc4dcd01863d9d6cebee --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r1.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:552343fb1ddf1e3d78d6b3ceb53080e2bd36f02f235652b80a86cc33c0c5af96 +size 775 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r2.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r2.toml new file mode 100644 index 0000000000000000000000000000000000000000..268e81cde484f414249b4bed18f2296896296911 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r2.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6673cf9e29e01324d7ac39d34990686e3d00bdcc524bad5be42d212ca745cd86 +size 774 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r3.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r3.toml new file mode 100644 index 0000000000000000000000000000000000000000..abedf8e5b80db19f41b371de1847ce8e3c84c9e2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r3.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9712b2066755012f36a9af0495fca9c3d25fde797a1f4fe5383413ca0e428214 +size 774 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r4.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r4.toml new file mode 100644 index 0000000000000000000000000000000000000000..246acf1c2e718c490b6c704f00a6ec9ff92c8da2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r4.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9708704e8db2c1ff05365b574218f1a1403eac59a0ab625da5ad72f5b1cd1b1a +size 773 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r5.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r5.toml new file mode 100644 index 0000000000000000000000000000000000000000..2652196a24d9fd4dafa2903548fc244bc000590c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r5.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:021200f8e406bb241258bd0fe78fa0ecd7ef433fb3066c6d62bf773dd0132c6c +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r6.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r6.toml new file mode 100644 index 0000000000000000000000000000000000000000..7b5032b438de111153df34ac268e671cdba24326 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r6.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8096a012e2b8c7d3ee5a66817aa21c9e9a82920b60a9e9e4818a6bb1fe60df15 +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r7.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r7.toml new file mode 100644 index 0000000000000000000000000000000000000000..51819759db158d5f9ad57b0f05743cf23ee58a9d --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r7.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa9287074ba7fa41fa656190a24b544331a0f756c35aaee4ba83aebf2ded968a +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r8.toml b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r8.toml new file mode 100644 index 0000000000000000000000000000000000000000..43ee3099541f832cc3311f458884b4d30fd6208e --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r8.toml @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:922a3210dba1e4254beb152bf1bb4a04aa625d8389d7c0386afa5864e33e03ca +size 772 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r0.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r0.log new file mode 100644 index 0000000000000000000000000000000000000000..995cbb1750abed21b67b8e2a5b5700ca52a98645 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r0.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:300cbf482ee3bbc46f6222e8c2f0367ee02e6859060914d369ffa4480c38460a +size 3533 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r1.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r1.log new file mode 100644 index 0000000000000000000000000000000000000000..9a80d378a062c2749d1f1bf2ee4b5a201e049171 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r1.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:54bf4cace5050fcc509cf2d46bc4b469ba73ba87cf4062386416d9f995b8ee08 +size 2501 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r2.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r2.log new file mode 100644 index 0000000000000000000000000000000000000000..54f336f057110d83155e01bcd267330eb3957e91 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r2.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4a59352937776423e4e2d60dcade377fdc25f3de444e2a49755bd6941dd6501f +size 1872 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r3.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r3.log new file mode 100644 index 0000000000000000000000000000000000000000..43cabc02b86136d9fa9faf82cf9c0a21a16e7bff --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r3.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4963d74df623aab37acec8972c5ea8e9c8f54a3a969c845eeb57784385940e1 +size 1661 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r4.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r4.log new file mode 100644 index 0000000000000000000000000000000000000000..ce85c9ad26562015b5164b6bd917436b5a49a6a3 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r4.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a95077c321cc86d218c43f47cbb6a0f338cc3773b514656c6be9b3755777fb5 +size 1557 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r5.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r5.log new file mode 100644 index 0000000000000000000000000000000000000000..0f064a0cbe78ec97b0f197de22e7259462687bd8 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r5.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5217ebf870e46636070f21893036d90e7f485474e65660b752acb617068ec695 +size 1557 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r6.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r6.log new file mode 100644 index 0000000000000000000000000000000000000000..c664db8e75f406102407b214022f659d5d0259e7 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r6.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:838fa358cb2abe57b7871dd7b112ca2556e7156c298c15c62e16f3d091a358dd +size 1556 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r7.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r7.log new file mode 100644 index 0000000000000000000000000000000000000000..174b4939bf193d3079deda7cd42cadc57226c8ea --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r7.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:68dbe17172a941fb8b7e70f63a8f165146fb554f8c83e3d2fca5d18e4c65ee9a +size 1556 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r8.log b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r8.log new file mode 100644 index 0000000000000000000000000000000000000000..94b9d834f88b3983368f23dbe9a49ee4802a6531 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r8.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:70396dc12b53688448392a5cb5d09eb62899a758e5452ac06e9d413cd1e6aa7e +size 1557 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/input_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..ea0c7955c35965e09281e7ad72e7f9722a3d793b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:754197615fcbb84d31c0a54a0fd62ded7a78578807874b50d4c73f62b7e80ef5 +size 1367 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/public_gate_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..c98157e1777a6c0cd4aed3d9028f538dc7515feb --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:258096c850b6b29941cd58c80c647d918039b1305b798ac5ba386d8861f08610 +size 658470 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/run_config.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..a3ea73adf8457aa476414f059d9ddf83fbb6cf82 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/run_config.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:326d24b9b02244de64b2779b4f99c7925620ab2a8cdca7f1f55a2fa7d5de92ab +size 2437 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/runtime_result.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..e173b9be53ee59f35214449fde07cca185c85806 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a6a22d9110018813864cac2e4f2803f2368c84aa1367d62667fa166e8db66d4 +size 1108 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/staged_features.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/test.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/train.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/val.csv b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_report.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9b229f392a353e9c8e1cd9fff8dfb7e45671c355 --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3132cd487ea0c0fbea9ff153ed56249ceebbe2003658a689ab0d9babecd89b8 +size 330 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_transforms_applied.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/model_input_manifest.json b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..cc159ec5ac566ae5b8a8ecc7493ab97327573d0f --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/staged/tabddpm/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6fc9824cdf43f79410086284c462c4318630326e2f9e3d030f0526857d8409d9 +size 658676 diff --git a/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm_sample_retry_trace_20260511_051616.jsonl b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm_sample_retry_trace_20260511_051616.jsonl new file mode 100644 index 0000000000000000000000000000000000000000..1d42625fdf98d1e9ec03f8f54d236f29b1f0b22b --- /dev/null +++ b/syntheticFail/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/tabddpm_sample_retry_trace_20260511_051616.jsonl @@ -0,0 +1,9 @@ +{"attempt": 0, "sample_batch_size": 256, "sample_seed": 1005, "sample_num_timesteps": 100, "use_ddim": false, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r0.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r0.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_ajynkth7/container.cid', '--gpus', 'device=0', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r0.py']' returned non-zero exit status 1.", "stdout_tail": "16\nSample timestep 15\nSample timestep 14\nSample timestep 13\nSample timestep 12\nSample timestep 11\nSample timestep 10\nSample timestep 9\nSample timestep 8\nSample timestep 7\nSample timestep 6\nSample timestep 5\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 1, "sample_batch_size": 128, "sample_seed": 1006, "sample_num_timesteps": 50, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r1.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r1.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_yhxs_hh2/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r1.py']' returned non-zero exit status 1.", "stdout_tail": "16\nSample timestep 15\nSample timestep 14\nSample timestep 13\nSample timestep 12\nSample timestep 11\nSample timestep 10\nSample timestep 9\nSample timestep 8\nSample timestep 7\nSample timestep 6\nSample timestep 5\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 2, "sample_batch_size": 64, "sample_seed": 1007, "sample_num_timesteps": 20, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r2.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r2.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_b2uldgng/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r2.py']' returned non-zero exit status 1.", "stdout_tail": "16\nSample timestep 15\nSample timestep 14\nSample timestep 13\nSample timestep 12\nSample timestep 11\nSample timestep 10\nSample timestep 9\nSample timestep 8\nSample timestep 7\nSample timestep 6\nSample timestep 5\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 3, "sample_batch_size": 32, "sample_seed": 1008, "sample_num_timesteps": 10, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r3.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r3.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm__7d9705s/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r3.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 9\nSample timestep 8\nSample timestep 7\nSample timestep 6\nSample timestep 5\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 4, "sample_batch_size": 16, "sample_seed": 1009, "sample_num_timesteps": 5, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r4.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r4.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_kagf4vdn/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r4.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 5, "sample_batch_size": 8, "sample_seed": 1010, "sample_num_timesteps": 5, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r5.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r5.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_1d1hlpmd/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r5.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 6, "sample_batch_size": 4, "sample_seed": 1011, "sample_num_timesteps": 5, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r6.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r6.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_nzkjz0qc/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r6.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 7, "sample_batch_size": 2, "sample_seed": 1012, "sample_num_timesteps": 5, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r7.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r7.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_ezaylq06/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r7.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} +{"attempt": 8, "sample_batch_size": 1, "sample_seed": 1013, "sample_num_timesteps": 5, "use_ddim": true, "config_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/config_sample_20260511_051616_r8.toml", "gen_log": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/gen_20260511_051616_r8.log", "status": "fail", "retryable": true, "exception_type": "CalledProcessError", "exception": "Command '['docker', 'run', '--rm', '--init', '--user', '1005:1005', '-e', 'HOME=/work/.home', '--cidfile', '/tmp/bench_docker_tabddpm_180cfjrz/container.cid', '--gpus', 'device=0', '-e', 'TABDDPM_SAMPLE_DDIM=1', '-v', '/data/jialinzhang/SynthesizePipeline-server:/work', '-w', '/work', '-v', '/data/jialinzhang/synthetic_benchmark/tabddpm/code:/workspace/tabddpm/code', 'benchmark:tabddpm-zjl', 'python', '/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-regen2-20260511_051611/_tabddpm_sample_r8.py']' returned non-zero exit status 1.", "stdout_tail": "mlp\nSample using DDIM.\nSample timestep 4\nSample timestep 3\nSample timestep 2\nSample timestep 1\nSample timestep 0\nTraceback (most recent call last):\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/_compat_run.py\", line 6, in \n runpy.run_path(sys.argv[0], run_name='__main__')\n File \"\", line 291, in run_path\n File \"\", line 98, in _run_module_code\n File \"\", line 88, in _run_code\n File \"scripts/pipeline.py\", line 112, in \n main()\n File \"scripts/pipeline.py\", line 61, in main\n sample(\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/scripts/sample.py\", line 102, in sample\n x_gen, y_gen = diffusion.sample_all(num_samples, batch_size, empirical_class_dist.float(), ddim=use_ddim)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File \"/work/output-Benchmark-trainonly-v1/c12/tabddpm/tabddpm-c12-20260511_031424/output/_tabddpm_runtime/tab_ddpm/gaussian_multinomial_diffsuion.py\", line 987, in sample_all\n raise FoundNANsError\ntab_ddpm.utils.FoundNANsError: Found NANs during sampling.\n[TabDDPM] Sampling 2623 rows\n", "stderr_tail": ""} diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/_tabdiff_train.py b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/_tabdiff_train.py new file mode 100644 index 0000000000000000000000000000000000000000..cafa8568d34ab8db027d2b4fc340840e0a785ddc --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/_tabdiff_train.py @@ -0,0 +1,21 @@ + +import os, shutil, subprocess, sys +td = r"/workspace/TabDiff" +name = r"pipeline_c12" +src = r"/work/output-Benchmark-trainonly-v1/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12" +dst_data = os.path.join(td, "data", name) +dst_syn = os.path.join(td, "synthetic", name) +shutil.rmtree(dst_data, ignore_errors=True) +shutil.copytree(src, dst_data) +os.makedirs(dst_syn, exist_ok=True) +for fn in ("real.csv", "test.csv", "val.csv"): + shutil.copy(os.path.join(src, fn), os.path.join(dst_syn, fn)) +os.chdir(td) +os.environ["PYTHONPATH"] = td + os.pathsep + os.environ.get("PYTHONPATH", "") +os.environ["TABDIFF_SMOKE_STEPS"] = "500" +os.environ["TABDIFF_ADAPTER_TRAIN"] = "1" +subprocess.check_call([ + sys.executable, "-m", "tabdiff.main", + "--dataname", name, "--mode", "train", "--gpu", "0", + "--no_wandb", "--exp_name", r"adapter_learnable", +]) diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/input_snapshot.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..53bc9785cbd291dc4565721142e72ea8010529f7 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c14b93d4ff31a5bd4832fb6a7d536728db7185bc4a5cb929081ffbdb1f620c5 +size 1367 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/normalized_schema_snapshot.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..528a08937d5f8790a99b30a506ea9528373f311c --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdd47237e86fffcbc722042f72d26f86f453f1276e6e18decf09dddb9f7d12ad +size 657619 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/public_gate_report.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..9bd937847427b1a3c46b223f490d85282d388ddc --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:db44536c0e96576047e7609aa7d3a96f2a3cbca8946e96ed74f8c7bf52e45cd4 +size 919 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/staged_input_manifest.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..6ca722741fedc234718f9815e4286565443638cf --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ee8dcfafd8fb89c1bc022cf2fc4ab740ee8e85f414937567e0a85e086c728c2a +size 658435 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/runtime_result.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..3498205cbf63b7caa9b73325190254fd0aa0c55a --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b05f2ef6059f5826b3adf61640be6eb74b08a229c3e1cd5a28330298d093e444 +size 1077 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/staged_features.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..140dd006c821cafce8fe1f5ea994c24a24db0f73 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4d0d98b86ca46b032dbc651380d625e2d7600f5251a60811bb81e1a6c5af70e +size 161608 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/test.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..bef74d8120821168118dab7f27630ccdd4e456f2 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377cdc71dcb1451916e4b052f69dcae90c8648105e3d82016bc74348443e25be +size 4125897 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/train.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..8215dd0220c6193b426fec66b98b1ad1272851fd --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c75114f21bd2661465a1c07af94f5249e6d47d50230c60699e74843acb77c74 +size 32713969 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/val.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e0ed233fb0370197ee75c6d056375e50627c3ce0 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9db0022070ad285c003e836f1ec85618f79abd9f38c8801581bbccba183f91eb +size 4101090 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_report.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..f7aecc988653d4d714a85d9ccf606dcc0eef0110 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5bf9e85ad2632509d3b358172f68ab8050b00e6232e118ad25a749887ef1756d +size 323 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_transforms_applied.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/model_input_manifest.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..b6cd6fe64a7aabf012a5d43419d57683a6c939c7 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/staged/tabdiff/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6bde34d63b11d0d9e9364eb8ea2d7c99a5c50310864615d6ac965425d733bd3a +size 658634 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_test.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_train.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_val.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..b20e607797f1dbdafa0127353d1ce801030f7ffc --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_cat_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a40b7a1a10c46761012cccd813d6d0d36acd860e4e82df27b411082f6b14e220 +size 32630248 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_test.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_train.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_val.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..cc6a2932a2388540b9e6d544caefda9e54c2339c --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/X_num_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b291acb8043ad23ea1045941ab75c030ba10b32b317e5b17351d61ca3db8e784 +size 31604 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/info.json b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/info.json new file mode 100644 index 0000000000000000000000000000000000000000..b3896b9f843d7f406db90904ad3bee1fb21a41ec --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/info.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:76b25602b0bfb8431edd723b4d83d331b1923cfd5dd45d6bf03044b4c2f1f9eb +size 239780 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/real.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/real.csv new file mode 100644 index 0000000000000000000000000000000000000000..e457e1f2f94e626d93d7c0b6ef9fd2ad6779daf6 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/real.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ad38a83d82ab9a0f8802d8a8416fd4bbece0c52b52b32bbe155968be0f68d99b +size 8222087 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/test.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..e457e1f2f94e626d93d7c0b6ef9fd2ad6779daf6 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ad38a83d82ab9a0f8802d8a8416fd4bbece0c52b52b32bbe155968be0f68d99b +size 8222087 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/val.csv b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..e457e1f2f94e626d93d7c0b6ef9fd2ad6779daf6 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ad38a83d82ab9a0f8802d8a8416fd4bbece0c52b52b32bbe155968be0f68d99b +size 8222087 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_test.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_test.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_test.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_train.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_train.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_train.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_val.npy b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_val.npy new file mode 100644 index 0000000000000000000000000000000000000000..dc446fbc1e6631d6dddc87fad53e07c78f2d0137 --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/tabular_bundle/pipeline_c12/y_val.npy @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f9d2aa6f032b962f1c2d25f76a4f7ac848cd1147d8520962d31af2d023e72a13 +size 21112 diff --git a/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/train_20260501_083458.log b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/train_20260501_083458.log new file mode 100644 index 0000000000000000000000000000000000000000..d2c09e4abda12e9f622939722cc244a4366301ae --- /dev/null +++ b/syntheticFail/c12/tabdiff/tabdiff-c12-20260501_083442/train_20260501_083458.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26f74e17e900535ce1144c5361f37bfe9904c61c50ffddd69542b30ed0a37380 +size 30831