Skip to content

LFP Viewer support for low sampling rates#704

Merged
anjaldoshi merged 1 commit into
open-ephys:developmentfrom
roberttoth02:development
Jun 22, 2026
Merged

LFP Viewer support for low sampling rates#704
anjaldoshi merged 1 commit into
open-ephys:developmentfrom
roberttoth02:development

Conversation

@roberttoth02

Copy link
Copy Markdown

Resolves #703

  1. Ensures very low sampling rate streams are actually plotted along the window by introducing minimum buffer length
  2. Fixes time axis drift at low sampling rates by revising the subSampleOffset accumulation mechanism
  3. Adds linear interpolation between datapoints where points / pixels < 1.0
  4. Adds new unit test group targeting the above fixes

@anjaldoshi anjaldoshi self-requested a review June 22, 2026 20:27

@anjaldoshi anjaldoshi left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @roberttoth02,

Thanks a lot for digging into this and fixing the low-sample-rate issues in the LFP Viewer.

This PR looks great overall, and thanks for targeting the development branch. That helps a lot since we already have a few other LFP Viewer changes there. The timing is great too, since we’re hoping to ship v1.1.0 this week and we’d love to get this in.

I went through the code and the approach makes a lot of sense. We just haven’t had much opportunity to exercise the viewer with very low sample-rate data before, especially below 100 Hz.

I also tested this locally with the LSL Inlet plugin using pylsl to stream sine-wave data at low sampling rates. Just like you described in the issue, the current development behavior drifts quite a bit once the samples-per-pixel ratio drops below 1, and at 1 Hz it basically fails. With your changes, the drift looks fixed and the traces render much more naturally with the interpolation.

The new tests are a really helpful addition too.

Overall, this is a solid fix, and I’m glad we can get it into v1.1.0.

@anjaldoshi anjaldoshi linked an issue Jun 22, 2026 that may be closed by this pull request
@anjaldoshi anjaldoshi merged commit 43c94b0 into open-ephys:development Jun 22, 2026
5 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.

LFP Viewer issues at low sampling rates

2 participants