Intersect/zero out DWI voxels with a mask

Hello,

I had a question of a special use case.
I want to simulate a lesion on a healthy DWI image.
I want to give a healthy DWI image a lesion so that I can compute tractography on it.
Is there a way to intersect the DWI image with a lesion mask in DWI space using MRTrix? What commands could I use?
I tried searching on the online forums but couldn’t quite find what I was looking for.

Your help is appreciated.
Thank you
Best,
Apoorva

Hi @apoorvakelkar,

With a DWI image and a lesion image that is 0s where lesion is and 1 everywhere else, use mrmath (mrmath — MRtrix3 3.0 documentation) to multiply the images together.

mrmath dwi.nii.gz lesion_0_mask.nii.gz product dwi_0_lesion_mask.nii.gz

Best,
Steven

I do not think this approach will make a very realistic injury. Why not use actual stroke datasets. The ARC provides hundreds of diffusion weighted images suitable for DTI analyses from individuals with chronic stroke. The SOOP provides thousands of acute DWI scans. For details see here and here.