-
Notifications
You must be signed in to change notification settings - Fork 191
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
Improve detect_bad_channels #2003
Improve detect_bad_channels #2003
Conversation
Add more chunk default computation.
for more information, see https://pre-commit.ci
chunk_duration_s=0.5, | ||
num_random_chunks=100, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would just increase the number of random chunks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The noisy channel are done on PSD. 300ms looks like quite short. I wanted to increase a bit.
where this 300ms comme from ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey both, this was the default from the IBL white paper (code here). In the context of the IBL pipeline PSD (I am not sure for the other methods in detect_bad_channels
), I do not think changing this would make too much difference. At 30 kHz sampling rate the FFT frequency bin-width of 300 ms trace would be 30k / 9k = 3.33 Hz vs. 2 Hz (using 500 ms). The main use of the PSD in the IBL function is to calculate the average power above 80% Nyquist. For example, the true 80% of Nyquist at 30 kHz that must be averaged over is the range 12-15000 Hz. This range would be something like 11997.99-14998.32 in practice with 3.33 Hz bins. So I don't think in this context at least it should matter much but I might have made an oversight / mistake.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JoeZiminski
I agree it won't change much. Instead we increased the number of chunks because we found that the method had quite large fluctuations with only 20 random chunks!
Co-authored-by: Alessio Buccino <[email protected]>
detect_bad_channels()