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

Include validation check for single table auto_assign_transformers #2021

Merged
merged 3 commits into from
May 24, 2024

Conversation

lajohn4747
Copy link
Contributor

resolves #1509
CU-85ztjjzrw

Include better messsaging for auto_assign_transformers by checking metadata and data before going through assigning the transformers.

@lajohn4747 lajohn4747 requested a review from a team as a code owner May 21, 2024 00:10
@sdv-team
Copy link
Contributor

pvk-developer
pvk-developer previously approved these changes May 22, 2024
@pvk-developer pvk-developer dismissed their stale review May 22, 2024 14:03

Does this work for multi table?

@lajohn4747
Copy link
Contributor Author

Does this work for multi table?

Yes it does, I added a test to multitable to confirm it as well. Multitable synthesizer handles auto_assign_transformer at the table level which happens to call the single table auto_assign_transformer function

Copy link
Contributor

@R-Palazzo R-Palazzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

I just have one question

tests/unit/single_table/test_base.py Outdated Show resolved Hide resolved
tests/unit/single_table/test_base.py Show resolved Hide resolved
sdv/single_table/base.py Outdated Show resolved Hide resolved
@lajohn4747 lajohn4747 requested a review from R-Palazzo May 22, 2024 15:43
@@ -32,7 +32,7 @@ def get_metadata(self, add_sequence_key=True, add_sequence_index=False):

def get_data(self):
data = pd.DataFrame({
'time': [1, 2, 3],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually use datetimes as now auto_assign_transformer will validate this data which would error out. It should be date-time anyway

@lajohn4747 lajohn4747 requested review from amontanez24 and pvk-developer and removed request for pvk-developer May 24, 2024 16:24
@lajohn4747 lajohn4747 merged commit ce93711 into main May 24, 2024
39 checks passed
@lajohn4747 lajohn4747 deleted the issue_1509_better_validation branch May 24, 2024 17:46
@lajohn4747 lajohn4747 added this to the 1.13.2 milestone Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Better data validation message for auto_assign_transformers
5 participants