Phase encoding direction from Philips Achieva

Hi
I’d be grateful for some guidance in figuring out the correct phase-encoding directoin from a Philips Achieva 3T diffusion dataset.
The dcm2niix .json file says
“PhaseEncodingAxis”: “j”,
“ImageOrientationPatientDICOM”: [
1,
0,
0,
0,
1,
0 ],
“InPlanePhaseEncodingDirectionDICOM”: “COL”,

The original protocol file says
fold-over direction =|“AP”
fat shift direction =|“P”
and this post
https://www.jiscmail.ac.uk/cgi-bin/webadmin?A2=fsl;7311a4e2.1308)
indicates that the pe is therefore pa, while this post
https://www.nitrc.org/pipermail/mrtrix-discussion/2014-January/000866.html)
suggests the opposite, ap.

sorry, sent without finishing
Any guidance will be appreciated!
Cheers
James

I’m not sure we’ve ever verified what the actual sign of the PE direction was (@rsmith will not doubt correct me if I’m wrong here) – we only need to ensure it’s consistent. For the purposes of distortion correction, it doesn’t make any difference, as long as the PE direction we do extract is consistent across series (if we get it the wrong way around, we estimate the opposite B0 field, but the correction is appropriate nonetheless). So if you have a different application where you need to know the sign of the PE direction, then I’m afraid I’m not sure we can say for sure… You may have more luck on more BIDS-focused fora, e.g. this thread.

I would also guess that @lconcha’s post from the old mrtrix archives only deals with inverting the PE direction, I don’t think it makes any claims as to which direction the PE gradient actually points towards – only that you can reverse it using the setting mentioned. Again, if I’m wrong, I’m sure someone will (kindly :pray:) correct me…

Hi James. In which direction do the eyes appear to be distorted? If they look to be pulled/stretched anteriorly then PE is PA. If they appear to be flattened towards the brain then PE direction is AP.
Do you have blipped data as well?

Jerome

1 Like

Thanks Jerome and J-Donald, super helpful.

The eyes distort anteriorly so it’s definitely PA phase encoding. Unfortunately we don’t have the blipped data so we have to just work with what we have for this dataset.

Cheers

James

Note:

“PhaseEncodingAxis”: “j”,

is not equivalent to:

“PhaseEncodingDirection”: “j”,

The former is provided by dcm2niix presumably because it cannot ascertain the sign of phase encoding from the DICOM data. In the case of MRtrix3 currently, loading directly from the DICOM data would result in an absence of phase encoding information because of the inavailability of that sign information.

Hi Robert
Thanks for the additional clarification.
Does PhaseEncodingDirection “j-” equal PA (and PhaseEncodingDirection “j” equal AP)?
Cheers
James

Does PhaseEncodingDirection “j-” equal PA (and PhaseEncodingDirection “j” equal AP)?

Other way: A>>P is “j-”, P>>A is “j”. NIfTI coordinate system is RAS, so “increasing toward A” is positive.

This is however only correct if the NIfTI image transform is approximately axial. “j” indicates the axis with the second smallest stride, and for an axial image that will be anterior-posterior, but that’s not guaranteed to be the case. If understanding these mechanisms is important for you I’ve tried to explain it as best I could here.

Great, thanks Robert.

Hi J-Donald, just a double-check. If I understand you correctly, we can still get the correct correction results even though the PE direction identified in -pe_dir is the opposite, as long as we are sure it’s consistent in this scan. Am I right?

Hello!

I received a DKI dataset, consisting of two DICOM folders: one with only 3 volumes (b0s) and another with 102 volumes (with 12 b0s distributed throughout the volumes), bvec and bval. However, despite the indication of AP and PA, respectively, in the file names, when I view the files, I get opposite information.

As you can see in the figure, the first row contains, for the same patient, the sagittal and axial T1-weighted images, followed by the same images (row two) for one of the DICOM folders (in this case, the one with 3 b0 volumes, supposedly AP) and, finally, by the same images (row three) for the other DICOM folder (with 102 volumes, bvec, bval and, supposedly, PA).

However, when checking the images, we see that, for the second row, the eyes are elongated forward, the nose is compressed, the scalp in the occipital region is expanded, and the cerebellum is slightly elongated, which actually corresponds to a PA acquisition. In the third line, we see the opposite patterns: the eyes flattened towards the brain, the nose expanded forward, the cerebellum compressed, and the scalp in the occipital region “thinner,” which would correspond to AP (contrary to what the name saved in the file suggests).

These characteristics were observed in the acquisitions of other patients. Therefore, I believe the names AP and PA were switched in the description. What do you think? Could you guide me?

Additionally, considering that the switch actually happened and the main file with the 102 volumes the PE = AP. I applied the following commands:

mrconvert sub01_AP/ sub01_AP.mif
mrconvert sub01_PA/ sub01_PA.mif

dwidenoise sub01_AP.mif sub01_AP_den.mif
dwidenoise sub01_PA.mif sub01_PA_den.mif

mrdegibbs sub01_AP_den.mif sub01_AP_preproc_input.mif
mrdegibbs sub01_PA_den.mif sub01_PA_preproc_input.mif

dwiextract sub01_AP_preproc_input.mif - -bzero | mrmath - mean mean_b0_AP.mif -axis 3
dwiextract sub01_PA_preproc_input.mif - -bzero | mrmath - mean mean_b0_PA.mif -axis 3

mrcat mean_b0_AP.mif mean_b0_PA.mif -axis 3 b0_pair.mif

dwifslpreproc sub01_AP_preproc_input.mif sub01_dwi.mif -pe_dir AP -rpe_pair -se_epi b0_pair.mif -align_seepi -eddy_options " --slm=linear "

dwibiascorrect sub01_dwi.mif sub01_dwi_unbiased.mif -bias bias.mif

I would like to know if the approach is correct (extracting the b0s and calculating the average for each DICOM folder, followed by concatenating the average b0 of AP and the average b0 of PA).

When I ran the dwifslpreproc command, two warnings appeared that I would like to know how problematic they are and if there is anything I can do:

dwifslpreproc: [WARNING] It appears that the spin-echo EPI images used for inhomogeneity field estimation have a different repetition time to the DWIs being corrected. This may cause issues in estimation of the field, as the first DWI b=0 volume will be added to the input series to topup due to use of the -align_seepi option.

dwifslpreproc: Balanced phase-encoding scheme detected in SE-EPI series; volume 0 will be removed and replaced with first b=0 from DWIs

Finally, I also have a problem due to cropping in the cerebellar region during acquisition. I’m thinking of using a standard mask in the MNI space without the cerebellum for group analysis with FA maps, for example. However, when normalizing the post-processing images to the MNI space and then using the mask without the cerebellum, could cropping in the cerebellar region be problematic? Any suggestions on how to proceed?

Kind regards!