I have phase and magnitude data acquired with a Siemens PRISMA scanner at a reasonably low SNR. I tried applying dwidenoise in the complex data but I am not sure it is performing better. For instance, I can see the noise floor reduced in some parts and maybe less blurriness when denoising the complex data, but it also returns lower SNR/CNR and visually looks noisier than denoising the magnitude data. I wonder whether this is the behaviour expected or I am doing something wrong. So far, I followed similar steps commented on in previous forum entries (Unwrapping before dwidenoise on complex-valued data) or your guidelines (https://readthedocs.org/projects/mrtrix/downloads/pdf/latest/):
- Rescale phase from (-4096:4096) to (0,2pi).
- mrcalc Mag.nii.gz Ph_rad.nii.gz -polar complex.nii.gz
- dwidenoise complex.nii.gz denoised.nii.gz -noise noisemap.nii.gz
- mrcalc denoised.nii.gz -abs abs_denoised.nii.gz
Attached is a screenshot of what I get when applied to magnitude vs complex data.
Thank you so much for your help!
OK, that’s clearly not what we would have expected… My guess is that the initial conversion of the phase is not quite right, but I have to admit there may be more going on. I’ve looked into this a bit yesterday as we are also in the process of setting up a protocol here, here are my findings so far (I’ll need to dig deeper in due course, but that’ll have to wait till after the Easter break).
I’ve tested 3 cases, all on the same 1.3mm isotropic, b = 0, 1000, 2500 s/mm², 131 volume 7T dataset:
The results look like this:
two examples – all on the same intensity scale:
All on the same intensity scale:
What does this tell us?
Main take-home points:
if the phase is not converted correctly, the estimated noise level is higher, and the images produced appear somewhat noisier (compared to magnitude or correctly-converted complex), and it looks like the intensity itself is lower than expected in places.
if the phase is correctly converted, the estimated noise level is similar to that estimated from the magnitude data – if anything, very slightly higher. But the images produced appear significantly noisier than those from the magnitude data.
the Rician / magnitude noise bias is considerably lower using complex data – as expected.
So all in all, it looks like the initial phase conversion could be an issue (hard to tell from what you show without knowing the intensity scale on the noise map), but even with the correct phase, the denoised complex images do indeed appear slightly noisier than I would have expected, based on my experiences a while back when we were initially tinkering with these concepts (quite a few years ago now…). So I will be looking into this more closely when I next get the chance…
Any thoughts about this, @dchristiaens…?
Quick update on this topic while I have a minute…
It looks like the essential step missing for complex denoising to work well is the phase correction. There are different ways of implementing this step, but the simplest is probably just to run a first pass MP-PCA on the complex DWI, then use the phase of this output to correct the phase of the raw DWI, then run MP-PCA again on that (steps to reproduce below).
With this, I get these outputs:
These correspond to the (top to bottom):
- original magnitude data
- magnitude data, denoised using regular MP-PCA
- complex data, denoised as-is using complex MP-PCA, followed by magnitude transform
- complex data, phase-corrected from first-pass complex MP-PCA, then denoised again using complex MP-PCA, followed by magnitude transform
You can see that the phase correction really seems to help here, and provides outputs that are visually at least as clean as magnitude MP-PCA, but with better rectification of the noise floor.
For reference, these are the corresponding noise maps produced:
Steps to reproduce:
- convert DICOM data to complex
- run first-pass complex MP-PCA
- correct phase of original data based on phase of first-pass MP-PCA run
- run second-pass MP-PCA on phase-corrected data
- perform final magnitude transform
These are implemented below assuming magnitude & phase DICOM data stored in the
DICOM_DWI_phase folders respectively:
mrcalc DICOM_DWI_mag/ DICOM_DWI_phase/ pi 4096 -div -mult -polar complex.mif
dwidenoise complex.mif complex_dn.mif -noise noisemap.mif
mrcalc complex.mif complex_dn.mif complex_dn.mif -abs -div -conj -mult complex_pc.mif
dwidenoise complex_pc.mif denoised_pc_dn.mif -noise noisemap_pc.mif
mrcalc denoised_pc_dn.mif -abs denoised_pc_dn_mag.mif