Skip to content
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

Coarse labels sbj 1 session 7 do not match #2

Open
Giezzy opened this issue Jun 28, 2023 · 1 comment
Open

Coarse labels sbj 1 session 7 do not match #2

Giezzy opened this issue Jun 28, 2023 · 1 comment

Comments

@Giezzy
Copy link

Giezzy commented Jun 28, 2023

Following the Example_AJILE12_exploration jupyter notebook I was opening other subjects and sessions, when running sbj=1 and session=7 (all other parameters the same) the coarse labels contain timestamps which exceed the dimension of the ElectricalSeries.

For example

start_time      62612.333333
stop_time       62733.033333
labels        Computer/phone
diff                   120.7

After correcting for the sampling rate stop_time becomes 31.366.516, while the corresponding dataframe is only 27.858.793 long

@stepeter
Copy link
Contributor

stepeter commented Jul 3, 2023

Thank you for pointing out the discrepancy between coarse label and ECoG datastreams for this participant day. What is happening there is that the coarse labels are derived from video data that was recorded separately from the ECoG and the raw data were saved in separate files. For sbj 1, one of the ECoG data files was lost before we put together this dataset which is why there is no day 6 for sbj 1. Based on the session_start_time, the first ~8.5 hours of data are missing from the ECoG data. This also matches the number of missing hours of ECoG data if you look at the data size based on the 500 Hz sampling rate (shown below). The labeled video data was available for the entirety of day 7, so we included it all.

total_sec_per_day = 3600*24
ecog_day7_sec = len(nwb.acquisition['ElectricalSeries'].data)/500
hrs_missing = (total_sec_per_day - ecog_day7_sec)/3600

If you are looking to have the coarse labels aligned to the ECoG data, you can pad the ECoG data with NaNs during the first 8.5 hours (15341207 NaN columns to get the total to 43200000). Otherwise, you can just ignore the coarse labels during the first 8.5 hours because there is no corresponding ECoG data.

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

No branches or pull requests

2 participants