User Tools

Site Tools


biac:analysis:topup_correction

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
biac:analysis:topup_correction [2019/02/22 14:45]
cmp12 old revision restored (2019/02/22 14:31)
biac:analysis:topup_correction [2019/09/04 17:45]
cmp12
Line 7: Line 7:
 There will be two series of single timepoint EPI images.  You can grab relevant info to create the acq_params.txt files from your XML header. There will be two series of single timepoint EPI images.  You can grab relevant info to create the acq_params.txt files from your XML header.
  
-You need to calculate readout time in seconds ( the physical time it takes to get the acquisition matrix of a single slice ) and get the polarity direction ( phase encode direction ).+You need to calculate readout time in seconds of the PEPOLAR images ( the physical time it takes to get the acquisition matrix of a single slice ) and get the polarity direction ( phase encode direction ).
  
 the readout time in seconds for the parameter file will be: the readout time in seconds for the parameter file will be:
Line 15: Line 15:
 </code> </code>
  
 +unfortunately at this point the polarity of the images will have to be determined from visual inspection. we aren't provided enough information in the metadata to give an entry into the BXH file ( yet ).
 +
 +Here is a rough guide to help with inspection.  Take note of the eyeballs being crushed in for AP and stretched out for PA.  Below shows the PEPOLAR images in red/blue on top of a mean functional.
 +{{:biac:analysis:connneuro_func.png?800|}}
  
-the polarity for the entry will have to be determined from the **seriesdescription**, which is typically "field map reverse polarity" or "field map regular" 
  
 reverse will be "-1" in the acq_params.txt and regular will be "1" reverse will be "-1" in the acq_params.txt and regular will be "1"
Line 62: Line 65:
 applytopup --imain=../bia6_00186_009_01.nii.gz --inindex=1 --method=jac --datain=acq_params.txt --topup=rs_topup --out=run009 --verbose applytopup --imain=../bia6_00186_009_01.nii.gz --inindex=1 --method=jac --datain=acq_params.txt --topup=rs_topup --out=run009 --verbose
 applytopup --imain=../bia6_00186_010_01.nii.gz --inindex=1 --method=jac --datain=acq_params.txt --topup=rs_topup --out=run010 --verbose applytopup --imain=../bia6_00186_010_01.nii.gz --inindex=1 --method=jac --datain=acq_params.txt --topup=rs_topup --out=run010 --verbose
 +</code>
 +
 +If you have the scenario where the functional data was acquired with acceleration, but the PEPOLAR images were not.  You can create an additional acq_params file with a modified readout time to help prevent over correction.  You will need to divide the echospacing by the sensefactor from your BXH header of the functional run.  If your functional data and PEPOLAR images have the same sensefactor, this compensation is not needed.
 +
 +<code>readout = ((echospacing/sensefactor) * (acquisitionmatrix[0] * (percentsampling/100))) / 1e6 
 +echospacing in the BXH header is in microseconds
 </code> </code>
  
Line 192: Line 201:
  
 there are 2 scenarios that typically apply here there are 2 scenarios that typically apply here
-1) a short acquisition with RPE B0s +1) DWI and a short acquisition with RPE B0s 
-2) an entire acquisition with the same gradient table and reverse phase encoding +2) entire acquisitions with the same gradient table and reverse phase encoding 
  
 In both scenarios it is important to create your data with normal phase encoding direction first, followed by reversed. In both scenarios it is important to create your data with normal phase encoding direction first, followed by reversed.
Line 264: Line 273:
 <code> <code>
 #concat the 2 series ( regular, reversed )  #concat the 2 series ( regular, reversed ) 
-bxh_concat bia6_00260_007_LAS.bxh bia6_00260_008_LAS.bxh both+bxh_concat bia6_00260_00 
 +7_LAS.bxh bia6_00260_008_LAS.bxh both
  
 #extract the gradients #extract the gradients
-extractdiffdirs --fsl both bvecs bvals+extractdiffdirs --fsl both.bxh bvecs bvals
  
 #convert to mif #convert to mif
Line 289: Line 299:
 dwipreproc dwi.mif dwi_corr.mif -rpe_all -pe_dir AP -readout_time 0.10656 -debug dwipreproc dwi.mif dwi_corr.mif -rpe_all -pe_dir AP -readout_time 0.10656 -debug
  
--rpe_all signals that you've replicated A+-rpe_all signals that you've replicated  
 +A
 LL the directions with a rpe acquisition LL the directions with a rpe acquisition
 -pe_dir is the phase encode direction of your regular acquisition -pe_dir is the phase encode direction of your regular acquisition
biac/analysis/topup_correction.txt · Last modified: 2023/02/23 18:43 (external edit)