De-flake test_decimate_system#160
Merged
Merged
Conversation
The raw and decimated streams are logged by independent MessageLoggers, and the graph terminates on the output count (TERM watches LOGFILT), so the raw log can end a message or two ahead of the filtered log. `expected` (built from all raw samples) was then longer than `outputs`, intermittently failing the full-length np.allclose with a shape mismatch (e.g. (100,8) vs (120,8)) under CI load. The anti-alias filter is causal and zi-initialized, so each stream is a prefix of a longer run; compare only the overlapping prefix. This mirrors the truncation test_filter_system already applies for the same termination race.
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.
test_decimate_systemintermittently fails CI with a shape mismatch (e.g.(100,8)vs(120,8)) — the failure seen on PR #159, unrelated to that PR's changes.Cause: the raw and decimated streams are logged by two independent
MessageLoggers, and the graph is torn down on the output count (TERMwatchesLOGFILT). Under load the raw logger can capture a message or two more than the filtered logger, soexpected(built from all raw samples) ends up longer thanoutputs, and the full-lengthnp.allclosefails on shape.Fix: the anti-alias filter is causal and zi-initialized, so each stream is a prefix of a longer run — compare only the overlapping prefix. This is the same truncation
test_filter_systemalready applies for the identical termination race; this just brings the decimate test in line.No production code touched.
test_decimate_system+test_filter_systempass (14, run repeatedly).