Comments (4)
I run some more experiments, following a similar setup to the one for recording the BioSemi device latencies:
- I used a Humisoft MF 624 DAQ card to produce a PWM pulse with a period of 250 ms and an amplitude of 50 mV
- The PWM was then inserted to:
- an A/D input of the DAQ card
- a channel of the BrainAmp amplifier.
- Both streams were recorded by LSL and an Event marker was sent by the A/D recording program when the voltage was sensed to be higher than 30 mV.
- The difference between the Event marker and the BrainAmp recordings is the delay caused by the Brain Amp.
The results are an average delay of 51.65 ms ranging from 50.4 ms to 53 ms. Following are the histograms of the delay of two tests I ran, a 3 min and a 6 min recording:
The good news is that the delays are within a range of 2.6 ms so by removing a known delay of 51.65 we can get accuracies of a bit more than 1 ms which is great.
However, the delays are exceptionally high, about an order of magnitude higher than the delays of BioSemi in comparison. Especially for use with BCI such delays are very problematic.
from lsl_archived.
ioannis,
It is unlikely that anything is not properly aligned at the importing stage. There is also some amount of software latency depending on you computer and OS etc. These latencies you report are not terribly outlandish given other measurements that I have seen and taken.
Having said that, 30-50ms in the eeg recording data does seem like a lot. One question, are the latencies consistent from method to method? E.g, does BrainVisionRDA.exe always come ~40ms late?
I have done a number of synchronization/latency experiments already, although not with the brainamp products. You can read about it here:
http://sccn.ucsd.edu/labinfo/SCCN_latencies/index.php
I will attempt to make my own measurements if I can find some brainamp equipment lying around somewhere.
Also, if the latencies are consistent, you can easily compensate for synchronization purposes. You can add a line to the xdf header (using the XDFBowser app) to account for lag time. See the 'IMPORTANT!!' section of this page:
http://sccn.ucsd.edu/labinfo/SCCN_latencies/biosemi.html
from lsl_archived.
David,
Thank you very much for your response.
A few comments based on your reply:
- I have run a couple of tests to identify the stability of the delay, depending on the method the range is between 10 - 20 ms. (Eg. BrainAmp.exe has a range of 10 ms from 23-33 ms)
- The actual delay is much larger. The hit event is already delayed by about 30 ms so the actual delay can be up to almost 100 ms depending on the method. (Eg. OVAS with size 8 chunks has delays in the range of 41- 62 ms with an effective delay of 70 - 90 ms)
- Part of the range of this delay is definitely due to Unity and the event recording as that code runs only at approx 250 Hz producing a +/- 5 ms range on when the hit event will be reported to LSL.
Based on the above my plan was to record with whatever method has the least delay (most likely BrainVisionRDA.exe because I encountered some clipping issues with BrainAmpSeries.exe) and then remove the average delay from the EEG stream. That should be good enough for my analysis.
However if there was any way of dropping that recording delay or at least identifying the cause would be nice. I understand that a delay of about 50 - 100 ms is not outlandish but it does seem a bit odd as I would expect something in the region of an order of magnitude less.
Again, thank you very much for your help.
from lsl_archived.
Nice work! As you say, the good news is that the delay is consistent and the jitter is small. 51.65ms is, unfortunately, a lot for BCI applications,
from lsl_archived.
Related Issues (20)
- How to change output dimension of inlet.pull_sample() HOT 5
- Default values for lsl_api.cfg are hard-coded and confusing HOT 1
- Which pylsl? HOT 3
- Cmake issue when build LabStreamingLayer application for Emotiv HOT 14
- Not reading serial data from Arduino
- LSL DLL on ARM64 Architecture HOT 4
- Can't Run LabRecorder App on Mac OS 10.13.4 HOT 1
- libjnidispatch.so? HOT 11
- Connection to smartphone HOT 1
- C++ 2015 professional and matlab 2015b HOT 1
- windows 10 LAN lsl fail HOT 7
- the trouble with __func__ HOT 9
- Firewall settings for LSL to work? HOT 2
- External native build issues while building LSL Android Studio examples HOT 4
- Errors when building BrainAmp App HOT 1
- Missing timeout parameter in C# binding for wait_for_consumers()
- BrainVisionRDA: compilation error (CMake on Windows) HOT 2
- pull_chunk starts and KEEPS returning empty after a short delay in stream AND stream is back HOT 1
- blocking call to pull_sample become unresponsive when no data available HOT 3
- How to load xdf multiple file ? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lsl_archived.