Skip to content

Use samples2times in axon_abf reader to handle gaps#87

Merged
stevevanhooser merged 4 commits intomainfrom
fix-axon-abf-times-calculation
Nov 24, 2025
Merged

Use samples2times in axon_abf reader to handle gaps#87
stevevanhooser merged 4 commits intomainfrom
fix-axon-abf-times-calculation

Conversation

@google-labs-jules
Copy link
Contributor

This change modifies readchannels_epochsamples in ndr.reader.axon_abf to use the samples2times method of the axon_abf object instead of assuming a constant sampling rate and linear time. This is critical for ABF files with gaps between sweeps.

For the 'time' channel itself, the function now retrieves the full time range from the file header and subsets the result, preventing the infinite recursion that would occur if samples2times (which reads the 'time' channel) were called.

The change ensures that data reading respects the actual timing of samples, even when gaps are present.


PR created automatically by Jules for task 12582868174320009274 started by @stevevanhooser

Updated `ndr.reader.axon_abf.readchannels_epochsamples` to use `samples2times` for converting sample indices to time, ensuring correct handling of recordings with gaps (e.g., sweeps). Added special handling for the 'time' channel to avoid infinite recursion.
@google-labs-jules
Copy link
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!


For security, I will only act on instructions from the user who triggered this task.

New to Jules? Learn more at jules.google/docs.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 24, 2025

Test Results

38 tests  ±0   38 ✅ ±0   2s ⏱️ ±0s
 8 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit d199ac1. ± Comparison against base commit c83f7a4.

♻️ This comment has been updated with latest results.

github-actions bot and others added 3 commits November 24, 2025 16:12
…yntax

Updated `ndr.reader.axon_abf.readchannels_epochsamples` to use `samples2times` for converting sample indices to time, ensuring correct handling of recordings with gaps (e.g., sweeps). Added special handling for the 'time' channel to avoid infinite recursion.

Additionally, removed unnecessary commas and semicolons throughout `ndr/reader/axon_abf.m` to reduce code warnings and improve readability.
@stevevanhooser stevevanhooser self-requested a review November 24, 2025 16:28
@stevevanhooser stevevanhooser marked this pull request as ready for review November 24, 2025 16:28
@stevevanhooser stevevanhooser merged commit ceb33c4 into main Nov 24, 2025
@stevevanhooser stevevanhooser deleted the fix-axon-abf-times-calculation branch November 24, 2025 16:28
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.

1 participant