Automated detection and labeling of high-density EEG electrodes from structural MR images

Objective. Accurate knowledge about the positions of electrodes in electroencephalography (EEG) is very important for precise source localizations. Direct detection of electrodes from magnetic resonance (MR) images is particularly interesting, as it is possible to avoid errors of co-registration between electrode and head coordinate systems. In this study, we propose an automated MR-based method for electrode detection and labeling, particularly tailored to high-density montages. Approach. Anatomical MR images were processed to create an electrode-enhanced image in individual space. Image processing included intensity non-uniformity correction, background noise and goggles artifact removal. Next, we defined a search volume around the head where electrode positions were detected. Electrodes were identified as local maxima in the search volume and registered to the Montreal Neurological Institute standard space using an affine transformation. This allowed the matching of the detected points with the specific EEG montage template, as well as their labeling. Matching and labeling were performed by the coherent point drift method. Our method was assessed on 8 MR images collected in subjects wearing a 256-channel EEG net, using the displacement with respect to manually selected electrodes as performance metric. Main results. Average displacement achieved by our method was significantly lower compared to alternative techniques, such as the photogrammetry technique. The maximum displacement was for more than 99% of the electrodes lower than 1 cm, which is typically considered an acceptable upper limit for errors in electrode positioning. Our method showed robustness and reliability, even in suboptimal conditions, such as in the case of net rotation, imprecisely gathered wires, electrode detachment from the head, and MR image ghosting. Significance. We showed that our method provides objective, repeatable and precise estimates of EEG electrode coordinates. We hope our work will contribute to a more widespread use of high-density EEG as a brain-imaging tool.

(Some figures may appear in colour only in the online journal)

