In afni_proc.py, blip-up/blip-down distortion correction is computed using unprocessed EPI data (no tshift or anything else). However, it is computed and applied *after* tshift and other initial temporal processing, being applied in the volreg block, along with the rest of the registration transformations.
That allows for the initial temporal processing to retain slice timing, but such that the temporal processing does not affect the distortion computation. Also, it allows for all spatial transformations to be applied in a single, combined transformation, without repeated spatial interpolation.
- rick