refactoring noise_schedule and time schedule into base class#1736
refactoring noise_schedule and time schedule into base class#1736manuelgloeckler merged 38 commits intomainfrom
Conversation
- created noise_schedule method to be overwritten by derivatives - created times_schedules method to be overwritten by derivatives - created test on times_schedules - improvded docstrings
- added tests too - inspired by https://arxiv.org/abs/2206.00364
in addition: - added improved version to benchmarks (for later comparison) - created new class ImprovedVPScoreEstimator
to understand how the VE estimator is implemented
- without touching the forward function of ConditionalScoreEstimator - benchmarks show that this leads to very long training time without any performance improvements
…e_schedules-1437 Resolved the merge conflicts by aligning the score estimator with the vector-field API changes from main and accepting the deletions of legacy score/NPSE paths. Details: - Cleaned and reconciled ConditionalScoreEstimator imports/init and typing in sbi/neural_nets/estimators/score_estimator.py, keeping beta_min/beta_max and device tracking consistent with the new base. - Dropped deleted legacy files to match main: sbi/inference/trainers/npse/npse.py, sbi/neural_nets/net_builders/score_nets.py, and tests/score_estimator_test.py.
|
And here's a quick review by SummaryThe PR centralizes time/noise schedule logic in Blocking issues
Non-blocking but important
TestsThe issue requests tests for both schedules, but this PR only changes
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1736 +/- ##
==========================================
- Coverage 88.51% 88.39% -0.13%
==========================================
Files 137 137
Lines 11527 12188 +661
==========================================
+ Hits 10203 10773 +570
- Misses 1324 1415 +91
Flags with carried forward coverage won't be shown. Click here to find out more.
|
|
when comparing to the plan in the original issue #1437 , I noticed that there are still a couple of open todos, for the general API ideas and for the schedule from EDM paper in particular. Accordingly, here is a potential plan for finishing this PR:
|
…o unify training in vftrainer class
|
Hi @touronc Thank you for the updates here - looks very good. I tested this locally and found some issues and suggest fixes below. I just saw that you pushed some fixes already recently, so some of the comments below will be obsolete. 1.
|
manuelgloeckler
left a comment
There was a problem hiding this comment.
Great, love it. Thanks for finishing this up.
I think e.g. for VE variants it would be beneficial to do some EDM like train and solve schedule, but this is another project which would need some benchmarking. So will also approve this to get it merged.
This is the conflict-free version of #1481 by @psteinb. I merged
mainin, resolved the conflicts and moved onto this new branch to enable others to continue this work.@psteinb I hope this is fine for you - all your commits are still here and attributed to you.
times_schedulenoise_scheduleThis addresses #1437