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

Fixed version transformation to accept user configs without ludwig_version #2424

Merged
merged 17 commits into from
Sep 1, 2022

Conversation

tgaddair
Copy link
Collaborator

@tgaddair tgaddair commented Aug 27, 2022

Without this change, there is no opportunity to provide a deprecation period for user configs that lack the ludwig_version param inserted as part of config rendering.

Also adds additional tests around early stopping, automl, backwards compatibility, and version transformation ordering.

@tgaddair tgaddair requested a review from connor-mccorm August 27, 2022 17:30
@tgaddair tgaddair changed the title Fixed early_stop default when hyperopt scheduler is provided Fixed version transformation to accept user configs without ludwig_version param Aug 27, 2022
@tgaddair tgaddair changed the title Fixed version transformation to accept user configs without ludwig_version param Fixed version transformation to accept user configs without ludwig_version Aug 27, 2022
@tgaddair tgaddair requested review from dantreiman and removed request for connor-mccorm August 27, 2022 18:30
@github-actions
Copy link

github-actions bot commented Aug 27, 2022

Unit Test Results

         6 files  +       1         6 suites  +1   3h 12m 30s ⏱️ + 1m 40s
  3 367 tests +       4  3 272 ✔️ +       4    95 💤 ±  0  0 ±0 
10 101 runs  +3 244  9 812 ✔️ +3 171  289 💤 +73  0 ±0 

Results for commit 4f5d19c. ± Comparison against base commit 188f48c.

♻️ This comment has been updated with latest results.

ludwig/api.py Outdated Show resolved Hide resolved
@@ -81,20 +81,17 @@ def wrap(fn: Callable[[Dict], Dict]):

def upgrade_to_latest_version(config: Dict):
"""Updates config from an older version of Ludwig to the current version. If config does not have a
"ludwig_version" key, no updates are applied.
"ludwig_version" key, all updates are applied.
Copy link
Contributor

Choose a reason for hiding this comment

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

In line 1361 of api.py LudwigModel.load() I added a similar condition: if no version in config, assume an old version. At this time I was thinking we should upgrade on load but error on init for old configs. On second thought, I agree this is better... and with this change the condition in api.py load() should be removed.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Thanks! Removed code at line 1361.

tgaddair and others added 2 commits August 30, 2022 12:05
Co-authored-by: Daniel Treiman <dan.treiman@gmail.com>
@tgaddair tgaddair merged commit 96e22f7 into master Sep 1, 2022
@tgaddair tgaddair deleted the fix-early-stop branch September 1, 2022 06:28
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.

2 participants