[Eeglablist] Weird Patterns in the Data: Bad Power or Ground?

Malte Anders malteanders at gmail.com
Mon Jan 27 10:54:25 PST 2020


Hello Nathan, and welcome to the club I call "ground loop victims"

Your data looks oddly familiar. I have recycled a garbage-EEG from 2017
when I was facing the problem myself: https://imgur.com/X4gRhgd . This
looks pretty similiar to your EEG in the marked patterns:
https://imgur.com/n5U2szz .

In my case, I was facing the same problem. I had connected another device
to the subject (in my case, a Medoc Pathway thermal sensory testing
device). As soon as the subject touched the thermode and the Medoc Pathway
was heating up ("Trigger 14" in my EEG), I've seen some nonsense spikes,
followed by some seconds of all channels going flat.
Once I removed the thermode, everything was fine again.

This is just my explanation approach, please correct me if I am wrong:
In your case, you don't have a Medoc Pathway, but at least 2 g.USBamps
connected to the subject that create a ground loop. You have grounded the
subject using the master gamma.box ground. However, your 4 g.USBamps are
also connected to the same ground. Your 4 g.USBamps have - by their nature
- a different ground reference potential. Somehow this creates a ground
loop, rendering your data useless.
Hence: as soon as more hardware than 1 EEG amplifier is connected to the
subject, the subject should be grounded at the most far away point
possible, which is the ground point even before your headbox (the one of
the power line). If its not, this ground loops leads to failing common mode
rejection, and the readings you get are potential differences created in
the ground wire, not the actual EEG potential on the head.
In other words: what you are recording now it the potential difference
between 4 g.HIamps connected to the same ground wire and not the potential
difference between your measuring electrode and your reference electrode.
Your potential difference between 4 devices of the same nature isn't as big
as mine: You're measuring 300-500 µV (which is still far away from the
physolocigal range somewhere in the 20-100 µV range). If you look at my
data, I have been measuring several mV of difference, which is even more
nonsense. I had, however, connected two different devices (EEG amp and
thermal sensory testing device) to the same subject.

I don't know if that explanation makes sense, but what that means in
practical terms is:
Connect all 4 g.USBamps and connect one electrode of each amp to your
forearm, head or any other body site (we don't need an actual EEG for
testing purposes).
Start recording and enjoy the nonsense data.
Now, touch the ground spot of your power outlet (NOT the L or N
wire!!!!!!!). The data should magically transform into readings that don't
flatline every other second. Once you stop touching the power outlet
groundings, you have garbage again.

Your two options here are to either create a stable grounding connection to
the subject using one wire with one end connected to a grounding pole (e.g.
solder it to the grounding wire of your multicontact plug or anything that
doesn't look like a 3 year old has been fiddling with electronics) and the
other one to any body site of the subject (in our experiment, we tried ESD
wrist straps that were connected to ground, but the contact of those is to
loose to hold throughout the experiment. We ended up giving the subjects a
blank copper wire to hold throughout the recordings...). Or you can - as
you definitely have 16 individual grounds with 4 amps - connect all 16
grounds to the subjects, although I doubt this is a practical approach.

Message me with your results, we have this sorted out in no time. And sorry
for all this text, I still struggle in keeping my texts short...

Malte Anders

Am Mo., 27. Jan. 2020 um 18:49 Uhr schrieb Nathan Sanders <nesander at ncsu.edu
>:

> Hey Malte,
>
> Thanks so much for responding! It feels like I have just been thrown a
> lifeline.
>
> First, here are some pictures. This <https://imgur.com/ZGQqano> is 64
> channel data after filtering but before re-referencing to average. Here
> <https://imgur.com/HRW4S0T>'s how it looks after you re-reference it. See
> how the channels are grouped in 4s? Those channels (1-4, 5-8, etc)
> correspond to the A, B, C, and D blocks on each amp. That's what led me to
> suspect a ground issue, like maybe these independent blocks which are
> supposed to be referenced to the same ground potential actually are not
> (Actually I am not quite sure how the electronics are connected under the
> hood). Also, the data turns out to be nonsense. I have also had a
> coincidental experience similar to yours -- I can get good data from a
> single 16-channel amp, but if I bridge the ground connections with a jumper
> cable to another amp which is turned on, then the data goes flat. To answer
> some of your other questions:
>
> The g.USBamp seems to have 4 ground connectors, so with 4 amps you have 16
>> ground connectors... Do you have all of those connected to the subject?
>>
>
> Someone from g.tec told me to just connect the ground connections on the D
> blocks together, and someone else in my lab told me to just connect the A
> blocks together. You're saying maybe I should connect them all? I can try
> that. I guess normally the subject would be grounded via the ground
> electrode that is connected to the master gamma.box which is in turn
> connected to the master amplifier, whose ground connection is connected to
> the other 3 amplifiers via the jumper cable in the D block.
>
> The reason for this: g.Tec hardware gets exremly picky if one electrode
>> fails.
>>
>
> You're saying that this could be a result of a bad electrode?
>
> I will take your advice and read that wiki article. I am going to try
> setting up the system in another room (connected to a different circuit
> breaker) and try your suggestions regarding grounding. Again, thank you so
> much for taking the time to help! I can't tell you how much I appreciate it.
>
> Sincerely,
>
> Nathan
>
> On Mon, Jan 27, 2020 at 11:56 AM Malte Anders <malteanders at gmail.com>
> wrote:
>
>> Hello Nathan,
>>
>> good to see somebody struggling with gTec Equipment and power line issues
>> as well. I have been struggling in 2017 to get our g.HIamp going as we had
>> huge power line artifacts. I have spammed the EEGLAB list with walls of
>> text as well, but then solved the problem by complete coincidence when I
>> actually touched a ground connector while having the EEG mounted to myself.
>> Keep in mind that I could not see your EEG-Data as the EEGLAB list does
>> not allow email attachments, you can however email me the Image directly
>> and also send an imageshack-link or something like that to the list so
>> everybody can see.
>>
>> Here are my 2 cents for your problem: I think your subject is not
>> properly grounded. The g.USBamp seems to have 4 ground connectors, so with
>> 4 amps you have 16 ground connectors... Do you have all of those connected
>> to the subject?
>> Some suggestions:
>>
>> -I know that some people might think this is stupid, but try to connect
>> the subject to the same ground as the amps. You can snitch a ground wire
>> directly from the power outlet (dangerous!) or maybe from some medical
>> equipment that is also connected somewhere in the room. For starters, a
>> bare wire that is connected to a ground connection on the one end and the
>> blank part of the other end is held by the subject in his/her hand is
>> sufficient.
>> Ground connections do look like this:
>> https://www.mikrocontroller.net/attachment/246107/bild1.jpg
>> This is the symbol for protective earth inputs:
>>
>> https://cdn3.iconfinder.com/data/icons/electronic-with-circle/64/ground-512.png
>> In my case, the EEG recording looked like garbage when I tried recording
>> without any further grounding measures. As soon as the subject simply
>> touched any grounding spot in the room, the magic happened and boom, the
>> EEG looked beautiful. Without proper grounding, common mode rejection fails
>> and in this case it would be helpful to see your actual recording images.
>>
>> -Connect only one (!) electrode to each amp, so 4 electrodes in total.
>> Then connect all the corresponding 4 ground wires from the amps. You should
>> now have connected 8 electrodes to the patient, 4 regular ones and 4
>> ground. I don't know if the g.USBamp allows you to record like this but
>> with the HIamp its possible, as the ground wire is then used as reference
>> electrode. If you need to specify another reference electrode, connect 4
>> more electrodes that correspond to the same ground wires you have
>> connected. Either way, try to record with as little electrodes connected to
>> the amps as possible (8 or 12) and look if the data looks better. The
>> reason for this: g.Tec hardware gets exremly picky if one electrode fails.
>> In the g.HIamp, if one electrode is broken, you _seem_ to get good data but
>> the output is completly nonsense. There is no way to know if one electrode
>> has failed other than doing impendance measurements from time to time (all
>> black: please find the on electrode out of 64 that screws up everything,
>> have fun) or having a close look at the amplitude values. With the g.HIamp,
>> amplitude values of 1 µV or less (even nV are plotted) are a good indicator
>> that one of your expensive electrodes went bad.
>>
>> -Does the g.USBamp provide an interface for impendance measurements? If
>> yes, what are the results? Do you get any readings or does impendance
>> measurement fail?
>>
>> Heres some further reading:
>> https://en.wikipedia.org/wiki/Ground_loop_(electricity)
>>
>> Keep me posted, we'll figure this out. I've been through a lot with g.Tec
>> hardware, the only good news is: once its up and running, you'll get really
>> good data.
>>
>> Am Mo., 27. Jan. 2020 um 17:20 Uhr schrieb Nathan Sanders <
>> nesander at ncsu.edu>:
>>
>>> Hey Everyone,
>>>
>>> I am in the middle of trying to diagnose what I think is some sort of
>>> hardware issue and I could use the benefit of your experience. I
>>> apologize
>>> for the wall of text but please bear with me!
>>>
>>> Backstory: originally I had all four of our 16-channel g.USBamps plugged
>>> into a single AC adapter with a four-way splitter. I have been able to
>>> get
>>> really nice data in the past, but recently channels have begun to
>>> flatline
>>> one after another until they were all flat. This intermittent problem has
>>> been getting steadily worse until a few days ago I couldn't get any
>>> signal
>>> at all. So I replaced the sync cables, but that did not solve the
>>> problem.
>>> I then discovered that this flatline problem would *not* occur if I only
>>> tried to collect data from one amp at a time (16 channels).
>>> Interestingly,
>>> the problem would come back if I turned on another amp (even if I was
>>> still
>>> only collecting data from the first amp), but it would go away again if I
>>> disconnected the ground jumper between the two (even if the second amp
>>> remained on). That led me to think that maybe our AC adapter was going
>>> bad
>>> or had a bad ground. We had three spares, so I tried hooking up the
>>> master
>>> amp with the suspected bad adapter, and the other three slave amps with
>>> the
>>> spare adapters. I was able to get a signal in all 64 channels
>>> (progress!).
>>> I recorded 5 minutes of resting state data as a test and this is what it
>>> looked like (see two attached photos)...
>>>
>>> data_filt_noreref.png shows what the data looked like right after
>>> filtering, *but before re-referencing to average*. All the channels look
>>> suspiciously correlated.
>>>
>>> After re-referencing to average, an interesting pattern emerges. You can
>>> see that the correlation pattern appears in groups of four channels.
>>> These
>>> channels correspond to the A, B, C, and D groups in each amplifier.
>>>
>>> I ran ICA and did not see anything that looked like a brain source.
>>>
>>> At first I thought maybe I had the channel locations mapped incorrectly,
>>> but I double checked and they are correct. I now think it has something
>>> to
>>> do with the AC adapter -- maybe it's failing or there is a bad ground or
>>> something and it is somehow contaminating the signals via the ground
>>> jumper. I know that bad power supplies and grounds can cause weird
>>> problems
>>> with computers and ham radio equipment...
>>>
>>> Has anyone ever seen anything like this? Any comments or suggestions
>>> would
>>> be greatly appreciated. Maybe they will be useful to someone in the
>>> future
>>> as well.
>>>
>>> Thanks as always,
>>>
>>> Nathan
>>> _______________________________________________
>>> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
>>> To unsubscribe, send an empty email to
>>> eeglablist-unsubscribe at sccn.ucsd.edu
>>> For digest mode, send an email with the subject "set digest mime" to
>>> eeglablist-request at sccn.ucsd.edu
>>>
>>
>>
>> --
>> Mit freundlichen Grüßen,
>>
>> Malte Anders
>>
>

-- 
Mit freundlichen Grüßen,

Malte Anders



More information about the eeglablist mailing list