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

The GaussianNormalizer should accept distribution names that are consistent with scipy #656

Closed
npatki opened this issue Jun 22, 2023 · 0 comments · Fixed by #722
Closed
Assignees
Labels
feature request Request for a new feature
Milestone

Comments

@npatki
Copy link
Contributor

npatki commented Jun 22, 2023

Problem Description

The GaussianNormalizer accepts a distribution parameter, where you can provide a string name of the univariate distribution.

The acceptable strings are: 'gaussian', 'gamma', 'beta', 'student_t', 'truncated_gaussian' and 'gaussian_kde'

These names are inconsistent with both of the following:

  • The underlying scipy library where the univariates come from and
  • The SDV library which uses the same names as scipy.

Expected behavior

Change the mappings to the following:

  • 'norm' should be used for a Gaussian distribution
  • 'truncnorm' should be used for a truncated Gaussian Distribution
  • 't' should be used for Student T

Additional context

In order to keep backwards compatibility, we can still accept the older names. If a user inputs them, internally use the newer names and show a Future Warning.

# example: user inputs 'gaussian' instead of 'norm'
my_transformer = GaussianNormalizer(distribution='gaussian')

This ultimately uses the correct distribution but it shows a future warning.

FutureWarning: Future versions of RDT will not support 'gaussian' as an option. Please use 'norm' instead.
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