-
Notifications
You must be signed in to change notification settings - Fork 45
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
Trigger channel index is not incremented in acq populate_phys_input #272
Comments
Uh, this is indeed a bug. However, I'm not totally sure the proposed solution is the one we should be following. In fact, at a certain point we decided to switch to channel numbering starting from 1 to be human friendly, rather than from 0 (see here. We need to change the help description (it's wrong) and check that actually the attributes are ok. |
To clarify, would that mean that acq-generated objects have channels starting at 1 and txt-generated ones have channels starting at 0? |
They should all start at 1. |
@eurunuela do the tests (integration) work with that in mind? |
They should. That change was added some months ago already and I'm pretty sure @vinferrer updated the tests. |
So in theory the only thing we need to correct (or see it is correct) are the docstrings and the CLI, right? |
Sounds like that's right. |
The trigger index needs to be incremented down in the acq version of |
@tsalo I very honestly don't remember 🙈 . Let me try it out. |
@tsalo I hope that the bugfix I opened fixes it. |
Thank you @smoia. I've updated the post at the beginning of the thread to reflect the actual bug. The issue title is still mostly accurate, so I'm going to leave it for now. |
Updated Issue
The acq-generated
BlueprintInput
objects'trigger_index
attribute does not correspond to the actual trigger channel index.The trigger index needs to be incremented down in the acq version of
populate_phys_input()
.Original Issue
When time is added as a channel to the time series data, the trigger channel index needs to be incremented, or else it will not reference the trigger channel. This is done in the txt version of populate_phys_input, but not in the the acq version.
Expected Behavior
The
BlueprintInput
object created from reading in a.acq
file should have a.trigger_idx
attribute pointing to the trigger channel.Actual Behavior
BlueprintInput
objects initialized from.acq
files have.trigger_idx
attributes pointing to the channel right before the trigger channel.Steps to Reproduce the Problem
chtrig
argument from thepopulate_phys_input()
call to the.trigger_idx
attribute of the generatedBlueprintInput
object. It should have a value ofchtrig + 1
, notchtrig
.Specifications
Possible solution
Add 1 to chtrig when initializing the BlueprintInput object in the acq version of populate_phys_input.
The text was updated successfully, but these errors were encountered: