Danger

You are looking at the documentation for an older version of the SDV! We are no longer supporting or maintaining this version of the software

Click here to go to the new docs pages.

sdv.relational.hma.HMA1

class sdv.relational.hma.HMA1(metadata, root_path=None, model=None, model_kwargs=None)[source]

Hierarchical Modeling Algorithm One.

Parameters
  • metadata (dict, str or Metadata) – Metadata dict, path to the metadata JSON file or Metadata instance itself.

  • root_path (str or None) – Path to the dataset directory. If None and metadata is a path, the metadata location is used. If None and metadata is a dict, the current working directory is used.

  • model (type) – Class of the copula to use. Defaults to sdv.models.copulas.GaussianCopula.

  • model_kwargs (dict) – Keyword arguments to pass to the model. If the default model is used, this defaults to using a gaussian distribution and a FrequencyEncoder_noised transformer.

__init__(metadata, root_path=None, model=None, model_kwargs=None)[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

__init__(metadata[, root_path, model, …])

Initialize self.

fit([tables])

Fit this relational model instance to the dataset data.

load(path)

Load a model from a given path.

sample([table_name, num_rows, …])

Generate synthetic data for one table or the entire dataset.

save(path)

Save this instance to the given path using cloudpickle.

Attributes

DEFAULT_MODEL_KWARGS

metadata