diff --git a/.gitattributes b/.gitattributes index 626f6d5c8911d8b31271295f57edd8161dac52c0..8ddb3a199d5eaef623b04fbcd96a66ecb1f2dd54 100644 --- a/.gitattributes +++ b/.gitattributes @@ -3909,3 +3909,21 @@ SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/gen_20260504_174137.log filte SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/models_300epochs/train_20260504_174121.log filter=lfs diff=lfs merge=lfs -text SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/models_300epochs/tvae_300epochs.pt filter=lfs diff=lfs merge=lfs -text SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae-c2-1382-20260504_174137.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/gen_20260504_174210.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/train_20260504_174154.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/tvae_300epochs.pt filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/gen_20260504_174245.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/train_20260504_174228.log filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/tvae_300epochs.pt filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/test.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/train.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/val.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv filter=lfs diff=lfs merge=lfs -text +SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/gen_20260504_175041.log filter=lfs diff=lfs merge=lfs -text diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/train.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..da4f4d55134eebc0e51157d0d467536371db1484 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174121/staged/public/val.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174121/staged/tvae/adapter_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/tvae/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..8e5f88dfc2ef54136ba069841270a9bc1107c991 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174121/staged/tvae/model_input_manifest.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/tvae/adapter_transforms_applied.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/tvae/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..0637a088a01e8ddab3bf3fa98dbe804cbde1a0dc --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174121/staged/tvae/model_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/staged/tvae/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..4025a7ab4cdca8637f0c0f73606fe22e2f7a7433 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174121/public_gate/staged_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174121/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174121/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174121/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174121/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174121/public_gate/public_gate_report.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae-c2-1382-20260504_174137.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae-c2-1382-20260504_174137.csv new file mode 100644 index 0000000000000000000000000000000000000000..0737ba5dfe37b5d7ec7bc0bc5c69c9ede6a47216 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae-c2-1382-20260504_174137.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1b2dc7b4aac308837c0d16c501f82943b483cde999544304161ff98921ed6e4c +size 41505 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae_metadata.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/tvae_metadata.json new file mode 100644 index 0000000000000000000000000000000000000000..183d627ebc98e89233655ec98c9dcbc528c4c328 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174121/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_174154/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..d80d25210e0289b817b08633cb84481dad9fa72c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/_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_174154/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_174154/tvae-c2-1382-20260504_174210.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..26e132045e4721046a67aaab210cdd192059dbd4 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/_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_174154/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/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_174154/gen_20260504_174210.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/gen_20260504_174210.log new file mode 100644 index 0000000000000000000000000000000000000000..63123e59ac40ced95634de8d57657fd11d935320 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/gen_20260504_174210.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9295c44c01b1fd97e9c805d7a481d72fcd0e87d969e89140bc0d39af40dfc04a +size 404 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/input_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..9e28a5421f2176e174a0659e66a40054269fb2ac --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/models_300epochs/train_20260504_174154.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/train_20260504_174154.log new file mode 100644 index 0000000000000000000000000000000000000000..18eba14510752169d46511d24b9fa056d4d48a17 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/train_20260504_174154.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:545125874fecb8ddd76af96a5ee5e06601127a0dd2e37ce07f49191222e99dc3 +size 620 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/tvae_300epochs.pt b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/tvae_300epochs.pt new file mode 100644 index 0000000000000000000000000000000000000000..8a29d8a55e3370ac0603b39a5784954180c743de --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/models_300epochs/tvae_300epochs.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c313f03bd4c66656f8c97200f3e68fa34fe32d3c2b0f3e6faccdd71d3f96f276 +size 344876 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/public_gate/normalized_schema_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..689b1d00d96508e44ba40e58dc4560e19afc2b3b --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/public_gate/public_gate_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..2e4cdcb2a4e28e40d59b17a83e773f622b7636a5 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/public_gate/staged_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..3b36c44b28c91fc89b7acfc0f2b620ed715caaf6 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/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_174154/run_config.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..d7c6834b0a8e47bb7e6f56b9fd086655f8441bce --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/run_config.json @@ -0,0 +1,45 @@ +{ + "schema_version": 1, + "recorded_at": "2026-05-04T17:41:54", + "dataset_id": "c2", + "model": "tvae", + "work_dir": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154", + "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_174154/models_300epochs/tvae_300epochs.pt", + "output_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv" + }, + "input_artifacts": { + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/public_gate/public_gate_report.json", + "public_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/public_gate/staged_input_manifest.json", + "model_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/tvae/model_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/train.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/staged_features.json", + "target_column": "class", + "task_type": "classification" + }, + "env_overrides": { + "BENCHMARK_TVAE_GPUS": "device=3", + "TVAE_BATCH_SIZE": "256", + "TVAE_COMPRESS_DIMS": "256,256", + "TVAE_DECOMPRESS_DIMS": "256,256", + "TVAE_EMBEDDING_DIM": "128", + "TVAE_EPOCHS": "500" + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/runtime_result.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..731b3fb75f31150c5c810369fca9d9fb0a47b65e --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/runtime_result.json @@ -0,0 +1,27 @@ +{ + "dataset_id": "c2", + "model": "tvae", + "run_id": "tvae-c2-20260504_174154", + "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_174154/tvae-c2-1382-20260504_174210.csv", + "model_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/models_300epochs/tvae_300epochs.pt" + }, + "timings": { + "train": { + "started_at": "2026-05-04T17:41:54", + "ended_at": "2026-05-04T17:42:10", + "duration_sec": 15.509 + }, + "generate": { + "started_at": "2026-05-04T17:42:10", + "ended_at": "2026-05-04T17:42:15", + "duration_sec": 5.341 + } + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/staged_features.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..61783861dd5de501592f76acb0469cf3f3b2622a --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/public/test.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..392a0d7189a34d8f13ecf20a99d64b03230d517c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/public/train.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..da4f4d55134eebc0e51157d0d467536371db1484 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/public/val.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/tvae/adapter_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/tvae/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..189b83c6cb1392d0d91b7025744650bbf87dfb55 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/tvae/model_input_manifest.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/tvae/adapter_transforms_applied.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/tvae/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..0637a088a01e8ddab3bf3fa98dbe804cbde1a0dc --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/staged/tvae/model_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/staged/tvae/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..3b4bcd1074c6e0d6cc900926febe83d6ece42b52 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174154/public_gate/staged_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174154/public_gate/public_gate_report.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv new file mode 100644 index 0000000000000000000000000000000000000000..c83688d2010e78aeb0ecc98529fdd18e33c714d5 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae-c2-1382-20260504_174210.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94ee321408fa4dd67c768ba7f1522bec0d6ad27f49ecc50eb179d2ae844dd3f5 +size 41485 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae_metadata.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/tvae_metadata.json new file mode 100644 index 0000000000000000000000000000000000000000..183d627ebc98e89233655ec98c9dcbc528c4c328 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174154/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_174228/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..bc004c641ef3108ef8d5f082c796ac82f8020042 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/_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_174228/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_174228/tvae-c2-1382-20260504_174245.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..bb08e002da231ddadd43ffcfd0f08856e725b5fb --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/_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_174228/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/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_174228/gen_20260504_174245.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/gen_20260504_174245.log new file mode 100644 index 0000000000000000000000000000000000000000..8c9691faa417502fa8ab6fd539913322f6ab883f --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/gen_20260504_174245.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:52660e570f2b1798f41853f45ac28d1c585f75b473dc0bafb63cea59cf9cd40d +size 404 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/input_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/input_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..9e28a5421f2176e174a0659e66a40054269fb2ac --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/models_300epochs/train_20260504_174228.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/train_20260504_174228.log new file mode 100644 index 0000000000000000000000000000000000000000..5de5d0ad51877c8b6ec752621ca300d9862143ba --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/train_20260504_174228.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:58c60bb9fe86a317efabacf81546eb2b25f680a81383de073a9feceb8729d822 +size 620 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/tvae_300epochs.pt b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/tvae_300epochs.pt new file mode 100644 index 0000000000000000000000000000000000000000..9924f6a37f84dc82fb6b9898dcfd4dd32b199504 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/models_300epochs/tvae_300epochs.pt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:15fc84c398c90a6b1dfa00fc6c2395643c8ca9901216eb12f9c29c1389c2775b +size 344876 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/public_gate/normalized_schema_snapshot.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/public_gate/normalized_schema_snapshot.json new file mode 100644 index 0000000000000000000000000000000000000000..689b1d00d96508e44ba40e58dc4560e19afc2b3b --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/public_gate/public_gate_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/public_gate/public_gate_report.json new file mode 100644 index 0000000000000000000000000000000000000000..2e4cdcb2a4e28e40d59b17a83e773f622b7636a5 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/public_gate/staged_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/public_gate/staged_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..8b14a46f210a5c5de1d60562b8556e1663ab2d60 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/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_174228/run_config.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/run_config.json new file mode 100644 index 0000000000000000000000000000000000000000..7ba68d85fbf3be069f5726a7ab23f2656ab6a24e --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/run_config.json @@ -0,0 +1,45 @@ +{ + "schema_version": 1, + "recorded_at": "2026-05-04T17:42:28", + "dataset_id": "c2", + "model": "tvae", + "work_dir": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228", + "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_174228/models_300epochs/tvae_300epochs.pt", + "output_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv" + }, + "input_artifacts": { + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/public_gate/public_gate_report.json", + "public_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/public_gate/staged_input_manifest.json", + "model_manifest": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/tvae/model_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/train.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/staged_features.json", + "target_column": "class", + "task_type": "classification" + }, + "env_overrides": { + "BENCHMARK_TVAE_GPUS": "device=3", + "TVAE_BATCH_SIZE": "256", + "TVAE_COMPRESS_DIMS": "256,256", + "TVAE_DECOMPRESS_DIMS": "256,256", + "TVAE_EMBEDDING_DIM": "256", + "TVAE_EPOCHS": "500" + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/runtime_result.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/runtime_result.json new file mode 100644 index 0000000000000000000000000000000000000000..79f329aafcff2be74e9f81bdeb2d4b5a868bdd83 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/runtime_result.json @@ -0,0 +1,27 @@ +{ + "dataset_id": "c2", + "model": "tvae", + "run_id": "tvae-c2-20260504_174228", + "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_174228/tvae-c2-1382-20260504_174245.csv", + "model_path": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/models_300epochs/tvae_300epochs.pt" + }, + "timings": { + "train": { + "started_at": "2026-05-04T17:42:28", + "ended_at": "2026-05-04T17:42:45", + "duration_sec": 16.727 + }, + "generate": { + "started_at": "2026-05-04T17:42:45", + "ended_at": "2026-05-04T17:42:50", + "duration_sec": 4.871 + } + } +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/staged_features.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/staged_features.json new file mode 100644 index 0000000000000000000000000000000000000000..61783861dd5de501592f76acb0469cf3f3b2622a --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/public/test.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/test.csv new file mode 100644 index 0000000000000000000000000000000000000000..392a0d7189a34d8f13ecf20a99d64b03230d517c --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/public/train.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/train.csv new file mode 100644 index 0000000000000000000000000000000000000000..da4f4d55134eebc0e51157d0d467536371db1484 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/public/val.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/public/val.csv new file mode 100644 index 0000000000000000000000000000000000000000..af8caf7ee42524188534a3daf32996dc491952d9 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/tvae/adapter_report.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/tvae/adapter_report.json new file mode 100644 index 0000000000000000000000000000000000000000..0e82075016a8326f1f9b6c83948df8bb21b14b53 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/tvae/model_input_manifest.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/tvae/adapter_transforms_applied.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/tvae/adapter_transforms_applied.json new file mode 100644 index 0000000000000000000000000000000000000000..0637a088a01e8ddab3bf3fa98dbe804cbde1a0dc --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/staged/tvae/model_input_manifest.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/staged/tvae/model_input_manifest.json new file mode 100644 index 0000000000000000000000000000000000000000..daeb2bc660e9e321edfd0696d3d48311f9070c78 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_174228/public_gate/staged_input_manifest.json", + "train_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/train.csv", + "val_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/val.csv", + "test_csv": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/test.csv", + "features_json": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/staged/public/staged_features.json", + "public_gate_report": "/data/jialinzhang/SynthesizePipeline-server/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_174228/public_gate/public_gate_report.json" +} \ No newline at end of file diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv new file mode 100644 index 0000000000000000000000000000000000000000..1eef2401674d55c788c8457160db07fb3ca8f4e4 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae-c2-1382-20260504_174245.csv @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ed8d81c7986042bdc6d46d880cf4b8ecbb4ab544eed3754733fc1ee8424db47d +size 41641 diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae_metadata.json b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/tvae_metadata.json new file mode 100644 index 0000000000000000000000000000000000000000..183d627ebc98e89233655ec98c9dcbc528c4c328 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_174228/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_175027/_tvae_generate.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/_tvae_generate.py new file mode 100644 index 0000000000000000000000000000000000000000..8104879488e8e7e39b0f1ce35e55b7498a71c718 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/_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_175027/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_175027/tvae-c2-1382-20260504_175041.csv", index=False) +print(f"[TVAE] Generated {total} rows (chunks={len(parts)}) -> /work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_175027/tvae-c2-1382-20260504_175041.csv") diff --git a/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/_tvae_train.py b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/_tvae_train.py new file mode 100644 index 0000000000000000000000000000000000000000..cb7ef14cbfef58c7485e0f2c428a4de8aa54f4f7 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/_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_175027/staged/public/train.csv" +meta_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_175027/tvae_metadata.json" +save_path = "/work/output-Benchmark-trainonly-v1/c2/tvae/tvae-c2-20260504_175027/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_175027/gen_20260504_175041.log b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/gen_20260504_175041.log new file mode 100644 index 0000000000000000000000000000000000000000..fc18445fff6eeef90a8c0c788069fa1fc492dd49 --- /dev/null +++ b/SynthData0523/main/c2/tvae/tvae-c2-20260504_175027/gen_20260504_175041.log @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a01f4b4e5969a83ef737504dd36e3b52b491552504978f2029b415c1d0899625 +size 404