Add incremental training and related unit tests#445
Merged
Conversation
ashelkovnykov
left a comment
Contributor
There was a problem hiding this comment.
Looks good - let's begin testing (once unit/integ tests are fixed)
|
|
||
| private val OPTIMIZER_CONFIG = OptimizerConfig(OPTIMIZER_TYPE, MAX_ITER, TOLERANCE) | ||
| private val MOCK_NORMALIZATION = mock(classOf[NormalizationContext]) | ||
| private val MOCK_NORMALIZATION = mock(classOf[NormalizationContext], withSettings().serializable()) |
Contributor
There was a problem hiding this comment.
What was the reason for this change?
Collaborator
Author
There was a problem hiding this comment.
Integ test throws an error that MOCK_NORMALIZATION is not serializable. Original class NormalizatoinContext extends Serializable. Need to set MOCK_NORMALIZATION to be serializable as well.
junshi15
reviewed
Feb 7, 2020
8011006 to
d3c24eb
Compare
cmjiang
reviewed
Mar 6, 2020
cmjiang
reviewed
Mar 6, 2020
cmjiang
reviewed
Mar 6, 2020
cmjiang
reviewed
Mar 6, 2020
cmjiang
reviewed
Mar 6, 2020
cmjiang
reviewed
Mar 6, 2020
cmjiang
approved these changes
Mar 6, 2020
cmjiang
left a comment
Collaborator
There was a problem hiding this comment.
Great job! Thank you for adding incremental training to Photon ML. This is a big step forward!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes are:
(1) Add
PriorDistributionto implement incremental learning prior distribution loss function(2) Enable photon-ml to read variance vectors
(3) Add 2 new parameters: i. Boolean
incrementalLearningas the switch for incremental learning. ii.incrementalWeightto specify the importance of prior distribution.Current implementation only covers diagonal prior variance. For Full Hessian implementation, see #450