|
MbalignTutorialTutorials.MbalignTutorial HistoryHide minor edits - Show changes to markup May 21, 2010, at 10:21 AM
by
- Reverted to original version.Changed lines 1-220 from:
haier america trading l.l.c http://predphechi.angelfire.com/u.n.-invasion-of-america.html toto u.s. america washlet 2006 mr. america bodybuilding http://predphechi.angelfire.com/america-on-line.com.html sap america inc the downsizing of america http://predphechi.angelfire.com/www.miss-america.com.html www.htc america.com overdose america.co http://predphechi.angelfire.com/www.guns-america-.com.html grohe america inc bank of america myeasypayments.com http://predphechi.angelfire.com/air-america-2.0.html bond america.com www.at home america.net http://predphechi.angelfire.com/www.tyre-america.com.html www.america mall.com blanco america.com http://predphechi.angelfire.com/mid-america-distribution-st.-joseph.html infoplease.com native america history lead america.org http://predphechi.angelfire.com/naughty-america.com-vip.html olympus america.com america personals singles.com http://predphechi.angelfire.com/america-bancard.com.html miss america pageant.com america s tire co http://predphechi.angelfire.com/frito-lay-north-america-inc.html history america.com to:
Tutorial: Motion Correction for Diffusion Weighted ImagesThis tutorial introduces the function mbalign in Camino, which is used to align the diffusion-weighted images within a single acquisition. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/S32.gif SYNOPSIS 1. Preparation before running mbalign1.1.General data files and informationBefore running mbalign, we need to have input and scheme files ready, and use -inputfile <Input voxel-order file> to specify in command options. If the input file is in scanner-order, we can use -scanner -inputfile <Input scanner-order file>. And also we need to make some other information of input image data clear and specify a few other options -datadims X Y Z <Number of voxels in each dimension> 1.2.SigmaThe value of sigma is the approximate noise standard deviation. An estimate of sigma is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. The camino program, datastats, can work it out for you: datastats -schemefile S.scheme -bgmask S32_BG.Bshort -inputfile S32.Bfloat where S32_BG.Bshort is a binary image containing an ROI in a background region of the image. The output looks like this: A well chosen background region that genuinely contains no signal should show similar statistics in the output above in both non-diffusion-weighted (b=0) images and diffusion weighted images. The first four images in the example above have b=0 and the subsequent ones have b>0. We see little difference in the statistics, which suggests the background genuinely contains no signal. The value of E(S^2) is around 1E5, so we might pick sigma = sqrt(E(S^2)/2), ie around 224. However, you may need to play with the setting of sigma to get the best results out of mbalign. The value is somewhat artificial, because really we just seek a good
threshold that reliably rejects measurements from corrupted images from contributing to the diffusion tensor fit. Several users have reported that they have to set
sigma 100 or 1000 times smaller than the estimate of sigma described above to get good results. Others report having to set sigma much higher, so this seems to be
data dependent. 1.3.Make slice to check input volumeThis section shows a simple way to check the input volume is what the program expects and also to give you a fell for how much realignment is required. It creates an image volume containing the corresponding slice from each image volume in the data set. If the image file is in voxel-order, we need to transfer it to scanner-order first: voxel2scanner -voxels $((128*128*32)) -inputdatatype float -outputdatatype float -components 64 -inputfile S32.Bfloat > S32.scan.Bfloat Then we can use camino function shredder to extract one slice from each of the 64 3D components, and build a 3D image shown in Fig1: http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32.fmr10_normmi.slice.check.jpg Fig.1 An image volume containing 1 slices from each of the 64 component images in the data set. Here is an example script for creating the image volume above: COMPONENT=64 #Since our dataset used in the example is float, so # Extract the middle slice # Make a header file
VOXELDIM_X=1.88 analyzeheader -voxeldims $VOXELDIM_X $VOXELDIM_Y $VOXELDIM_Z -datadims $DATADIM_X $DATADIM_Y $COMPONENT -datatype float > S32._SLICECHECK.hdr Now we can use visualisation tools, like MRIcro (Fig.2), to check the alignment of input data set. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_mircro.jpg Fig.2 Using MRIcro to see slice volume 2. Run mbalign2.1. Run mbalign simplyAn example of using mbalign in the simplest way is:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -inputfile S32.Bfloat
then the screen output would be: 2.2. Run mbalign in an advanced waySome other options mignt need to use:
-flirtsearchcost <Search cost function used in flirt> 3. Improve performanceThere are a few options can be used to improve the performance of mbalign.
-sigma http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/fa.s32.bdouble.jpg Fig.3 View projection of FA map generated by camino http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_m100.bshort.jpg Fig.4 View projection of mask file generated by camino We can also use matlab to make a mask file.
-bgthresh <Background threshold> 4. Update GradientUpdating diffusion gradients after registration is not an essential procedure, but can improve the registration result. Fig.5 explains the reason why diffusion gradients need to be updated after registration. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/rotate_tif_c.png Fig.5 Illustration of how rotation affects the effective gradient direction. The arrows indicate gradient directions. (a) Head without rotation. Suppose the mouth is a fibre. The signal is high because the gradient is perpendicular to the fibre. (b) Head with rotation. The signal is lower in the mouth fibre. (c) The unrotated head (after registration). The effective gradient direction for the corrected image is rotated. We can use our matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat. 5. More hintsQuite a few default options can be change in the source code of mbalign. Make the default values to the ones most frequently used can make the everyday use of mbalign much simpler. Inside mbalign source code, we can find and change the default options from the following part. #################################################### AcknowledgementWe would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. Reference- Y. Bai and D. C. Alexander, “Model-Based Registration to Correct for Motion between Acquisitions in Diffusion MR Imaging”, The Fifth IEEE International Symposium on Biomedical Imaging ( ISBI 2008), May 2008. May 16, 2010, at 06:04 PM
by
- EFBEOkhgwnKSCrHxChanged line 1 from:
SB7Bpg <a href="http://eobrqiurerih.com/">eobrqiurerih</a>, [url=http://sgtunkytfqev.com/]sgtunkytfqev[/url], [link=http://ayesnfbmznxj.com/]ayesnfbmznxj[/link], http://lubozxqctamy.com/ to:
haier america trading l.l.c http://predphechi.angelfire.com/u.n.-invasion-of-america.html toto u.s. america washlet 2006 mr. america bodybuilding http://predphechi.angelfire.com/america-on-line.com.html sap america inc the downsizing of america http://predphechi.angelfire.com/www.miss-america.com.html www.htc america.com overdose america.co http://predphechi.angelfire.com/www.guns-america-.com.html grohe america inc bank of america myeasypayments.com http://predphechi.angelfire.com/air-america-2.0.html bond america.com www.at home america.net http://predphechi.angelfire.com/www.tyre-america.com.html www.america mall.com blanco america.com http://predphechi.angelfire.com/mid-america-distribution-st.-joseph.html infoplease.com native america history lead america.org http://predphechi.angelfire.com/naughty-america.com-vip.html olympus america.com america personals singles.com http://predphechi.angelfire.com/america-bancard.com.html miss america pageant.com america s tire co http://predphechi.angelfire.com/frito-lay-north-america-inc.html history america.com May 04, 2010, at 11:03 AM
by
- jbvjFBnbRRqChanged lines 1-240 from:
Tutorial: Motion Correction for Diffusion Weighted ImagesThis tutorial introduces the function mbalign in Camino, which is used to align the diffusion-weighted images within a single acquisition. The program comes with a health warning: it is far from perfect. It can help to realign images, but we strongly recommend you check the output of the procedure to ensure it has made a genuine improvement. There are several tips below to help improve performance of the algorithm. Experience tells us that each data set requires different settings in mbalign to get it to work. Below is an example that worked on one sample data set, but you'll probably need to play with the settings to get it to work on yours. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/S32.gif SYNOPSIS 1. Preparation before running mbalign1.1.General data files and informationBefore running mbalign, we need to have input and scheme files ready, and use -inputfile <Input voxel-order file> to specify in command options. If the input file is in scanner-order, we can use -scanner -inputfile <Input scanner-order file>. And also we need to make some other information of input image data clear and specify a few other options -datadims X Y Z <Number of voxels in each dimension> 1.2.SigmaThe value of sigma is the approximate noise standard deviation. An estimate of sigma is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. The camino program, datastats, can work it out for you: datastats -schemefile S.scheme -bgmask S32_BG.Bshort -inputfile S32.Bfloat where S32_BG.Bshort is a binary image containing an ROI in a background region of the image. The output looks like this: A well chosen background region that genuinely contains no signal should show similar statistics in the output above in both non-diffusion-weighted (b=0) images and diffusion weighted images. The first four images in the example above have b=0 and the subsequent ones have b>0. We see little difference in the statistics, which suggests the background genuinely contains no signal. The value of E(S^2) is around 1E5, so we might pick sigma = sqrt(E(S^2)/2), ie around 224. However, you may need to play with the setting of sigma to get the best results out of mbalign. The value is somewhat artificial, because really we just seek a good
threshold that reliably rejects measurements from corrupted images from contributing to the diffusion tensor fit. Several users have reported that they have to set
sigma 100 or 1000 times smaller than the estimate of sigma described above to get good results. Others report having to set sigma much higher, so this seems to be
data dependent. 1.3.Make slice to check input volumeThis section shows a simple way to check the input volume is what the program expects and also to give you a fell for how much realignment is required. It creates an image volume containing the corresponding slice from each image volume in the data set. If the image file is in voxel-order, we need to transfer it to scanner-order first: voxel2scanner -voxels $((128*128*32)) -inputdatatype float -outputdatatype float -components 64 -inputfile S32.Bfloat > S32.scan.Bfloat Then we can use camino function shredder to extract one slice from each of the 64 3D components, and build a 3D image shown in Fig1: http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32.fmr10_normmi.slice.check.jpg Fig.1 An image volume containing 1 slices from each of the 64 component images in the data set. Here is an example script for creating the image volume above: COMPONENT=64 #Since our dataset used in the example is float, so # Extract the middle slice # Make a header file
VOXELDIM_X=1.88 analyzeheader -voxeldims $VOXELDIM_X $VOXELDIM_Y $VOXELDIM_Z -datadims $DATADIM_X $DATADIM_Y $COMPONENT -datatype float > S32._SLICECHECK.hdr Now we can use visualisation tools, like MRIcro (Fig.2), to check the alignment of input data set. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_mircro.jpg Fig.2 Using MRIcro to see slice volume 2. Run mbalign2.1. Run mbalign simplyAn example of using mbalign in the simplest way is: The program will create a temporary directory used during processing. It can be either specified by -tmpdir or automatically created according to the file name and current time. We do not have to use -outputfile to specify the output file name, and the program can generate it according to the input file name, as in the example shown above. To run mbalign, computer need to have registration software flirt(http://www.fmrib.ox.ac.uk/fsl/flirt/index.html) installed, which is part of FSL library(http://www.fmrib.ox.ac.uk/fsl/). We also need to specify the flirt directory by using -fsldir, but more easily, once we have camino and FSL installed, default value of variable DIR_FSL can be set inside the mbalign script. During the running of mbalign, you may see a lot of warning messages showing inside terminal window. Normally, just do not worry about it too much. Once the registration is complete, you should see the message shown below. After program finishes, the temporary directory should be deleted (Removing junk files...), but we can still use -keepjunk to prevent removal, which can be useful to help us analyse the final output. If the program is interrupted, this temporary folder will remain as junk files in computer and may need manual deletion. If we did not specify -outputfile, the program can generate it according to the input file name (Aligned data set output to /tmp/S32.out.Bfloat). After mbalign is complete, it is a good idea to repeat the procedure in section 1.3 to check the quality of the alignment. The registration does not always work and may do strange things to some component volumes, so manual checking is required. You may also find, as with any realignment procedure, that it does not improve the alignment. If the images were well aligned to begin with, you may want to stick with them rather than use the mbalign output. 2.2. Run mbalign in an advanced waySome other options can be useful: -flirtsearchcost <Search cost function used in flirt> -flirttransform <Transformation used in flirt> -searchrange <angle> -eddy -datatype <Data type for input and output files> -scanout <output scanner-order file> -omat <File name> -slicecheck <File name> When all the options are decided, we can run mbalign in an advanced way, such like mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -fsldir /cs/research/medim/common0/green/common/fsl/fslRH9/ -inputfile S32.Bfloat -slicecheck S32.fmr.slice.check -outputfile S32.fmr.Bfloat -omat S32.fmr.mat.txt -scanout S32.fmr.scanout.Bfloat -keepjunk -tmpdir tmp.fmr 3. Improving performanceThere are a few options can be used to improve the performance of mbalign. -sigma -bgmask <Mask file> http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/fa.s32.bdouble.jpg Fig.3 View projection of FA map generated by camino http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_m100.bshort.jpg Fig.4 View projection of mask file generated by camino We can also use matlab to make a mask file. -bgthresh <Background threshold> -searchrange <angle> 4. Update GradientUpdating diffusion gradients after registration is not an essential procedure, but can improve the precision of subsequent processing. Fig.5 explains the reason why diffusion gradients need to be updated after registration. http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/rotate_tif_c.png Fig.5 Illustration of how rotation affects the effective gradient direction. The arrows indicate gradient directions. (a) Head without rotation. Suppose the mouth is a fibre. The signal is high because the gradient is perpendicular to the fibre. (b) Head with rotation. The signal is lower in the mouth fibre. (c) The unrotated head (after registration). The effective gradient direction for the corrected image is rotated. We can use the matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat. 5. More hintsQuite a few default options can be changed in the source code of mbalign. Make the default values to the ones most frequently used can make the everyday use of mbalign much simpler. Inside mbalign source code, we can find and change the default options from the following part. #################################################### AcknowledgementWe would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. Reference- Y. Bai and D. C. Alexander, “Model-Based Registration to Correct for Motion between Acquisitions in Diffusion MR Imaging”, The Fifth IEEE International Symposium on Biomedical Imaging ( ISBI 2008), May 2008. to:
SB7Bpg <a href="http://eobrqiurerih.com/">eobrqiurerih</a>, [url=http://sgtunkytfqev.com/]sgtunkytfqev[/url], [link=http://ayesnfbmznxj.com/]ayesnfbmznxj[/link], http://lubozxqctamy.com/ February 18, 2010, at 10:19 AM
by
- Changed lines 3-4 from:
This tutorial introduces the function mbalign in Camino, which is used to align the diffusion-weighted images within a single acquisition. to:
This tutorial introduces the function mbalign in Camino, which is used to align the diffusion-weighted images within a single acquisition. The program comes with a health warning: it is far from perfect. It can help to realign images, but we strongly recommend you check the output of the procedure to ensure it has made a genuine improvement. There are several tips below to help improve performance of the algorithm. Experience tells us that each data set requires different settings in mbalign to get it to work. Below is an example that worked on one sample data set, but you'll probably need to play with the settings to get it to work on yours. Changed lines 106-108 from:
An example of using mbalign in the simplest way is: mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -inputfile S32.Bfloat then the screen output would be: \\ to:
An example of using mbalign in the simplest way is: Changed lines 120-124 from:
============================================================================================== to:
============================================================================================== The program will create a temporary directory used during processing. It can be either specified by -tmpdir or automatically created according to the file name and current time. We do not have to use -outputfile to specify the output file name, and the program can generate it according to the input file name, as in the example shown above. To run mbalign, computer need to have registration software flirt(http://www.fmrib.ox.ac.uk/fsl/flirt/index.html) installed, which is part of FSL library(http://www.fmrib.ox.ac.uk/fsl/). We also need to specify the flirt directory by using -fsldir, but more easily, once we have camino and FSL installed, default value of variable DIR_FSL can be set inside the mbalign script. During the running of mbalign, you may see a lot of warning messages showing inside terminal window. Normally, just do not worry about it too much. Once the registration is complete, you should see the message shown below.\\ Changed lines 139-140 from:
============================================================================================== to:
============================================================================================== After program finishes, the temporary directory should be deleted (Removing junk files...), but we can still use -keepjunk to prevent removal, which can be useful to help us analyse the final output. If the program is interrupted, this temporary folder will remain as junk files in computer and may need manual deletion. Changed lines 144-145 from:
We will discuss scheme file updating in Section 4.Update Gradient. to:
After mbalign is complete, it is a good idea to repeat the procedure in section 1.3 to check the quality of the alignment. The registration does not always work and may do strange things to some component volumes, so manual checking is required. You may also find, as with any realignment procedure, that it does not improve the alignment. If the images were well aligned to begin with, you may want to stick with them rather than use the mbalign output. Changed lines 149-150 from:
Some other options mignt need to use: to:
Some other options can be useful: Added line 153:
Added line 156:
Added line 159:
Added line 162:
Added line 165:
Added line 168:
Added line 171:
Changed lines 173-174 from:
Output a pair of <File name>.img and <File name>.hrd files. Default is no calculation. \\ to:
Output a pair of <File name>.img and <File name>.hrd files. Default is no calculation. Added line 176:
Changed lines 179-180 from:
3. Improve performanceto:
3. Improving performanceAdded line 182:
Changed lines 184-185 from:
High sigma allows the program to involve more measurement in the DT fitting, and low sigma leads rejections during the DT fitting. Based on this theory, we can change the value of sigma to improve the reference making. to:
High sigma allows the program to involve more measurement in the DT fitting, and low sigma leads rejections during the DT fitting. Based on this theory, we can change the value of sigma to improve the reference making, as discussed in section 1.2 above. Changed lines 187-188 from:
Use a mask file can improve the quality of the reference images used in mbalign registration. And the data type of mask file should be "short". Camino function mask can help to create a background mask from a voxel-ordered DW data file by thresholding the average b=0 measurement. to:
Use a mask file that specifies the brain region in the image usually improves the performance of the registration in mbalign and is strongly recommended. The data type of mask file should be "short". Camino function mask can help to create a background mask from a voxel-ordered DW data file by thresholding the average b=0 measurement, eg:\\ Added line 199:
Changed lines 201-202 from:
Decide the value of threshold, and improve fitting the diffusion tensors. to:
Decide the value of threshold, and improve fitting the diffusion tensors. This is an alternative to specifying the mask file as above and tells the program to threshold on the b=0 measurement directly. Changed line 207 from:
Updating diffusion gradients after registration is not an essential procedure, but can improve the registration result. to:
Updating diffusion gradients after registration is not an essential procedure, but can improve the precision of subsequent processing. Changed lines 212-213 from:
We can use our matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat. to:
We can use the matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat. Changed line 216 from:
Quite a few default options can be change in the source code of mbalign. Make the default values to the ones most frequently used can make the everyday use of mbalign much simpler. Inside mbalign source code, we can find and change the default options from the following part. to:
Quite a few default options can be changed in the source code of mbalign. Make the default values to the ones most frequently used can make the everyday use of mbalign much simpler. Inside mbalign source code, we can find and change the default options from the following part. February 18, 2010, at 10:05 AM
by
- Changed lines 61-62 from:
1.4.Make slice to check input volumeto:
1.3.Make slice to check input volumeThis section shows a simple way to check the input volume is what the program expects and also to give you a fell for how much realignment is required. It creates an image volume containing the corresponding slice from each image volume in the data set. Changed lines 69-70 from:
Then we can use camino function shredder to extract one slice from each of the 32 3D components, and build a 3D image shown in Fig1: to:
Then we can use camino function shredder to extract one slice from each of the 64 3D components, and build a 3D image shown in Fig1: Changed lines 73-74 from:
Fig.1 An image volume containing 32 slices from 64 diffusion components. to:
Fig.1 An image volume containing 1 slices from each of the 64 component images in the data set. Changed lines 77-78 from:
To make the command easy to read, we can use variables representing data information: to:
Here is an example script for creating the image volume above: Deleted line 79:
\\ Changed lines 84-85 from:
Since our dataset used in the example is float, so to:
#Since our dataset used in the example is float, so\\ Changed lines 87-92 from:
If we would like to extract the middle slice along z direction, we can set OFFSET=$(($DATADIM_X*$DATADIM_Y*$((DATADIM_Z/2))*$TYPESIZE)) Then, calling shredder to:
# Extract the middle slice Changed lines 91-92 from:
Make a header file (*.hdr) to make *.img file readable by many visualisation softwares: to:
# Make a header file Changed line 98 from:
Using some visualisation tools, such like MRIcro(Fig.2) and camino, we can check the slice motion of input data set. to:
Now we can use visualisation tools, like MRIcro (Fig.2), to check the alignment of input data set. February 18, 2010, at 09:51 AM
by
- Changed lines 3-4 from:
This tutorial gives a general introduction of using function mbalign in Camino package to align the diffusion-weighted images within a single acquisition. to:
This tutorial introduces the function mbalign in Camino, which is used to align the diffusion-weighted images within a single acquisition. Changed lines 31-39 from:
The sigma is approximate noise standard deviation. An estimate of sigma is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. A camino program, datastats, can work it out for you as well. datastats -schemefile S.scheme -bgmask S32_M100.Bshort -inputfile S32.Bfloat where S32_M100.Bshort is a mask file for ROI (we will discuss more about generating mask in Section 3). then the screen output would be: \\ to:
The value of sigma is the approximate noise standard deviation. An estimate of sigma is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. The camino program, datastats, can work it out for you: datastats -schemefile S.scheme -bgmask S32_BG.Bshort -inputfile S32.Bfloat where S32_BG.Bshort is a binary image containing an ROI in a background region of the image. The output looks like this: \\ Changed lines 44-55 from:
4 2.564062E02 7.868863E04 1.294450E04 1.137739E02 to:
4 2.564062E02 9.868863E04 1.294450E04 1.137739E02 Changed lines 52-55 from:
So we can choose 7.5 as the value of E(S^2). Then sigma, sqrt(E(S^2)/2), would be 1.9. However, you may need to play with the value of sigma to get the best results out of mbalign. The value is somewhat artificial, because really we just seek a good setting that reliably rejects measurements from corrupted images from contributing to the diffusion tensor fit. Several users have reported that they have to set to:
A well chosen background region that genuinely contains no signal should show similar statistics in the output above in both non-diffusion-weighted (b=0) images and diffusion weighted images. The first four images in the example above have b=0 and the subsequent ones have b>0. We see little difference in the statistics, which suggests the background genuinely contains no signal. The value of E(S^2) is around 1E5, so we might pick sigma = sqrt(E(S^2)/2), ie around 224. However, you may need to play with the setting of sigma to get the best results out of mbalign. The value is somewhat artificial, because really we just seek a good threshold that reliably rejects measurements from corrupted images from contributing to the diffusion tensor fit. Several users have reported that they have to set February 18, 2010, at 09:40 AM
by
- Changed lines 209-225 from:
#################################################### \\ ##### Change default variables to match system ##### \\ #################################################### \\ # Hint: To make your input arguments simple, set \\ # default input which you most often to use. # FSL directory \\ DIR_FSL=/cs/research/medim/common0/green/common/fsl/fslRH9 # LIM_ROTATE is default for -searchrange \\ LIM_ROTATE=90 # Available cost functions are: \\ # mutualinfo corratio,normcorr,normmi,leastsq. \\ SEARCH_COST=mutualinfo #Degree of freedom \\ # 12 for affine; 6 for rigid. \\ DOF=12 to:
#################################################### February 18, 2010, at 09:39 AM
by
- Added line 209:
[= Added line 225:
=] February 18, 2010, at 09:36 AM
by
- Changed lines 204-206 from:
We can use our matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat.!! 5. More hints to:
We can use our matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat. 5. More hintsAdded line 208:
February 18, 2010, at 09:35 AM
by
- Added line 114:
Changed lines 150-153 from:
We will discuss scheme file updating in Section 4.Update Gradient.!!! 2.2. Run mbalign in an advanced way to:
We will discuss scheme file updating in Section 4.Update Gradient. 2.2. Run mbalign in an advanced wayChanged lines 172-175 from:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -fsldir /cs/research/medim/common0/green/common/fsl/fslRH9/ -inputfile S32.Bfloat -slicecheck S32.fmr.slice.check -outputfile S32.fmr.Bfloat -omat S32.fmr.mat.txt -scanout S32.fmr.scanout.Bfloat -keepjunk -tmpdir tmp.fmr!! 3. Improve performance to:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -fsldir /cs/research/medim/common0/green/common/fsl/fslRH9/ -inputfile S32.Bfloat -slicecheck S32.fmr.slice.check -outputfile S32.fmr.Bfloat -omat S32.fmr.mat.txt -scanout S32.fmr.scanout.Bfloat -keepjunk -tmpdir tmp.fmr 3. Improve performanceAdded line 183:
Added line 185:
Added line 189:
Changed lines 196-198 from:
Sometimes, the pitch of histogram will cause the failure of registration. Simply narrow down the angle search range can cover this problem for most of the time.!! 4. Update Gradient to:
Sometimes, the pitch of histogram will cause the failure of registration. Simply narrow down the angle search range can cover this problem for most of the time. 4. Update GradientFebruary 18, 2010, at 09:31 AM
by
- Changed lines 208-209 from:
DOF=12!! Acknowledgement We would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. \\ to:
DOF=12 AcknowledgementWe would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. February 18, 2010, at 09:30 AM
by
- Changed line 129 from:
============================================================================================== to:
==============================================================================================\\ Changed line 133 from:
During the running of mbalign, there could be a lot of warning messages showing inside terminal window. Normally, just do not worry about it too much. Once the registration has got done, we may see the message shown below. to:
During the running of mbalign, there could be a lot of warning messages showing inside terminal window. Normally, just do not worry about it too much. Once the registration is complete, we may see the message shown below.\\ Changed line 146 from:
============================================================================================== to:
==============================================================================================\\ Changed lines 209-210 from:
We would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. \\!! Reference to:
We would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. February 18, 2010, at 09:27 AM
by
- Changed line 60 from:
So we can choose 7.5 as the value of E(S^2). Then sigma, sqrt(E(S^2)/2), would be 1.9. \\ to:
So we can choose 7.5 as the value of E(S^2). Then sigma, sqrt(E(S^2)/2), would be 1.9. February 18, 2010, at 09:25 AM
by
- Added sentence on setting sigma in mbalign.Changed lines 31-32 from:
The sigma is approximate noise standard deviation. A suggested value is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. to:
The sigma is approximate noise standard deviation. An estimate of sigma is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. Added lines 61-65:
However, you may need to play with the value of sigma to get the best results out of mbalign. The value is somewhat artificial, because really we just seek a good setting that reliably rejects measurements from corrupted images from contributing to the diffusion tensor fit. Several users have reported that they have to set sigma 100 or 1000 times smaller than the estimate of sigma described above to get good results. Others report having to set sigma much higher, so this seems to be data dependent.\\ October 22, 2009, at 03:47 AM
by
- Changed lines 5-6 from:
files/mbalign/S32.gif to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/S32.gif Changed lines 70-71 from:
files/mbalign/s32.fmr10_normmi.slice.check.jpg to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32.fmr10_normmi.slice.check.jpg Changed lines 106-107 from:
files/mbalign/s32_mircro.jpg to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_mircro.jpg Changed lines 109-110 from:
2. Run mbalign!!! 2.1. Run mbalign simplyto:
2. Run mbalign2.1. Run mbalign simplyChanged line 112 from:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -inputfile S32.Bfloat to:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -inputfile S32.Bfloat Changed lines 171-172 from:
files/mbalign/fa.s32.bdouble.jpg to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/fa.s32.bdouble.jpg Changed lines 173-174 from:
files/mbalign/s32_m100.bshort.jpg to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/s32_m100.bshort.jpg Added line 176:
Changed lines 184-185 from:
files/mbalign/rotate_tif_c.png to:
http://www.cs.ucl.ac.uk/research/medic/camino/tutorials/files/mbalign/rotate_tif_c.png September 04, 2009, at 04:54 PM
by - August 31, 2009, at 01:03 AM
by
- Changed lines 1-3 from:
Tutorial: Spatial normalization using flirt with diffusion tensor reorientationThis case study shows how to combine FSL's flirt program with Camino's tensor reorientation (using the preservation of principal directions (PPD) algorithm from Alexander et al, IEEE Trans. Medical Imaging 20(11) 1131-1139 2001) to perform spatial normalization of diffusion tensor images. Specifically, we will align two diffusion tensor images from different subjects. \\ to:
Tutorial: Motion Correction for Diffusion Weighted ImagesThis tutorial gives a general introduction of using function mbalign in Camino package to align the diffusion-weighted images within a single acquisition. files/mbalign/S32.gif SYNOPSIS 1. Preparation before running mbalign1.1.General data files and informationBefore running mbalign, we need to have input and scheme files ready, and use -inputfile <Input voxel-order file> to specify in command options. If the input file is in scanner-order, we can use -scanner -inputfile <Input scanner-order file>. And also we need to make some other information of input image data clear and specify a few other options -datadims X Y Z <Number of voxels in each dimension> 1.2.SigmaThe sigma is approximate noise standard deviation. A suggested value is sqrt(E(S^2)/2), where S is the signal in background and E denotes expectation over an ROI. A camino program, datastats, can work it out for you as well. datastats -schemefile S.scheme -bgmask S32_M100.Bshort -inputfile S32.Bfloat where S32_M100.Bshort is a mask file for ROI (we will discuss more about generating mask in Section 3). then the screen output would be: So we can choose 7.5 as the value of E(S^2). Then sigma, sqrt(E(S^2)/2), would be 1.9. 1.4.Make slice to check input volumeIf the image file is in voxel-order, we need to transfer it to scanner-order first: voxel2scanner -voxels $((128*128*32)) -inputdatatype float -outputdatatype float -components 64 -inputfile S32.Bfloat > S32.scan.Bfloat Then we can use camino function shredder to extract one slice from each of the 32 3D components, and build a 3D image shown in Fig1: files/mbalign/s32.fmr10_normmi.slice.check.jpg Fig.1 An image volume containing 32 slices from 64 diffusion components. To make the command easy to read, we can use variables representing data information: COMPONENT=64 \\ Changed lines 80-134 from:
Make sure camino/bin and fsl/bin are in your PATH. to:
DATADIM_X=128 Since our dataset used in the example is float, so TYPESIZE=4 If we would like to extract the middle slice along z direction, we can set OFFSET=$(($DATADIM_X*$DATADIM_Y*$((DATADIM_Z/2))*$TYPESIZE)) Then, calling shredder shredder $OFFSET $(($DATADIM_X*$DATADIM_Y*$TYPESIZE)) $(($DATADIM_X*$DATADIM_Y*$(($DATADIM_Z-1))*$TYPESIZE)) < S32.scan.Bfloat > S32._SLICECHECK.img Make a header file (*.hdr) to make *.img file readable by many visualisation softwares: VOXELDIM_X=1.88 analyzeheader -voxeldims $VOXELDIM_X $VOXELDIM_Y $VOXELDIM_Z -datadims $DATADIM_X $DATADIM_Y $COMPONENT -datatype float > S32._SLICECHECK.hdr Using some visualisation tools, such like MRIcro(Fig.2) and camino, we can check the slice motion of input data set. files/mbalign/s32_mircro.jpg Fig.2 Using MRIcro to see slice volume 2. Run mbalign!!! 2.1. Run mbalign simplyAn example of using mbalign in the simplest way is:
mbalign -datatype float -schemefile S.scheme -datadims 128 128 60 -voxeldims 1.88 1.88 2.0 -sigma 1.9 -inputfile S32.Bfloat
then the screen output would be: Fig.3 View projection of FA map generated by camino files/mbalign/s32_m100.bshort.jpg Fig.4 View projection of mask file generated by camino
We can also use matlab to make a mask file.
-bgthresh <Background threshold> Fig.5 Illustration of how rotation affects the effective gradient direction. The arrows indicate gradient directions. (a) Head without rotation. Suppose the mouth is a fibre. The signal is high because the gradient is perpendicular to the fibre. (b) Head with rotation. The signal is lower in the mouth fibre. (c) The unrotated head (after registration). The effective gradient direction for the corrected image is rotated. We can use our matlab function to update diffusion gradient for registered data set, and the usage method is explained inside the matlab file. Since the transformations used in the registration contribute to the gradient updating, we MUST save the transform matrix when running mbalign, using -omat.!! 5. More hints Quite a few default options can be change in the source code of mbalign. Make the default values to the ones most frequently used can make the everyday use of mbalign much simpler. Inside mbalign source code, we can find and change the default options from the following part.
We would like to thank Geoff Parker and Karl Embleton, University of Manchester, for providing the brain data. \\!! Reference - Y. Bai and D. C. Alexander, “Model-Based Registration to Correct for Motion between Acquisitions in Diffusion MR Imaging”, The Fifth IEEE International Symposium on Biomedical Imaging ( ISBI 2008), May 2008. August 31, 2009, at 01:02 AM
by
- Added lines 1-59:
Tutorial: Spatial normalization using flirt with diffusion tensor reorientationThis case study shows how to combine FSL's flirt program with Camino's tensor reorientation (using the preservation of principal directions (PPD) algorithm from Alexander et al, IEEE Trans. Medical Imaging 20(11) 1131-1139 2001) to perform spatial normalization of diffusion tensor images. Specifically, we will align two diffusion tensor images from different subjects. |