Field-map undistortion v3.03 July 2004 Batch mode description These are all now properties of a structure, so you set them using something like bp.acceptalldefaults=1 When you run the tool using the GUI, it saves this structure to a file “parameters.mat” in the directory where you store the field map intermediates (as specified in phasemapdirectory below, or entered as “field map directory” in the GUI). You could use this as a basis for your batch script. You may run the tool in batch mode by providing this structure as a parameter e.g., fieldmap_undistort_v3(bp) where bp is the structure you’ve made. The Cambridge only options extract parameters from the Bruker files that will be unique to our site. However, with a little modification they could be used where preprocessed fieldmaps are available in Analyze format. COMMON TO ALL RECO IMPORT MODES NAME DESCRIPTION POSSIBLE VALUES acceptalldefaults Whether to accept default values for parameters below startstage Stage of processing to start at recophasemaps Where phase maps are/ will be reconstructed 0 No 1 Yes 2 Use same parameters as last time 0 Reco 1 Unwrapping 2 Skull stripping 3 Expansion 4 Rotation & reslicing 5 Generate distorted magnitude 6 Coregistration 7 Undistortion 1 Locally reconstructed 0 Reconstructed with WBIC tool 2 Varian field maps 3Bruker Queensland field maps 4 Siemens gre_fieldmapping 5 Separate Analyze format field maps 6Ready preprocessed fieldmaps in Tesla',... evoltime Difference in echo time of two maps (ms) phaseencodeaxis Phase encode axis along which undistortion will be applied phasemapdirectory epitocoreg Directory for field map data files Filename of EPI to coregister to (usually mean*...) Filename( s) of EPIs to undistort Interpolation type epistoundistort interpol 2.276 9.104 (Cambridge default) 2.5 8.104 2.46 (Siemens GRE fieldmapping default) 1–x 2–y 3–z linear WHEN REQUIRED Always Always Anything up to stage 5 Anything up to stage 5 Always Always Anything up to stage 6 Always Always realigntocom manualshift padz zerodisp maxshift constrain Whether to realign field maps to their centre of mass at start of processing Shift EPI forward by this many mm during undistortion process (very occasionally necessary to keep them within field of view) Pad fieldmap above and below in z dirextion by this many voxels Adjust undistortion map so mean displacement is zero (helps to keep everything in FOV) Mask voxels that shift by more than this distance in mm Constrain coregistration of EPI and distorted field map magnitude to only allow translations sinc (default) 0 No 1 Yes (default) defaults to zero 0 No 1 Yes Anything up to stage 4 Anything up to stage 5 defaults to 9999 Always 0 No 1 Constrain to translations only (default) Anything up to stage 6 SIEMENS GRE_FIELDMAPPING SEQUENCE gre_phase gre_fieldmapping Analyze format phase gre_mag gre_fieldmapping Analyze format magnitude Anything before stage 5 Anything before stage 5 ANALYZE FORMAT FIELDMAPS fmA_m Magnitude of fieldmap A fmA_p Phase of fieldmap A fmB_m Magnitude of fieldmap B fmB_p Phase of fieldmap B Anything up to stage 5 Always Anything before stage 5 Anything before stage 5 Anything before stage 5 Anything before stage 5 CAMBRIDGE ONLY: OLD FIELDMAPS phasemappair (bandwidth) phasemapdirectory phase1a phase1b phase1c phasecmr Whether to use phase 1a and 1b or phase 1a and 1c No longer required – extracted automatically from imnd or .brkhdr file Directory for data files Directory of phase1a data (if reconstructing locally) Directory of phase1a data (if reconstructing locally) Directory of phase1a data (if reconstructing locally) Filename of .cmr file (if reconstructing at WBIC) 1 1a and 1b maps 2 1a and 1c maps Always Never Always Anything before stage 5 Anything before stage 5 Anything before stage 5 Anything before stage 5 CAMBRIDGE ONLY: NEW FIELDMAPS, PRE-PROCESSED AND SCALED IN TESLA newfieldmap Path to directory containing Analyze Anything format files: before stage 5 magnitude.img fieldmap.img matfile.txt 4x3 rotation/translation matrix (use [1 0 0 0; 0 1 0 0; 0 0 1 0] if no rotation or translation needed) OXFORD ONLY oxmap Filename of _b0map file procpar Filename of EPI procpar file Anything before stage 5 Anything before stage 5