-
Notifications
You must be signed in to change notification settings - Fork 24
Description
Hi guys,
I found a difference in how load_xdf() function works in Python vs Matlab, and it seems there is something wrong with the Python implementation, particularly with the dejitter_timestamps parameter when set to True. I was using the function with default parameters, and while in Matlab it was working properly, in Python I received data streams that were misaligned.
How I found the bug:
I had multiple datastreams sent from 2 PCs into the Lab Recorder. The recording would start only when all of the streams were already visible, and the devices were actively streaming. I loaded the same xdf datafile into Python and Matlab and received 2 different outcomes - the time_stamps values were different, while the time_series values were the same in Python and Matlab. When loaded in Python, the timestamps of streams from 1st PC started ~46 seconds earlier than the streams from the second PC.
How I fixed it (temporarily):
What worked for me was setting the dejitter_timestamps parameter in the Python function to False. Then the data matched the data I had loaded in Matlab.
I attached the xdf file where the time difference between the streams (PolarBand and HMD) is ~46 seconds.