Improve performance of early stop check in ES#168
Open
dpaetzel wants to merge 1 commit intoheidmic:masterfrom
Open
Improve performance of early stop check in ES#168dpaetzel wants to merge 1 commit intoheidmic:masterfrom
dpaetzel wants to merge 1 commit intoheidmic:masterfrom
Conversation
183be9b to
4c2c666
Compare
4c2c666 to
b69683f
Compare
Owner
|
David sent me preliminary results that the new version might actually be slower. @RomanSraj please test this on our typical problem sizes |
Collaborator
Author
|
I think the results of the very few tests (10 repetitions on a single problem instance) I ran are well within the range of “not faster or slower in a neither statistically nor practically significant way”. This change should thus probably be seen as nothing more but a small refactoring. |
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.
The early stopping check was previously implemented using a
dequewhich ultimately results inself.delaymany (typically hundreds) comparisons in each iteration. Now it's based on a counter since the last improvement which reduces the number of comparisons/updates to less than a handful.