Summary
The EPI scripts (epi2d_fid.py, epi2d_se.py) currently set rf.freq_offset to excite different slices in multi-slice acquisitions, but do not apply the corresponding rf.phase_offset correction. This results in a slice-dependent phase error that is irrelevant for magnitude imaging but incorrect for phase-sensitive applications. For single-slice acquisitions (n_slices=1), freq_offset is zero, so the (missing) phase correction has no effect.
We will add the phase offset correction after successful validation in virtual and real measurements!
Background
When an RF pulse is played in the presence of a slice-select gradient, a frequency offset is applied to shift the excited slice:
rf.freq_offset = gz.amplitude * slice_thickness * (slice_ - (n_slices - 1) / 2)
This frequency offset causes a phase accumulation over the duration of the RF pulse. At the effective center of the pulse, the accumulated phase is:
phase = -2 * pi * freq_offset * t_center
where t_center is obtained from pp.calc_rf_center(rf)[0]. Without compensating for this, each slice is excited with a different (uncontrolled) phase offset.
Required changes
FID case (epi2d_fid.py):
rf.freq_offset = gz.amplitude * slice_thickness * (slice_ - (n_slices - 1) / 2)
rf.phase_offset = -2 * np.pi * rf.freq_offset * pp.calc_rf_center(rf)[0]
SE case (epi2d_se.py):
Both the excitation and refocusing pulses need correction. Additionally, the currently already considered 90° phase shift on the refocusing pulse (CPMG condition) must stay considered:
# Excitation pulse
rf.freq_offset = gz.amplitude * slice_thickness * (slice_ - (n_slices - 1) / 2)
rf.phase_offset = -2 * np.pi * rf.freq_offset * pp.calc_rf_center(rf)[0]
# Refocusing pulse
rf180.freq_offset = gz180.amplitude * slice_thickness * (slice_ - (n_slices - 1) / 2)
rf180.phase_offset = np.pi / 2 - 2 * np.pi * rf180.freq_offset * pp.calc_rf_center(rf180)[0]
Notes
- The CPMG 90° phase offset (
np.pi / 2) on the refocusing pulse is good practice but not strictly required for single spin-echo EPI.
Summary
The EPI scripts (epi2d_fid.py, epi2d_se.py) currently set
rf.freq_offsetto excite different slices in multi-slice acquisitions, but do not apply the correspondingrf.phase_offsetcorrection. This results in a slice-dependent phase error that is irrelevant for magnitude imaging but incorrect for phase-sensitive applications. For single-slice acquisitions (n_slices=1),freq_offsetis zero, so the (missing) phase correction has no effect.We will add the phase offset correction after successful validation in virtual and real measurements!
Background
When an RF pulse is played in the presence of a slice-select gradient, a frequency offset is applied to shift the excited slice:
This frequency offset causes a phase accumulation over the duration of the RF pulse. At the effective center of the pulse, the accumulated phase is:
where
t_centeris obtained frompp.calc_rf_center(rf)[0]. Without compensating for this, each slice is excited with a different (uncontrolled) phase offset.Required changes
FID case (epi2d_fid.py):
SE case (epi2d_se.py):
Both the excitation and refocusing pulses need correction. Additionally, the currently already considered 90° phase shift on the refocusing pulse (CPMG condition) must stay considered:
Notes
np.pi / 2) on the refocusing pulse is good practice but not strictly required for single spin-echo EPI.