OSC Streaming vs Recording Data Discrepancy

Post Reply
alnasir43
Posts: 3
Joined: Tue Mar 30, 2021 9:00 pm

OSC Streaming vs Recording Data Discrepancy

Post by alnasir43 »

Hi,

I'm wondering what is the difference between the raw data obtained via OSC streaming and the raw data obtained through recording? My assumption was that these two should produce identical data but I'm finding it is not the case. Can anyone shed some light?
User avatar
James
Site Admin
Posts: 1109
Joined: Wed Jan 02, 2013 9:06 pm

Re: OSC Streaming vs Recording Data Discrepancy

Post by James »

Set the "Recording Interval" to "Constant" and the RAW EEG will match.
Because all values are written on each line as a requirement of the CSV format, you'll get duplicate data on all other values due to the slower data rate. For example, absolutes are calculated at 10Hz.
You can find the data rates in the OSC spec here: https://mind-monitor.com/FAQ.php#oscspec

OSC on the other hand, streams each value type independently, so you can for example get 256Hz RAW EEG and 10Hz Absolutes.

If you want to record all the data exactly as in the OSC stream with each data type being written at it's independent data rate, then you can record in ".Muse" format (Switch formats in settings). This creates a Google Protocol Buffer file, which was the file format that Interaxon originally used with their now discontinued Muse Lab toolset.
alnasir43
Posts: 3
Joined: Tue Mar 30, 2021 9:00 pm

Re: OSC Streaming vs Recording Data Discrepancy

Post by alnasir43 »

Thanks for the reply!

I do have recording interval at 'constant'. I'm not worried about other values since I'm only focused on the raw. I guess my question is more along the lines of how do I get OSC to produce the exact same data as from the recording. Beyond matching frequencies would there be any difference in the voltage values themselves?

To give a brief background on my question, I'm conducting a simple machine learning exercise involving feature extraction from eeg signals. However, the model only seems to perform well with recorded data, and not with the data I obtain from the OSC.
User avatar
James
Site Admin
Posts: 1109
Joined: Wed Jan 02, 2013 9:06 pm

Re: OSC Streaming vs Recording Data Discrepancy

Post by James »

The recorded RAW EEG and Streamed RAW EEG values will be identical at the "Constant" recording rate.

If you go into settings you can turn on "Marker Buttons". This will give you five numbered buttons that you can use to inject a numbered marker into both the OSC and recorded stream to help sync.
alnasir43
Posts: 3
Joined: Tue Mar 30, 2021 9:00 pm

Re: OSC Streaming vs Recording Data Discrepancy

Post by alnasir43 »

Thanks again for the reply.

It still doesn't seem to sync up. Is the OSC stream 220 Hz by default or 256? I noticed there are two values on the OSC stream spec.
User avatar
James
Site Admin
Posts: 1109
Joined: Wed Jan 02, 2013 9:06 pm

Re: OSC Streaming vs Recording Data Discrepancy

Post by James »

220Hz for the 2014 Muse, 256Hz for all the later versions.
Are you sure you've got all the OSC data? It's UDP, so you might have dropped some packets.
Email me some samples and I'll take a look.
Post Reply