8215
Comment:
|
8216
|
Deletions are marked like this. | Additions are marked like this. |
Line 15: | Line 15: |
* What we expect to get at the end of this process is a matrix which size is [Number of sensors x Number of sources] | * What we expect to get at the end of this process is a matrix whose size is [Number of sensors x Number of sources] |
Line 19: | Line 19: |
* BEM was implemented but still need to be validated. Coming soon. | * BEM was implemented but still needs to be validated. Coming soon. |
Tutorial 5: Computing a head model
This tutorial is still based on Sabine Meunier's somatotopy experiment, called TutorialCTF in your Brainstorm database. The recordings have already been imported and analyzed at the sensors level, and they are now ready for source estimation.
Contents
Forward problem
The first step consists in computing a model that explains how an electric current flowing in the brain can influence what is recorded out of the head, by the EEG or MEG sensors.
- This problem is called forward problem.
Its result is called head model in Brainstorm interface, but can also be referred as forward model or leadfield matrix.
- In Brainstorm software, we consider that the electric or magnetic activity which is recorded by the sensors is produced mainly by a set of electric dipoles located at the surface of the cortex.
- Contrary to a dipole localization method, we fix the dipoles locations (cortex surface) and orientations (perpendicular to the cortex), and try to estimate the activity of each dipole at each time sample.
- The grid of sources (dipoles) that is used is defined by the cortex surface we have imported in one of the previous tutorials; each vertex of this surface is considered as dipole.
- The default surface distributed with Brainstorm have around 15,000 vertices. So we will have 15,000 dipole amplitudes to estimate. Using less vertices would just lower the resolution of the results; using more produces too much data and might lead to memory issues.
- What we expect to get at the end of this process is a matrix whose size is [Number of sensors x Number of sources]
- For computing this matrix, two methods are available for MEG recordings in Brainstorm, and will be computed in this tutorial:
- Single sphere model: the head is considered a homogeneous sphere
- Overlapping spheres method:
- BEM was implemented but still needs to be validated. Coming soon.
To understand properly what is a forward model, why this approach was chosen, what is the best method, etc. please visit the RefManual section (under construction). For now we will only focus on how you compute a head model with the Brainstorm interface.
Single sphere model
Select the TutorialCTF protocol, close all the figures, and follow these steps:
Right-click on the StimRightThumb condition and select Compute head model. The Head modeler window will appear.
---The only thing you can choose here is the forward model you will use: Single sphere or Overlapping spheres.
Choose Single sphere.
- You can also edit the Comment field of the file that will be created.
- If you had MEG and EEG recorded in the same file, you have had the option to compute a forward matrix for either MEG, EEG or both.
The Head compartments panel just shows the surfaces that are going to be used to compute this model. If you did your work while importing the subject's anatomy, you wouldn't even have to check this.
Click on Run.
Two other windows appear, to help you define the sphere. Estimating the best fitting sphere for a head is not always that easy as it looks like, for many reasons: a human head is usually not spherical, and the sets of point we can use at this point are not always well adapted for an automatic sphere estimation.
- Read and follow the instructions in the help window and then close it.
Click on the Scalp button, move and resize the sphere manually, just to see how it works.
Click again on Scalp: here we will use directly the estimation of the sphere based on the vertices of the Scalp surface (a simple least-squares fitting using all the vertices of the surface).
For EEG 3-shell spheres models, you just estimate and manipulate the largest sphere (scalp), and then use the Edit properties... button to define the relative radii of the 2 other spheres, and their respective conductivities. This will be decribed in another tutorial.
Click on Ok. And wait for a few seconds, the forward model computation is started.
A new file appeared just below the channel file, it represents the head model.
- You cannot do many interesting things only with this file, as it is only a matrix that converts the cortical sources into MEG/EEG recordings, and we don't have any sources information yet.
You may just check the sphere(s) that were used to compute the head model, with the Check spheres menu.
Overlapping spheres model
Let's compute now an other forward model. The overlapping spheres method is based on the estimation of a different sphere for each sensor. Instead of using only one sphere for the whole head, it estimates a sphere that fits locally the shape of the head in the surroundings of each sensor.
Right-click on StimRightThumb condition and select Compute head model again.
Select the Overlapping spheres method and click on Run. It doesn't ask for anything, the 151 spheres are estimated automatically.
At the end, the Check spheres window shows the spheres that were estimated. You check all them by following the indications written in green at the bottom of the window: use left/right arrows. At each step, the current sensor marker is displayed in red, and the sphere you see is its local estimation of the head shape.
Close this window when you reviewed them all.
Selection of a head model
We now have two head models in for our Subject01 / StimRightThumb condition.
- You can have several head models computed for the same dataset, but it is not recommanded as it might be difficult afterwards to know which one was used to compute the sources.
If you want to keep them anyway, you have to indicate which one is the default one. You do that by double-clicking on one of them (or right-click > set as default head model), and it is supposed to turn green. The head model displayed in green is the one that will be used for the following computation step.
- For MEG, when it works properly, the overlapping spheres model usually gives better results than the single sphere one. In this particular case, it produces more focal results, so we are going to use it for the next steps.
- The only problem is that this method depends a lot on the scalp surface you use. If the surface has some irregularities, some holes or some extra blobs inside or outside the head, the fitting algorithm may crash. In that case you would have to fix your surface or use the single sphere method, as it is more robust.
For EEG, always prefer the "3-shell sphere (BERG)" model.
Now to make things clearer: delete the Single sphere head model, and keep the Overlapping spheres.
Batching head model computation
You can run in two clicks the computation of overlapping spheres model for all the conditions or subjects you want in the database.
The Compute head model menu is available in the many popup menus in the tree (protocol, subject, condition). It is then applied recursively to all the subjects and conditions that the node you selected include.
Example: If you want to compute it on all the subjects and all the conditions, select the Compute head model menu from the protocol node TutorialCtf. For all the conditions of Subject01, run it from the Subject01 popup menu. Etc.
If you only want to compute it on some subjects of the protocol, select them at once holding the Ctrl key, right-click on one, and select the Compute head model menu.
To process all the subjects for one condition, switch to the Functional data (sorted by conditions) view of the database.
Next
You are done with the forward problem.
Next step: the ?estimation of the noise covariance.