Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a unified get_parameters method for all multi-table synthesizers #1674

Closed
npatki opened this issue Nov 13, 2023 · 0 comments · Fixed by #1679
Closed

Create a unified get_parameters method for all multi-table synthesizers #1674

npatki opened this issue Nov 13, 2023 · 0 comments · Fixed by #1679
Assignees
Labels
feature request Request for a new feature
Milestone

Comments

@npatki
Copy link
Contributor

npatki commented Nov 13, 2023

Problem Description

The multi-table synthesizers allow users to set and get parameters. Setting parameters must be different for the different synthesizers -- as each has different options based on the underlying algorithm. However, getting the parameters should be more consistent.

Expected behavior

All synthesizers should have a single method called get_parameters() that returns all the parameters used for the synthesizer. It should include:

  • Any parameters used during initialization (eg. locales, num_clusters, etc.)
  • A nested dictionary called 'tables' with settings specific to each table. The format of the dictionary would vary based on the type of multi-table algorithm.

The expected behavior is for the public-facing synthesizer only (HMA). We'll file a separate issue for HSA, Independent and DayZ (enterprise features).

# HMASynthesizer
>>> hma_synth.get_parameters()
{
  'locales': ['en_US', 'fr_CA'], # add the init params as top level
  'verbose': True,
  'tables': { # the table specific params are now in a nested dictionary
    'users': {
      'table_synthesizer': 'GaussianCopulaSynthesizer', # only possible synthesizer for HMA
      'table_parameters': { # add the table-level parameters here
        'enforce_min_max_values': False,
        'default_distribution': 'truncnorm',
      }
    }
  }
}

Additional context

The get_table_parameters should also be updated to provide the given table's parameter entry:

>>> hma_synth.get_table_parameters('users')
{
    'table_synthesizer': 'GaussianCopulaSynthesizer', # only possible synthesizer for HMA
    'table_parameters': { # add the table-level parameters here
      'enforce_min_max_values': False,
      'default_distribution': 'truncnorm'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Request for a new feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants