Repository navigation
Parse EpochSection in ABF2 files to get digital output waveform info - #562
Conversation
|
Thanks for your contribution @erikli! |
|
Hello @erikli! Thanks for updating the PR.
|
|
@JuliaSprenger thanks for the advice! Looks like all checks now pass. Also just adding a note here to resolve the caveat I pointed out in my initial post for the pull request and provide some useful knowledge for anyone who might be trying to parse Axon ABF2 files. The information that you need to recapitulate the original stimulus waveform (both digital and analog) is contained in multiple places.
The current AxonIO.read_protocol() method utilizes a subset of these. In particular I know it doesn't consider What this commit provides is parsing of the ABF2 file header to populate |
|
@erikli The information in your previous comment is very useful. Could you put this information within the docstring for the |
|
I'd be happy to but it will probably take me until sometime at the end of this week or next weekend. I will do my best to follow the guidelines in https://neo.readthedocs.io/en/0.6/developers_guide.html#working-on-the-documentation but it will definitely warrant a bit of review as I have never written documentation that would be parsed by something like sphinx autodoc. |
|
I am not a user of clampfit so you are more expert that me here. As an author of AxonIO and AxonRawIO, the only thing I can say is : read_protocol is not garanty. Adding more thing to _axon_info info is really good. Feel free to also make modification on read_protocol and/or add warning/raise for uncorvered case. |
|
Can we merge ? |
|
Life has run away with me a bit so I haven't had time to make any of the
doc changes. It should be safe to merge, but none of the information from
my comments in this thread will be incorporated into the relevant
docstrings.
…On Mon, Oct 8, 2018 at 10:15 AM Garcia Samuel ***@***.***> wrote:
Can we merge ?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#562 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFYXE-Op23FpW16c_yeFDxsZ-e8RgZBQks5ui13pgaJpZM4WUPVS>
.
|
Noticed that there was an EpochInfoDescription block sitting around that wasn't being used, so I followed the format of the other sections to parse an 'EpochInfo' block into the ABF2 header. On initial inspection, it seems to work properly and I can see the digital output epochs.
A caveat is that each DAC channel can define it's own epoch durations and the EpochInfo returned doesn't provide a duration field. So for example, if Epoch A is defined as 1 second in CMD#0 and as 5 seconds in CMD#1, it isn't necessarily obvious which length the digital output pulse should be if you were to turn the EpochInfo section into a waveform. (Similar to how read_raw_protocol converts the dictEpochInfoPerDAC into a waveform). Still, I think that parsing the EpochInfo block is useful.