Introduction
Electroencephalography (EEG) is an electrophysiological technique that permits to record neuronal activity over the scalp. Given its high temporal resolution, it is widely used to investigate the dynamics of brain activity, both in health and disease (Chen et al 2008, Brodbeck et al 2011. Most recently, the availability of EEG systems with high electrode density (number of channels >100) has substantially improved the spatial localization of brain activity sources (Lantz et al 2003). This progress has opened new opportunities for achieving substantially higher spatio-temporal accuracy (Dale and Halgren 2001, Lopes da Silva 2004, He et al 2011, Michel and Murray 2012 making EEG an attractive tool for the noninvasive study of brain activity and connectivity in the human brain (Lantz et al 2003, Michel et al 2004, Brodbeck et al 2011, Song et al 2015. Accurate information about how neuronal activity propagates from the brain to the sensors, which is typically referred to as EEG forward solution, is key for the localization of brain activity using high-density EEG. Electrode coordinates are detected in the sensor space and registered to a head model, which is generated from a magnetic resonance (MR) image and defines the source space. Notably, inaccurate information on EEG electrode coordinates may affect the EEG forward solution, hence neural source imaging (Khosla et al 1999).
Several methods for estimating the EEG sensor locations have been developed over the years. Classical techniques include manual delineation as well as electromagnetic or ultrasonic digitization. All of these are primarily based on the selection of anatomical landmarks or fiducial points, such as nasion, pre-auricular points, vertex and inion (Koessler et al 2007). The identification of landmarks can permit to estimate the positions of the remaining electrodes, using information from a standard EEG montage (De Munck et al 1991, Le et al 1998. However, this estimation is prone to errors, which may arise from the non-optimal application of the net on the subject's head, such as stretched, and/or asymmetric net positioning, or erroneous definition of anatomical landmarks. Electromagnetic and ultrasound digitization techniques are potentially more precise than the manual approach, and permit to acquire three-dimensional information about electrode positions in addition to the anatomical landmarks (Tucker 1993, Le et al 1998, He and Estepp 2013. However, there are a number of disadvantages related to these two techniques, such as sensitivity to the environmental conditions and the time-consuming detection process. Furthermore, since the subject is allowed to move the head during the digitization process, localization errors due to head movements should be considered. These could be limited by putting a stabilizer on the head, but this is rarely done in the practice because it may be uncomfortable for the subject (Le et al 1998). Overall, digitization techniques are time-consuming and less suited for high-density EEG because of the many electrodes to be detected.
Dealing with high-resolution EEG has been made possible through the introduction of the Geodesic Photogrammetry System (GPS), which allows the localization of EEG sensors on the subject's scalp by using multiple pictures of the subject's head taken simultaneously. GPS overcomes the labor-intensive and time-consuming limits common to the methods mentioned above (Russell et al 2005). However, the material needed for the acquisition is expensive and somehow cumbersome. Furthermore, GPS only works on visible points, so it may become less precise if the hair hides some electrodes.
It is worth noting that, when using manual delineation, electromagnetic digitization, ultrasonic digitization or GPS, the electrode positions are determined in a fixed head coordinate space and are not yet registered to the MR coordinate space that defines the location of all potential neuronal sources (Russell et al 2005, Koessler et al 2009. This registration, which can be performed either by means of a rigid (6-parameter) or an affine (12-parameter) spatial transformation, may be more or less reliable, depending on the accuracy of the head model and of the electrode positions. To address this problem, a number of studies proposed the direct localization of EEG sensors from MR images (Brinkmann et al 1998, Koessler et al 2008, De Munck et al 2012. Since electrode positions and head geometry are extracted from the same MR image, it is theoretically possible to attain a more accurate correlation of EEG information with anatomical structures in the brain. Furthermore, no specific equipment is needed, except for having access to an MR scanner. This may be considered a primary limitation of the MR-based approach, as not all EEG laboratories have access to MR facilities. However, MR scanning is required to collect a structural image of the subject's head, based on which a realistic head model can be built. Even if MR safety exclusion criteria for the subjects and costs for MR scans may represent some further limitations in a pure EEG study, this approach is desirable for the use of EEG as brain imaging tool (Michel and Murray 2012). Notably, the MR scanning of a participant wearing an EEG net can be easily performed in simultaneous EEG-fMRI experiments (Laufs 2008).
A number of MR-based localization approaches have been already developed. Most of them rely on the use of external paramagnetic markers, such as vitamin A (Van Hoey et al 1997, Brinkmann et al 1998, Sijbers et al 2000, gadolinium (Yoo et al 1997, Koessler et al 2008, CuSO 4 solution (Brinkmann et al 1998) and collodion (Lagerlund et al 1993). Notably, the application of markers may affect the stability of the system resulting in electrodes misplacement or detachment (Yoo et al 1997, Brinkmann et al 1998. Most importantly, none of the MR-based localization methods were developed for and tested with high-density EEG montages. Interestingly, currently available high-density EEG nets have electrodes embedded in a plastic case. Since plastic contains hydrogen protons, it can be detected in MR images (Kramme et al 2011). This opens up an opportunity for detecting highdensity EEG electrodes from MR images without using external paramagnetic markers.
In this study, we tackle this challenge, proposing a method for the detection and labeling of high-density (256channel) EEG electrodes from structural MR images. Our approach does not require the use of markers fixed to the electrodes, and provides objective, fast and reproducible estimates of EEG electrodes coordinates using information extracted from an MR image.

Method description
Our method localizes and labels EEG electrodes from an MR image following two sequential steps (figure 1): (1) image processing: the structural MR image is processed in the individual space to improve image quality, perform image segmentation and detect the head shape; since electrodes are positioned around the scalp, a search volume is defined around the external border of the head. (2) electrode detection and labeling: candidate electrodes are identified within the search volume in individual space and then registered to the Montreal Neurological Institute (MNI) standard space; then, template EEG points are matched to the MR-detected electrode points, allowing for a direct electrode labeling. The full procedure is explained in detail in the following paragraphs.
2.1.1. Image processing. Processing of the MR images is carried out using the SPM12 software (http://www.fil.ion. ucl.ac.uk/spm/software/spm12/) and in-built MATLAB (MathWorks, Natick, US) functions. First of all, we correct for intensity non-uniformity (INU) in the MR image and remove background noise and goggles artifact (if goggles are worn by the subject). Then, a mask external to the head skin but including the electrodes is generated and applied to the image. Finally, spatial smoothing is applied to simplify the detection of electrodes as local maxima in the masked image.
2.1.1.1. INU correction and segmentation. First of all, we perform spatial resampling at 1 mm isotropic voxels on the structural MR image (figure 2(a)). Afterwards, INU correction (figure 2(b)) is carried out by the unified segmentation algorithm implemented in SPM12, using a regularization parameter equal to 0.0001 and a smoothing parameter equal to 30 mm full width at half maximum (FWHM), respectively.
2.1.1.2. Background noise removal. The INU-corrected image is binarized by using a threshold equal to 10% of the maximal image intensity. The voxels belonging to the resulting binary image are clustered to define the head of the subject and other unconnected structures. A mask including only the head is defined and applied to the original image, allowing the elimination of background noise and the exclusion of all the external structures detached from the head.
2.1.1.3. Goggles removal. In some cases, electrodes are not the only structures attached to the head. Indeed, glasses for correction to normal sight or video goggles are used when visual-based tasks are involved during a functional acquisition in the MR scanner. The presence of goggles is detectable in the structural MR image and this may substantially increase the number of false positives detected by our method. As such, a dedicated image-processing step is used to remove goggles (if present) from the MR image.
First of all, we binarize the masked INU-corrected image obtained at the previous processing step, using 25% of the maximum value as threshold. Dilation and erosion of the resulting mask are performed using morphological operators with 1-voxel radius for the spherical structuring element to remove residual possible noise around the head. Following the binarization, internal bone and sinus areas, which show low intensity in the MR image as compared to other head structures, appear as dark holes in the head and are filled in. Then, clusters of connected voxels in the image are defined and only the biggest one, which corresponds to the head and the connected surrounding structures, is kept. The resulting image is dilated (spherical kernel with 3-voxel radius) to incorporate all the external structures connected to the head. At this point, the previously defined mask is subtracted from the new dilated image, highlighting the presence of objects bordering with the scalp. Goggles regions are identified as the objects and with cluster size larger than 10.000 mm 3 . Image intensity in these regions is set to zero in the original image, thereby allowing for the removal of the goggles (only if these are present). This produces a deglassed MR image (figure 2(c)).
2.1.1.4. Retrieval of electrode image. After the localization and the removal of the goggles artifact, the search volume for the electrodes is defined. The original image without the goggles is binarized using 25% maximum intensity as threshold. The new binarized image is eroded and dilated using a 4-voxel spherical element. The resulting mask includes the full head and the volume around the scalp. Since the electrodes are located on the scalp's surface, we create a new mask for isolating the volume around the head, through the subtraction of the binarized image without goggles from the just calculated resulting mask. The new mask represents the search volume for electrodes detection. Original data are masked with the search volume to visualize only the skull border region where the electrodes are detected (figure 2(d)).
2.1.2. Detection and selection of electrodes. All analysis steps after image processing are implemented using MATLAB. First of all, candidate electrode positions are defined using the smoothed electrode image. The initial list of candidate electrodes is reduced by applying specific criteria based on their positions. Next, the candidate electrode positions are transformed to a standard space and compared with those of a template EEG net, in order to estimate the positions of the real EEG electrodes and to label them.
Finally, we back transform the detected electrode positions to the original space of the MR image.
2.1.2.1. Detection of candidate electrodes. First, the electrode image is smoothed (figure 2(e)) using a Gaussian kernel with a FWHM approximately equal to the electrode radius (5 mm for the montage used in this study). This smoothing kernel is chosen to reduce image noise but preserve electrode information. Then, candidate electrode points ] are defined by extracting the local maxima in the smoothed electrode image. The number of candidate points d is expected to be larger than the number of electrodes n, due to image artifacts or residuals of other structures external to the head.
2.1.2.2. Registration of electrode positions to MNI space. We transform the detected electrode positions from individual to MNI standard space in order to standardize the electrode positions, such that their mutual distance is not biased by head size and orientation. The registration of the electrode positions is performed by applying a 12-parameter affine transformation, calculated by means of SPM using the INUcorrected MR image as moving image and a T1-weighted template image in MNI space as target image. The relation between the ith electrode point in MNI space and in individual space, indicated with y ī and y i respectively, can be expressed as follows: where R represents a rotation, t a translation, and D indicates a non-uniform dilation between the two coordinate systems.
2.1.2.3. Filtering of candidate electrodes. We use two different criteria based on the Euclidean distance to reduce possible false positives among the detected points. First, we exclude the electrodes that are close to each other. Accordingly, we calculate a distance matrix using the coordinates of the detected electrodes. If there is a pair of electrodes with distance lower than the minimum interelectrode distance in the template (equal to 12 mm for the montage used in this study), the one that is the furthest from the head contour is excluded. In a second filtering step, we assess the minimum distance of each electrode from the head contour. We define and remove outlier electrodes, defined as those with distances larger than the average plus four times the standard deviation of the whole set of values. This leaves us with a set of d′ candidate points in MNI space  [¯¯] To this end, the coherent point drift (CPD) algorithm (Myronenko and Song 2010) is iteratively run until convergence. CPD considers the alignment of two point sets as a probability density estimation problem, where one point set represents the Gaussian mixture model (GMM) centroids, and the other one represents the data points. GMM centroids are assumed to have equal isotropic variance s , 2 which is derived from the data. These centroids are forced to move coherently as a group to preserve the topological structure of the point set.
To this end, a continuous velocity function υ needs to be defined, such that the updated position for the ith template point can be written as: An optimal solution to the problem is defined by minimizing a negative log-likelihood function E, defined as follows: å å here λ is a weighting factor and f a regularization function that enforces a smooth motion constraint (Chui andRangarajan 2000, Jian andVemuri 2011). Upon convergence of the CPD-based iterative procedure, the coordinates of the nonlinearly registered template points [¯¯] are taken as estimates of the final electrode positions in MNI space. Notably, electrode labeling is directly obtained in this manner. Eventually, the electrode coordinates are projected to individual space by inverting the affine transformation previously calculated from individual to MNI space (see equation (1)). Specifically, the final ith electrode point x , j with j=1,K, n, is obtained as follows: The MR data were collected in two phases. In the first one, two subjects (subjects S1 and S2) underwent MRI while wearing a HydroCel Geodesic Sensor Net (Electrical Geodesics, Eugene, US) with 256 electrodes. Subsequently, the 3D Cartesian coordinates of the EEG sensors on the scalp were also obtained using a GPS. We paid particular attention to the subject's preparation and in particular to the positioning of the EEG net, as the goal was to provide a benchmark to test our approach against another technique for 3D electrodes position reconstruction. In a second phase of the data acquisition, we acquired data in six subjects (subjects S3-S8), who were wearing a 256-channel HydroCel Geodesic Sensor Net. Since we wanted to assess the performance of our method, we acquired these additional MR images trying to replicate typical sensor net positioning and MR imaging problems that can be encountered when performing simultaneous acquisition of fMRI and EEG data, such as net rotation (S3 and S5), imprecisely gathered wires (S6), electrode detachment from the head (S4 and S7), and ghosting (S8) (see figures 4-6).
2.2.2. Assessment of method performance. The automated method was validated against manual detection from the MR volume. This was performed by one experienced investigator and double-checked by a second one. We opted for manual delineation for the estimation of the electrode positions, because this could be performed directly on the MR image, such that the measurement was not affected by coregistration errors. Nonetheless, it is worth noting that also the results of this procedure are operator-dependent and have an associated imprecision, which cannot be eliminated. The manual procedure demanded to look at the 3D image and select the center of each electrode with a mouse click to get the corresponding x y z , , ( ) coordinates in a Cartesian system.
MRIcron (http://people.cas.sc.edu/rorden/mricron/index. html) was used as image viewer for this step. Electrode labeling was also performed manually, comparing the set of points defined by the operator against those of a template montage (figure 3), which was used independently also as input to the automated method (see section 2.1.2).
As a first performance analysis, we assessed the number of points detected by the automated method across different processing stages. Specifically, we quantified the number of false positives and false negatives just after the detection of candidate electrodes (before filtering) as well as after the first and second electrode filtering steps. Notably, the automated method was implemented such that the whole set of electrode points was generated at the end of our procedure (virtually, with no false positives and negatives). For this reason, the final set of electrode points was further analyzed in terms of: (1) positioning error (PE), and (2) localization accuracy (LA). PE was measured by calculating the Euclidean distance between the positions of automatically and manually detected electrodes, respectively. LA was quantified by calculating the ratio between the number of electrodes for which PE was lower than a given tolerance limit and the total number of electrodes (in our case, n=256). This limit was set to 1 cm, in accordance with previous studies (Kavanagk et al 1978).
We compared the performance of our method against the one of GPS, which is currently considered the most suitable procedure for the localization of high-density EEG electrodes. With GPS, the position of each EEG electrode is derived from multiple pictures, simultaneously captured, of all the sensors on the subject's scalp. After defining the 2D electrode positions on at least 2 pictures, 3D coordinates are computed by using a triangulation algorithm (Russel et al 2005). We registered sensors locations detected by GPS to the scalp points defined by image segmentation (see section 2.1.1), as typically done in EEG source localization studies (Song et al 2015, Reis andLochmann 2015), using the rigid-body transformation implemented in SPM. A rigid-body transformation was used for preserving the inter-electrode distances and therefore the global spatial configuration of the electrodes. Also, we used the same approach to align the   GPS-derived electrodes positions to the manually detected points, such that the estimate of the overall error associated with the GPS was the smallest possible. In this manner, we attempted to estimate the inaccuracy that can be ascribed to the GPS technology (i.e., intrinsic GPS error), and not to the imperfections of the head model.

Results
In all the datasets used for the validation, our image-processing procedure was able to remove-at least in part-structures external to the head, such as goggles and other noise in the MR image, while sparing the electrodes. This led to the successful creation of an electrode image on which candidate electrode positions were detected. The number of these detected points contained some false positives but never exceeded 128% of the number of electrodes in the montage (i.e. 256) for any of the eight MR images in this study. The number of false negatives (missing points) was 0.5% of the total number of electrodes just after electrode detection, and did not increase across the two filtering steps (table 1). In turn, the overall number of false positives decreased consistently across the filtering steps, going from 16% down to 2.5% (table 1). Notably, no false positives and no false negatives were present after the use of the CPD algorithm (see section 2.1.2).
Next, we assessed the performance of our MR-based method for electrode localization in terms of PE and LA, using the results obtained by GPS localization as reference (table 2 and figure 7). For both MR images under investigation (S1 and S2), our MR-based electrode detection approach showed an average PE smaller than 3 mm. Since the maximum PE was below 8 mm, we also obtained an LA equal to 100%. Notably, channel-by-channel PEs were significantly lower than those of GPS (Wilcoxon Signed Ranks Test, Z=13.860, 2-tailed p<0.001, and Z=13.744, 2-tailed p<0.001, for S1 and S2, respectively). Furthermore, PEs obtained with our MR-based approach remained significantly lower than GPS even when we discounted the effect of coregistration errors (see section 2.2.2) that affected the GPSbased localizations (Wilcoxon Signed Ranks Test, Z=11.492, 2-tailed p<0.001, and Z=8.165, 2-tailed p<0.001, for S1 and S2, respectively).
We also analyzed the spatial distribution of the localization error across EEG channels. In this respect, we observed that the error was relatively uniform for our MR-based approach (figure 8(a)), with a coefficient of variation (i.e. standard deviation divided by average) equal to about 48%, whereas the GPS presented relatively larger values in correspondence to the edge of the net, at the bottom of the head, as well as around the ears and the cheeks ( figure 8(b)). In this case, the coefficient of variation of PE across channels was about 69%.
Subsequently, we assessed the performance of our approach on a set of MR images collected in six additional subjects (S3-S8). In this case, net positioning was performed to replicate possible unfavorable conditions in net positioning and MR scanning (see section 2.2.1). In spite of that, average Table 1. Analysis of the number of false negative (FN) and false positive (FP) across different analysis stages. This analysis refers to three main stages: (1) definition of candidate electrodes after the image processing part (before filtering), first filtering step based on inter-electrode distance, second filtering step based on the distance from the head contour.   PE was lower than 3.5 mm for all subjects (table 3 and figure 9). Electrode detection was slightly less accurate in the posterior part of the head, in correspondence of the ears' region and around the cheeks ( figure 10). Accordingly, a small number of detected electrode distances were larger than 1 cm, with LA ranging between 97% and 100%, and the coefficient of variation of PE across channels was about 66%.

Discussion
To the best of our knowledge, this is the first study proposing an automated method for localizing and labeling EEG electrodes through MR images, without using any specific sensor   marker and specifically tailored to high-density EEG montages. So far only two studies proposed labeling methods, but these were either semi-automated (De Munck et al 2012) or required the use of external markers (Koessler et al 2008). In either case, those methods were specifically developed for and validated with low-density EEG systems.
The availability of information about three-dimensional position of each electrode on a subject's head is strictly required for correlating EEG data with the underlying brain activities (He and Estepp 2013). MR-based localization method, among which the method we propose in this paper, have the great advantage of providing electrodes coordinates directly in the MR space, which is the same space to which EEG activity needs to be projected for source localizations (Lagerlund et al 1993, Towle et al 1993, Van Hoey et al 1997, Yoo et al 1997. This minimizes further sources of errors, such as electrodes position digitization and projection. Conversely, other techniques provide EEG electrode coordinates that should be registered from the EEG sensor space to the MR space, and then projected onto the surface of the reconstructed head model. Digitization techniques, in particular, may be very time-consuming for high-density EEG studies (Koessler et al 2007). In order to avoid the laborintensive measurement of the electrodes and fiduciary landmarks in every subject, many studies use an MR template image for structural reference and fit a standard electrode coordinate system over it (Richards et al 2015). This leads to reduced accuracy in source locations (Yoo et al 1997, Khosla et al 1999, Dalal et al 2014. Nowadays, GPS represents the primary technique for localization of high-density EEG electrodes. Not only were the localization errors for our MR-based approach substantially lower than GPS, but they were also more homogeneously distributed across channels (see table 2), as revealed by a reduced coefficient of variation compared to the GPS. Our data confirmed that the error in the spatial registration to the subject's head may contribute for the largest part to the total error that characterizes the GPS. However, even when we discounted the contribution of this registration error in the GPS measures, we still found that our MR-based approach had better performance (table 2 and figure 7).
We extended our validation to additional MR datasets with EEG montage having 256 channels, and characterized by relatively lower quality, and to verify whether the approach we developed could be applicable to a wide range of situations. As expected, the MR datasets characterized by lower quality yielded higher error values (for mean, standard deviation and maximum) compared to the first, more controlled dataset (see tables 2 and 3). Nonetheless, our method showed satisfactory results, with averages lower than 3.5 mm for all the subjects. Specifically, LA was always larger than 99%, except for two MR images. One of these images (S8) was severely affected by ghosting, resulting in the assignment of a few points to image noise rather than to true electrodes. The other MR image (S6) was characterized by inappropriate wire gathering. It is worth mentioning that, even for subjects showing the highest distances using our approach, the spatial localization error was still lower than the one of GPS. Electrodes detachment itself did not seem to affect negatively the performance of our method, showing really high accuracy (LA close to 100%). However, this should be anyway avoided as it negatively impacts on the quality of the collected EEG signals. MR images characterized by rotation of the central line of the EEG net yielded results similar to those of goodquality images (e.g. the ones labeled as S1 and S2), showing the robustness of our approach in the case of sub-optimal net positioning. Notably, we found the maximum error for our MR-based approach to be for more than 99% of the electrodes lower than 1 cm (as shown by LA values in tables 2 and 3), which is considered an acceptable upper limit for errors in electrode positioning (Kavanagk et al 1978).
Our method showed robustness and reliability, even in suboptimal conditions. On the other hand, a number of limitations should be mentioned. First, we conducted the present study using structural images collected with an MR sequence that we routinely use for EEG-fMRI experiments. Further improvement could theoretically be obtained if specific MR acquisition sequences would be designed to improve the contrast of the EEG electrodes in the MR image, as compared to brain tissues. Since high-density EEG electrodes can be visualized in the MR image as they contain plastic material and plastic has a very rapid decay, it is conceivable that MR sequences with ultra-short echo time (Robson et al 2003)  could improve the accuracy of the proposed method. Furthermore, the method relies on image processing steps that are not specifically designed to preserve electrode shape, and electrode positions are simply detected as local maxima after linear Gaussian filtering. An area of possible methodological improvement concerns the enhancement of electrode detectability by using nonlinear edge-preserving filtering specifically designed for MR images (Samsonov and Johnson 2004) in combination with robust template matching (Tward et al 2013). Finally, the method requires the initial setting of several parameters, e.g. for thresholding and dilation/erosion. These parameters have been empirically tuned in the present study, but may not easily generalize to MR images with different contrast, signal-to-noise ratio and/or spatial resolution. As such, the method cannot be considered fully automated. From this standpoint, the implementation of procedures for the automated selection of the parameters based on MR image properties would be highly desired for extending the applicability of our method. Future work is warranted for the development and testing of these procedures based on a large number of images collected with different MR scanners and various acquisition sequences. This would further contribute to a general validation of our approach.

Conclusion
We have introduced a method for the detection and labeling of high-density (256-channels) EEG electrodes. This does not require the use of markers fixed to the electrodes, and provides objective and reproducible estimates of EEG electrodes coordinates using information extracted from the MR image. Importantly, these estimates are not affected by errors of registration and projection of EEG electrodes onto the head model, which are present when using other techniques such as 3D digitization and GPS (Russell et al 2005). Notably, our results revealed increased localization precision as compared to GPS, which is the most widely employed solution for highdensity EEG. We suggest our method for detection and labeling of high-density EEG electrodes has the potential to increase the accuracy of source localizations. We hope this may advance the utility of EEG in the context of brain imaging applications.