{"id":10220,"library":"sdv","title":"SDV: Synthetic Data Vault","description":"SDV (Synthetic Data Vault) is a Python library that allows users to generate synthetic data for various data types, including single tables, multi-table relational datasets, and sequential data. It provides a range of models and tools to create high-quality synthetic data that preserves the statistical properties and privacy of the original data. As of version 1.36.0, it continues to be actively developed, with a regular release cadence to add new features and improve existing models.","status":"active","version":"1.36.0","language":"python","source_language":"en","source_url":"https://github.com/sdv-dev/SDV","tags":["synthetic data","data generation","privacy","machine learning","tabular data","data science"],"install":[{"cmd":"pip install sdv","lang":"bash","label":"Install SDV"}],"dependencies":[],"imports":[{"note":"Synthesizers were moved out of 'sdv.models' in v0.17.0. Use 'sdv.single_table', 'sdv.multi_table', or 'sdv.sequential' depending on your data type.","wrong":"from sdv.models import GaussianCopulaSynthesizer","symbol":"GaussianCopulaSynthesizer","correct":"from sdv.single_table import GaussianCopulaSynthesizer"},{"note":"The 'sdv.lite' module was deprecated and removed. Presets are now found directly under the respective data type modules.","wrong":"from sdv.lite import SingleTablePreset","symbol":"SingleTablePreset","correct":"from sdv.single_table.preset import SingleTablePreset"},{"symbol":"load_dataset","correct":"from sdv.datasets.demo import load_dataset"}],"quickstart":{"code":"import pandas as pd\nfrom sdv.single_table import GaussianCopulaSynthesizer\nfrom sdv.datasets.demo import load_dataset\n\n# 1. Load a demo dataset (returns an SDVData object with data and metadata)\nreal_data = load_dataset('PUMS')\n\n# 2. Initialize a synthesizer, passing the metadata\nsynthesizer = GaussianCopulaSynthesizer(metadata=real_data.metadata)\n\n# 3. Fit the synthesizer to the real data\nsynthesizer.fit(real_data.data)\n\n# 4. Sample synthetic data\nsynthetic_data = synthesizer.sample(num_rows=len(real_data.data))\n\nprint(\"Original data head:\")\nprint(real_data.data.head())\nprint(\"\\nSynthetic data head:\")\nprint(synthetic_data.head())","lang":"python","description":"This quickstart demonstrates how to load a demo dataset, initialize a `GaussianCopulaSynthesizer` with the dataset's metadata, fit the synthesizer to the real data, and then sample synthetic data. This is a common workflow for single-table synthetic data generation."},"warnings":[{"fix":"Update your imports. For single-table synthesizers, use `from sdv.single_table import ...`. For multi-table, `from sdv.multi_table import ...`, and for sequential, `from sdv.sequential import ...`.","message":"Synthesizer import paths were changed in SDV v0.17.0. The `sdv.models` and `sdv.tabular` modules were removed.","severity":"breaking","affected_versions":"<0.17.0"},{"fix":"Manually create and pass `SingleTableMetadata` or `MultiTableMetadata` objects. Define primary keys, relationships, data types, and potentially privacy considerations explicitly for best results.","message":"While SDV can infer metadata, explicit metadata definition is often crucial for higher quality synthetic data, especially with complex schemas or specific data types (e.g., primary keys, relationships, sensitive columns).","severity":"gotcha","affected_versions":"All versions"},{"fix":"Consider downsampling your data for initial experimentation. Ensure your environment has sufficient RAM. For production-scale needs, explore SDV's performance optimization features or consider distributed processing frameworks if applicable.","message":"Generating synthetic data for very large datasets (millions of rows) or complex multi-table schemas can be memory-intensive and time-consuming.","severity":"gotcha","affected_versions":"All versions"}],"env_vars":null,"search_vec":"'1.36.0':64 'activ':69 'add':77 'allow':14 'cadenc':75 'continu':66 'creat':44 'data':3,7,19,22,34,49,60,85,86,92,93 'dataset':31 'develop':70 'exist':82 'featur':79 'generat':17,87 'high':46 'high-qual':45 'improv':81 'includ':24 'learn':90 'librari':12 'machin':89 'model':40,83 'multi':28 'multi-t':27 'new':78 'origin':59 'preserv':51 'privaci':56,88 'properti':54 'provid':36 'python':11 'qualiti':47 'rang':38 'regular':73 'relat':30 'releas':74 'scienc':94 'sdv':1,5 'sequenti':33 'singl':25 'statist':53 'synthet':2,6,18,48,84 'tabl':26,29 'tabular':91 'tool':42 'type':23 'user':15 'various':21 'vault':4,8 'version':63","created_at":"2026-04-17T01:22:59.809205+00:00","updated_at":"2026-04-17T01:22:59.809205+00:00","problems":[{"fix":"Change your import statement from `from sdv.models import SynthesizerName` to `from sdv.single_table import SynthesizerName` (or `multi_table`/`sequential` as appropriate).","cause":"Attempting to import a synthesizer from an old module path that was removed in SDV v0.17.0.","error":"ModuleNotFoundError: No module named 'sdv.models'"},{"fix":"Preprocess your data to convert unsupported columns into one of the supported types. Explicitly define column types in your `sdv.metadata` object to guide the synthesizer.","cause":"SDV synthesizers have limitations on the types of data they can process directly (e.g., complex objects, nested lists, mixed types), or metadata inference incorrectly assigned a type.","error":"ValueError: The column '...' contains unsupported data types. Supported data types are numeric, boolean, datetime, and categorical."},{"fix":"Ensure your training data has a sufficient number of rows (typically several dozens or hundreds at minimum, depending on complexity) to provide enough statistical information for the model. SDV is not designed for extremely small datasets.","cause":"The input dataset provided to `synthesizer.fit()` has too few rows for the selected synthesizer to effectively learn the underlying data patterns and statistical distributions.","error":"NotEnoughDataError: Not enough data for synthesizer to learn from. Expected at least X rows but got Y rows."}],"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"1.37.1","cli_name":"","cli_version":null,"type":"library","homepage":"https://docs.sdv.dev","github":"https://github.com/sdv-dev/SDV","docs":null,"changelog":"https://github.com/sdv-dev/SDV/blob/main/HISTORY.md","pypi":"https://pypi.org/project/sdv/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["data","ai-ml"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-06-28","last_verified":"2026-06-28","next_check":"2026-07-28","install_tag":null}}