Attempt to fix hooks using first keyframe at first step of second sampler #6185
+6
−2
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.
Attempts to resolve #6183
This fixes the issue where hooks incorrectly use the first keyframe during the first step of a second sampler pass as described in the original issue's workflow. Workflows that sample through all sigmas are not affected by this change.
Unfortunately, I don't believe this resolves the issue entirely, as it still has to invoke the ModelPatcher at the first step of the second sampler pass when it should not be necessary, and while the results are much closer to being identical than before, it still is ever so slightly off. Regardless, I'm opening this PR for further dissection and maybe as a temporary fix until it is properly resolved.
Result of this PR (compare to result 1 in the aforementioned issue)