-
Notifications
You must be signed in to change notification settings - Fork 6
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
split physioevents and events json #92
Conversation
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will try to make the test a bit more stringent
tests/test_edf2bids.py
Outdated
if ending == "_physio": | ||
assert len(df[0].diff().unique()) == 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
apparently this is failing for some data
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FAILED tests/test_edf2bids.py::test_edf_end_to_end - assert 5 == 1
+ where 5 = len(array([ nan, 2.00000e+00, 1.10336e+05, 1.76840e+04, 1.61320e+04]))
+ where array([ nan, 2.00000e+00, 1.10336e+05, 1.76840e+04, 1.61320e+04]) = unique()
+ where unique = 0 NaN\n1 2.0\n2 2.0\n3 2.0\n4 2.0\n ... \n531148 2.0\n531149 2.0\n531150 2.0\n531151 2.0\n531152 2.0\nName: 0, Length: 531153, dtype: float64.unique
+ where 0 NaN\n1 2.0\n2 2.0\n3 2.0\n4 2.0\n ... \n531148 2.0\n531149 2.0\n531150 2.0\n531151 2.0\n531152 2.0\nName: 0, Length: 531153, dtype: float64 = diff()
+ where diff = 0 3098681\n1 3098683\n2 3098685\n3 3098687\n4 3098689\n ... \n531148 4305123\n531149 4305125\n531150 4305127\n531151 4305129\n531152 4305131\nName: 0, Length: 531153, dtype: int64.diff
FAILED tests/test_edf2bids.py::test_edf_end_to_end_2eyes - assert 2 == 1
+ where 2 = len(array([nan, 1.]))
+ where array([nan, 1.]) = unique()
+ where unique = 0 NaN\n1 1.0\n2 1.0\n3 1.0\n4 1.0\n ... \n51668 1.0\n51669 1.0\n51670 1.0\n51671 1.0\n51672 1.0\nName: 0, Length: 51673, dtype: float64.unique
+ where 0 NaN\n1 1.0\n2 1.0\n3 1.0\n4 1.0\n ... \n51668 1.0\n51669 1.0\n51670 1.0\n51671 1.0\n51672 1.0\nName: 0, Length: 51673, dtype: float64 = diff()
+ where diff = 0 767979\n1 767980\n2 767981\n3 767982\n4 767983\n ... \n51668 819647\n51669 819648\n51670 819649\n51671 819650\n51672 819651\nName: 0, Length: 51673, dtype: int64.diff
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the the time stamp column contain nan?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it should not. It's kind of related to #69 where we said we would need an additional check to ensure that the timestamp in physio.tsv.gz is actually continuous because that might not be the case, at least for eyetrackers other than eyelink. Physioevents.tsv.gz should also not have NaNs in timestamp, but here it does not have to be continuous because a timestamp is only logged if there is an actual corresponding event.
So long story short, we need something checking that there are no NaNs for both, and a check for physio.tsv.gz that it's continuous.
some tests are failing because the timestamps of the output physio.tsv.gz are not continuous because eyetracker was probably turned on and off will need to be fixed as we resolve issue #69 |
See #90
Closes #90