diff --git a/.gitattributes b/.gitattributes index b9c221d0b1382790211520ab4c442e14af29c29f..bf6d42fb241298acbf911ae3b8ec20dc22765f4e 100644 --- a/.gitattributes +++ b/.gitattributes @@ -3862,3 +3862,33 @@ SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/data/tabsyn_c2/y_train.np SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/gen_20260501_060640.log filter=lfs diff=lfs merge=lfs -text SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/real.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/tabsyn-c2-1382-20260501_060640.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/train_20260501_054336.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/gen_20260501_060709.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/input_snapshot.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/train_20260501_060652.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/normalized_schema_snapshot.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/public_gate_report.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/staged_input_manifest.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/runtime_result.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/staged_features.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_report.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_transforms_applied.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/model_input_manifest.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae_metadata.json filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/gen_20260504_173024.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/train_20260504_173008.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/gen_20260504_174029.log filter=lfs diff=lfs merge=lfs -text diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/val.csv b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26e90c1170a57a14c05832ac88027722b1f3848f9662c7c09ef7c93dcba4cc01 +size 5176 diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_report.json b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..6473cb524a6aca6c0137b1df8834b97c83691e40 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_report.json @@ -0,0 +1,7 @@ +{ + "adapter_ready_status": "pass", + "adapter_fail_reason_code": null, + "adapter_fail_detail": null, + "adapter_transforms_applied": [], + "model_input_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/model_input_manifest.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_transforms_applied.json b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..0637a088a01e8ddab3bf3fa98dbe804cbde1a0dc --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/adapter_transforms_applied.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/model_input_manifest.json b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..64f1d74c2494673a5dd2bff99e278a5c50b69787 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/staged/tabsyn/model_input_manifest.json @@ -0,0 +1,151 @@ +{ + "dataset_id": "c2", + "model": "tabsyn", + "target_column": "class", + "task_type": "classification", + "column_schema": [ + { + "name": "buying", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "med", + "high", + "low" + ] + } + }, + { + "name": "maint", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "low", + "med", + "high" + ] + } + }, + { + "name": "doors", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "2", + "5more", + "3", + "4" + ] + } + }, + { + "name": "persons", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "2", + "4", + "more" + ] + } + }, + { + "name": "lug_boot", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "small", + "big", + "med" + ] + } + }, + { + "name": "safety", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "low", + "high", + "med" + ] + } + }, + { + "name": "class", + "role": "target", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "unacc", + "good", + "acc", + "vgood" + ] + } + } + ], + "public_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/public_gate/staged_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tabsyn/tabsyn-c2-20260501_054336/public_gate/public_gate_report.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/real.csv b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/real.csv new file mode 100644 index 0000000000000000000000000000000000000000..94d40776e20a2226c5a316fc3eaf8b74b8513970 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/real.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e7b4d4a1f787d81e53eddffbd43603149e1dd038d94b4c0244340ff4a2e4511 +size 19397 diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/test.csv b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..94d40776e20a2226c5a316fc3eaf8b74b8513970 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/synthetic/tabsyn_c2/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e7b4d4a1f787d81e53eddffbd43603149e1dd038d94b4c0244340ff4a2e4511 +size 19397 diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/tabsyn-c2-1382-20260501_060640.csv b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/tabsyn-c2-1382-20260501_060640.csv new file mode 100644 index 0000000000000000000000000000000000000000..39e2693554f350eece083f11a7ec5f66be41602b --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/tabsyn-c2-1382-20260501_060640.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2afabda24cfd6511735e2c376c97c1593ce80d5ef5a5185cdfe71b3a4a118000 +size 40220 diff --git a/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/train_20260501_054336.log b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/train_20260501_054336.log new file mode 100644 index 0000000000000000000000000000000000000000..3f47b32c1e7ee1a9ca0414ac30c4a85a14d55146 --- /dev/null +++ b/SynthData0523/main/c2/tabsyn/tabsyn-c2-20260501_054336/train_20260501_054336.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1e99c585306f1279128b0848854ae012c2e21c5df40f4520a77ffe1a85bb733a +size 2086454 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..ee07f8086f9dbcecc5be413f1c22bda98e3c3aad --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_generate.py @@ -0,0 +1,23 @@ +import os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +from src.SpecificModels.ctgan_rdt_inverse_fix import apply_ctgan_inverse_fix +apply_ctgan_inverse_fix() +import pandas as pd +from ctgan.synthesizers.tvae import TVAE +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +model = TVAE.load("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt") +total = 1382 +chunk = min(50000, total) if total > 50000 else total +parts = [] +left = total +while left > 0: + take = min(chunk, left) + parts.append(model.sample(take)) + left -= take +samples = pd.concat(parts, ignore_index=True) if len(parts) > 1 else parts[0] +samples.to_csv("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..bf188e71fc3ecfb788fd1e9ad029b67b8c19e45a --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/_tvae_train.py @@ -0,0 +1,30 @@ +import json, os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +import pandas as pd +from ctgan.data import read_csv +from ctgan.synthesizers.tvae import TVAE + +# Keep transform stage parallelism bounded for stability on shared host. +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +_nj = (os.environ.get("TVAE_CTGAN_JOBTRANS_N_JOBS") or "").strip() +if _nj: + print("[TVAE] joblib Parallel cap ON, TVAE_CTGAN_JOBTRANS_N_JOBS=" + _nj) +else: + print("[TVAE] joblib Parallel cap OFF (unset TVAE_CTGAN_JOBTRANS_N_JOBS)") +print("[TVAE] LOKY_MAX_CPU_COUNT=" + str(os.environ.get("LOKY_MAX_CPU_COUNT", ""))) + +csv_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt" +epochs = 300 + +data, discrete_columns = read_csv(csv_path, meta_path, header=True, discrete=None) +print(f"[TVAE] Training on {len(data)} rows, {len(data.columns)} cols, epochs={epochs}") +model = TVAE(epochs=epochs, batch_size=500) +model.fit(data, discrete_columns) +model.save(save_path) +print(f"[TVAE] Model saved -> {save_path}") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/gen_20260501_060709.log b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/gen_20260501_060709.log new file mode 100644 index 0000000000000000000000000000000000000000..6e7da99bdaa881a0255e099018caabf0fcb884d2 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/gen_20260501_060709.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:811a90c82a00a2453464da6ac5fc4ab320e6647e8228f8cec6951bd6f380b484 +size 404 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/input_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..cd1d010fabba126c78ff3a3f3d3641d05081e2ca --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/input_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:312db5b6cbb94923c8ad75e1540b44497286257503a0a69e724cffe3276247d8 +size 1340 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/train_20260501_060652.log b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/train_20260501_060652.log new file mode 100644 index 0000000000000000000000000000000000000000..9e1180bfc3aade0f1b5beab810653d04743a3f29 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/train_20260501_060652.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c85525e2a454b9c93bb4128e261000b45ec90958e4758d80a0e77a9d772ece2e +size 531 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt new file mode 100644 index 0000000000000000000000000000000000000000..17b6a7e21950887bb50757c079cfd899b0c9e47c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/models_300epochs/tvae_300epochs.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3a0d83f23a59f1dd860e3ef1c7fd7e17bf189a4f5b79f6078b43dbbe8d01dd6 +size 344876 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/normalized_schema_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..bc291aca72c2ac00d7eb2da74c894bb15ef82aed --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a63ea2091eccf0145444f670415e7201dbdd052bc2ddabdc4241f6f16bdcf0a0 +size 3153 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/public_gate_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..7a6c2a269c5cb0cf7e30d07bcc6766f4fd653e51 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/public_gate_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bdc8c14ffce6055ca726f7949b2900c4ba619b670f8fc63c61328c24e4c46c66 +size 912 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/staged_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..76aa92f06e3603dc0b7c9f5324d2367607e74be1 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/public_gate/staged_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20e5fa55753bde0cd4ff2b52b1ffd4f27b1676c6d80746ceb0f653fc1e538259 +size 3929 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/runtime_result.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..3dd03cb281a9cbaf6c11b8d7fa9c4885ebd7f0e2 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/runtime_result.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0f27756195564a22238b07287b1b1d52053d96519b5597d44fc09738648d18c +size 894 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/staged_features.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..96ce2fcc5c1b712d1baabe9a6462bb9c882c30fc --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/staged_features.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:37511511f1d7cb0e004f9d7305c900644ebefe672c9a1a418c1f29b36786fabd +size 659 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/test.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..392a0d7189a34d8f13ecf20a99d64b03230d517c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b48114a7d0bc5bd9a07920f903c8d4aba8bf98bf2a66a050da03588b0245ca73 +size 5273 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/train.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..da4f4d55134eebc0e51157d0d467536371db1484 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aed00c2c2b3f88a55a7ebff31b2e1b5e0e32fb0a7267e0b9d2779cd23e434dd +size 41565 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/val.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26e90c1170a57a14c05832ac88027722b1f3848f9662c7c09ef7c93dcba4cc01 +size 5176 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..eeb29fca6bb029b831e82e2ec77af21806dc56c3 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_report.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f63c4ac0926e0c8e109a9daee966333ed1de7839a3df1fb57209209ecceca6f3 +size 312 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_transforms_applied.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..6f3aaa01a627a955d2022165805d2786c0da78ba --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/adapter_transforms_applied.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f53cda18c2baa0c0354bb5f9a3ecbe5ed12ab4d8e11ba873c2f11161202b945 +size 2 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/model_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..b5310bf5dffc28893c19969f46fe19d10181da23 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/staged/tvae/model_input_manifest.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a7f1f46e0893532bf06da0b5419d6186b1ebbf5757e6dbfd4f5924179e7e6517 +size 4117 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv new file mode 100644 index 0000000000000000000000000000000000000000..7f03aa1c4919240cc177bb5d5621d801da134f1d --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae-c2-1382-20260501_060709.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0623ee3f26117b60c69a602520884727739b320db35033d330e1b1415a4d8469 +size 41504 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae_metadata.json b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae_metadata.json new file mode 100644 index 0000000000000000000000000000000000000000..3357d5c85d5c890c0c326fcadd967ac3a125e0fb --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260501_060652/tvae_metadata.json @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c3281d50afec388c98ae73df59e56f82e3d46f7f968df0f491e9451aed70de6e +size 476 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..ba56b67e501be1a02f9df11b17b5be278a4fbaf4 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_generate.py @@ -0,0 +1,23 @@ +import os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +from src.SpecificModels.ctgan_rdt_inverse_fix import apply_ctgan_inverse_fix +apply_ctgan_inverse_fix() +import pandas as pd +from ctgan.synthesizers.tvae import TVAE +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +model = TVAE.load("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt") +total = 1382 +chunk = min(50000, total) if total > 50000 else total +parts = [] +left = total +while left > 0: + take = min(chunk, left) + parts.append(model.sample(take)) + left -= take +samples = pd.concat(parts, ignore_index=True) if len(parts) > 1 else parts[0] +samples.to_csv("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..1c8ca6db5febbe87084a63b4625ce50a43245d7d --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/_tvae_train.py @@ -0,0 +1,30 @@ +import json, os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +import pandas as pd +from ctgan.data import read_csv +from ctgan.synthesizers.tvae import TVAE + +# Keep transform stage parallelism bounded for stability on shared host. +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +_nj = (os.environ.get("TVAE_CTGAN_JOBTRANS_N_JOBS") or "").strip() +if _nj: + print("[TVAE] joblib Parallel cap ON, TVAE_CTGAN_JOBTRANS_N_JOBS=" + _nj) +else: + print("[TVAE] joblib Parallel cap OFF (unset TVAE_CTGAN_JOBTRANS_N_JOBS)") +print("[TVAE] LOKY_MAX_CPU_COUNT=" + str(os.environ.get("LOKY_MAX_CPU_COUNT", ""))) + +csv_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt" +epochs = 300 + +data, discrete_columns = read_csv(csv_path, meta_path, header=True, discrete=None) +print(f"[TVAE] Training on {len(data)} rows, {len(data.columns)} cols, epochs={epochs}") +model = TVAE(epochs=epochs, batch_size=500) +model.fit(data, discrete_columns) +model.save(save_path) +print(f"[TVAE] Model saved -> {save_path}") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/gen_20260504_173024.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/gen_20260504_173024.log new file mode 100644 index 0000000000000000000000000000000000000000..53d08cd059dddaa7aff8bae5458dce3fa0b5ab7e --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/gen_20260504_173024.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c250d16c78bb78776dfd39677e43fa301524a14766e56dfb776757716b41ad3c +size 404 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/input_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..9e28a5421f2176e174a0659e66a40054269fb2ac --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/input_snapshot.json @@ -0,0 +1,36 @@ +{ + "dataset_id": "c2", + "model": "tvae", + "inputs": { + "train_csv": { + "path": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-train.csv", + "exists": true, + "size": 42948, + "sha256": "17bc560fa96bd00fb3b526e1e65bc91210b701d0d0a4e8bb9b4c5196cab56def" + }, + "val_csv": { + "path": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-val.csv", + "exists": true, + "size": 5349, + "sha256": "61e565eca62e65a7dccd9d51039a3170413379e10fc494e25870e7c4294863c9" + }, + "test_csv": { + "path": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-test.csv", + "exists": true, + "size": 5448, + "sha256": "cbcbb062a1faf5fa44b66c80532baa229e05b94fc42137269761e6c6d84af20a" + }, + "profile_json": { + "path": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/artifacts/data_core/tabular/c2/c2-dataset_profile.json", + "exists": true, + "size": 3240, + "sha256": "526b7163b2076c93c0bf4638438081ee8a6907065d5b608faa40d1a3dbc2a27b" + }, + "contract_json": { + "path": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/artifacts/data_core/tabular/c2/c2-dataset_contract_v1.json", + "exists": true, + "size": 3731, + "sha256": "fb595a876054c2ee9b4e10cfe83a5691588de1d25466cbb9d473c18ad3604009" + } + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/train_20260504_173008.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/train_20260504_173008.log new file mode 100644 index 0000000000000000000000000000000000000000..4f1bc8a0c8aa1472b5b5a147d542eb71dee6b421 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/train_20260504_173008.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1c352ed86bd6646a32996cf14ef89e36f1c70492c504f33136461af759d97f8 +size 531 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt new file mode 100644 index 0000000000000000000000000000000000000000..601624c018769994626fca7acae79f71da20202b --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:359d4ce6570b67da168f59f79a24d6afcc861aaf7416c29c0ad54e031827ea1b +size 344876 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/normalized_schema_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..689b1d00d96508e44ba40e58dc4560e19afc2b3b --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/normalized_schema_snapshot.json @@ -0,0 +1,144 @@ +{ + "dataset_id": "c2", + "target_column": "class", + "task_type": "classification", + "columns": [ + { + "name": "buying", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "med", + "high", + "low" + ] + } + }, + { + "name": "maint", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "low", + "med", + "high" + ] + } + }, + { + "name": "doors", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "2", + "5more", + "3", + "4" + ] + } + }, + { + "name": "persons", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "2", + "4", + "more" + ] + } + }, + { + "name": "lug_boot", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "small", + "big", + "med" + ] + } + }, + { + "name": "safety", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "low", + "high", + "med" + ] + } + }, + { + "name": "class", + "role": "target", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "unacc", + "good", + "acc", + "vgood" + ] + } + } + ] +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..2e4cdcb2a4e28e40d59b17a83e773f622b7636a5 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json @@ -0,0 +1,37 @@ +{ + "dataset_id": "c2", + "status": "pass", + "checks": [ + { + "check_id": "PG001_csv_parse_ok", + "status": "pass" + }, + { + "check_id": "PG002_split_header_consistent", + "status": "pass" + }, + { + "check_id": "PG003_profile_header_match", + "status": "pass" + }, + { + "check_id": "PG004_missing_token_normalized", + "status": "pass" + }, + { + "check_id": "PG005_semantic_type_validated", + "status": "pass" + }, + { + "check_id": "PG006_target_defined_and_valid", + "status": "pass" + } + ], + "target_column": "class", + "task_type": "classification", + "input_splits": { + "train": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-train.csv", + "val": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-val.csv", + "test": "/data/jialinzhang/SynthesizePipeline-server/DatasetNew/c2/c2-test.csv" + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/staged_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..34b8b885d16936dabc4bfa6ae10d9902d0dcbe1e --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/public_gate/staged_input_manifest.json @@ -0,0 +1,149 @@ +{ + "dataset_id": "c2", + "target_column": "class", + "task_type": "classification", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json", + "column_schema": [ + { + "name": "buying", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "med", + "high", + "low" + ] + } + }, + { + "name": "maint", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "low", + "med", + "high" + ] + } + }, + { + "name": "doors", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "2", + "5more", + "3", + "4" + ] + } + }, + { + "name": "persons", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "2", + "4", + "more" + ] + } + }, + { + "name": "lug_boot", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "small", + "big", + "med" + ] + } + }, + { + "name": "safety", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "low", + "high", + "med" + ] + } + }, + { + "name": "class", + "role": "target", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "unacc", + "good", + "acc", + "vgood" + ] + } + } + ] +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/run_config.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..7335c4ba5feedfd103bfd4c81cc612041c2e4e81 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/run_config.json @@ -0,0 +1,40 @@ +{ + "schema_version": 1, + "recorded_at": "2026-05-04T17:30:08", + "dataset_id": "c2", + "model": "tvae", + "work_dir": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008", + "dataset_source_requested": "new", + "dataset_source_resolved": "new", + "cli_args": { + "model": "tvae", + "dataset": "c2", + "dataset_source": "new", + "train": true, + "generate": true, + "num_rows": 0, + "epochs": null, + "output_dir": null, + "model_dir": null, + "work_dir": null, + "resume": false, + "no_stats": false + }, + "resolved": { + "num_rows": 1382, + "model_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt", + "output_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv" + }, + "input_artifacts": { + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json", + "public_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/public_gate/staged_input_manifest.json", + "model_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/tvae/model_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json", + "target_column": "class", + "task_type": "classification" + }, + "env_overrides": { + "BENCHMARK_TVAE_GPUS": "device=3" + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/runtime_result.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..22be744ff183e559b6ad1a680776340fac9c465e --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/runtime_result.json @@ -0,0 +1,27 @@ +{ + "dataset_id": "c2", + "model": "tvae", + "run_id": "tvae-c2-20260504_173008", + "public_gate_status": "pass", + "adapter_ready_status": "pass", + "train_status": "success", + "generate_status": "success", + "reason_code": null, + "reason_detail": null, + "artifacts": { + "synthetic_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv", + "model_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/models_300epochs/tvae_300epochs.pt" + }, + "timings": { + "train": { + "started_at": "2026-05-04T17:30:08", + "ended_at": "2026-05-04T17:30:24", + "duration_sec": 15.956 + }, + "generate": { + "started_at": "2026-05-04T17:30:24", + "ended_at": "2026-05-04T17:30:30", + "duration_sec": 5.259 + } + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..61783861dd5de501592f76acb0469cf3f3b2622a --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json @@ -0,0 +1,37 @@ +[ + { + "feature_name": "buying", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "maint", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "doors", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "persons", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "lug_boot", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "safety", + "data_type": "categorical", + "is_target": false + }, + { + "feature_name": "class", + "data_type": "categorical", + "is_target": true + } +] \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..392a0d7189a34d8f13ecf20a99d64b03230d517c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b48114a7d0bc5bd9a07920f903c8d4aba8bf98bf2a66a050da03588b0245ca73 +size 5273 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..da4f4d55134eebc0e51157d0d467536371db1484 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4aed00c2c2b3f88a55a7ebff31b2e1b5e0e32fb0a7267e0b9d2779cd23e434dd +size 41565 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26e90c1170a57a14c05832ac88027722b1f3848f9662c7c09ef7c93dcba4cc01 +size 5176 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..4242764ed766368329eb87e61673e22e2b5b6af8 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_report.json @@ -0,0 +1,7 @@ +{ + "adapter_ready_status": "pass", + "adapter_fail_reason_code": null, + "adapter_fail_detail": null, + "adapter_transforms_applied": [], + "model_input_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/tvae/model_input_manifest.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_transforms_applied.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..0637a088a01e8ddab3bf3fa98dbe804cbde1a0dc --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/adapter_transforms_applied.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/model_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..f04fd5c7b319044a938f125aa99765abe6589a9c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/staged/tvae/model_input_manifest.json @@ -0,0 +1,151 @@ +{ + "dataset_id": "c2", + "model": "tvae", + "target_column": "class", + "task_type": "classification", + "column_schema": [ + { + "name": "buying", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "med", + "high", + "low" + ] + } + }, + { + "name": "maint", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "vhigh", + "low", + "med", + "high" + ] + } + }, + { + "name": "doors", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "2", + "5more", + "3", + "4" + ] + } + }, + { + "name": "persons", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "2", + "4", + "more" + ] + } + }, + { + "name": "lug_boot", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "small", + "big", + "med" + ] + } + }, + { + "name": "safety", + "role": "feature", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 3, + "unique_ratio": 0.002171, + "example_values": [ + "low", + "high", + "med" + ] + } + }, + { + "name": "class", + "role": "target", + "semantic_type": "categorical", + "nullable": false, + "missing_tokens": [], + "parse_format": null, + "impute_strategy": "mode", + "profile_stats": { + "missing_rate": 0.0, + "unique_count": 4, + "unique_ratio": 0.002894, + "example_values": [ + "unacc", + "good", + "acc", + "vgood" + ] + } + } + ], + "public_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/public_gate/staged_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_173008/public_gate/public_gate_report.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv new file mode 100644 index 0000000000000000000000000000000000000000..0facc9d2d09dd192dcf6aaf22fef2e2ec709388b --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae-c2-1382-20260504_173024.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5c13329eb5fa57144da4e37e2c72a488103b21bb242e3711339b259178094e71 +size 41572 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae_metadata.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae_metadata.json new file mode 100644 index 0000000000000000000000000000000000000000..183d627ebc98e89233655ec98c9dcbc528c4c328 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_173008/tvae_metadata.json @@ -0,0 +1,32 @@ +{ + "columns": [ + { + "name": "buying", + "type": "categorical" + }, + { + "name": "maint", + "type": "categorical" + }, + { + "name": "doors", + "type": "categorical" + }, + { + "name": "persons", + "type": "categorical" + }, + { + "name": "lug_boot", + "type": "categorical" + }, + { + "name": "safety", + "type": "categorical" + }, + { + "name": "class", + "type": "categorical" + } + ] +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..3286ed3675bc2e6dab9822c66720b2afe05caa4d --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_generate.py @@ -0,0 +1,23 @@ +import os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +from src.SpecificModels.ctgan_rdt_inverse_fix import apply_ctgan_inverse_fix +apply_ctgan_inverse_fix() +import pandas as pd +from ctgan.synthesizers.tvae import TVAE +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +model = TVAE.load("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/models_300epochs/tvae_300epochs.pt") +total = 1382 +chunk = min(50000, total) if total > 50000 else total +parts = [] +left = total +while left > 0: + take = min(chunk, left) + parts.append(model.sample(take)) + left -= take +samples = pd.concat(parts, ignore_index=True) if len(parts) > 1 else parts[0] +samples.to_csv("/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/tvae-c2-1382-20260504_174029.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/tvae-c2-1382-20260504_174029.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..907e254de6937dd18f07ac7af235f221f36bb32a --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/_tvae_train.py @@ -0,0 +1,39 @@ +import json, os, sys +sys.path.insert(0, "/work") +from src.SpecificModels.ctgan_joblib_parallel_cap import apply_parallel_cap_from_env +apply_parallel_cap_from_env() +import pandas as pd +from ctgan.data import read_csv +from ctgan.synthesizers.tvae import TVAE + +# Keep transform stage parallelism bounded for stability on shared host. +os.environ.setdefault("LOKY_MAX_CPU_COUNT", "8") +os.environ.setdefault("OPENBLAS_NUM_THREADS", "8") +os.environ.setdefault("MKL_NUM_THREADS", "8") +_nj = (os.environ.get("TVAE_CTGAN_JOBTRANS_N_JOBS") or "").strip() +if _nj: + print("[TVAE] joblib Parallel cap ON, TVAE_CTGAN_JOBTRANS_N_JOBS=" + _nj) +else: + print("[TVAE] joblib Parallel cap OFF (unset TVAE_CTGAN_JOBTRANS_N_JOBS)") +print("[TVAE] LOKY_MAX_CPU_COUNT=" + str(os.environ.get("LOKY_MAX_CPU_COUNT", ""))) + +csv_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174013/models_300epochs/tvae_300epochs.pt" +epochs = int(os.environ.get("TVAE_EPOCHS", 300)) +batch_size = int(os.environ.get("TVAE_BATCH_SIZE", "500")) +embedding_dim = int(os.environ.get("TVAE_EMBEDDING_DIM", "128")) +def _parse_dims(name, default): + raw = (os.environ.get(name) or "").strip() + if not raw: + return default + return tuple(int(x.strip()) for x in raw.split(",") if x.strip()) +compress_dims = _parse_dims("TVAE_COMPRESS_DIMS", (128, 128)) +decompress_dims = _parse_dims("TVAE_DECOMPRESS_DIMS", (128, 128)) + +data, discrete_columns = read_csv(csv_path, meta_path, header=True, discrete=None) +print(f"[TVAE] Training on {len(data)} rows, {len(data.columns)} cols, epochs={epochs}, batch_size={batch_size}, embedding_dim={embedding_dim}, compress_dims={compress_dims}, decompress_dims={decompress_dims}") +model = TVAE(epochs=epochs, batch_size=batch_size, embedding_dim=embedding_dim, compress_dims=compress_dims, decompress_dims=decompress_dims) +model.fit(data, discrete_columns) +model.save(save_path) +print(f"[TVAE] Model saved -> {save_path}") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/gen_20260504_174029.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/gen_20260504_174029.log new file mode 100644 index 0000000000000000000000000000000000000000..a1b1e990c2280e5c69b5bb23bc9d3b47e6938193 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174013/gen_20260504_174029.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:56d72e0efac984702b081bb48d7cb946ea3691388616e818ff414e6e231d5453 +size 404