Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix flaky test and add random seed to have deterministic tests #199

Merged
merged 1 commit into from
Oct 1, 2024

Conversation

patricefortin
Copy link
Member

In some cases (non deterministic), test_filt was failing due to the strategy on PSD comparison.

The change here fix the test, and also add a random seed for which the test was failing.

@patricefortin
Copy link
Member Author

patricefortin commented Oct 1, 2024

This image shows the values of the sum of psd for the first frequencies, when the test is failing

plt.plot(np.arange(raw_psd.shape[1])[:10], np.sum(raw_psd, axis=0)[:10], label="raw")
plt.plot(np.arange(raw_filt_default_psd.shape[1])[:10], np.sum(raw_filt_default_psd, axis=0)[:10], label="filtered")
plt.legend()
plt.show()

image

@deep-introspection deep-introspection merged commit 0e111b8 into ppsp-team:master Oct 1, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants