Slow performance when changing strides

Dear all,
I have a question related to the command pasted above: mrconvert data.nii.gz DWI.mif -fslgrad bvecs bvals -datatype float32 -strides 0,0,0,1. I’m also running this on the HCP data. The challenge i have is that it is taking a lot of time to execute this command, and the progress rate is slow. Is this expected? or what do you suggest?

Thanks

Welcome @Joanne,

I suspect this will be due to running too close to memory limits. When handling HCP data, the first step is to uncompress the data into RAM, which takes up over 4GB by itself. The operation then requires another 4+GB to store the output. If your system doesn’t have more than 8GB, then you’re relying on the operating system’s virtual memory handling to transparently swap bits of RAM to/from the hard drive, which is painfully slow – especially in a case such as this one where the memory access patterns make the process incredibly inefficient. I can go into the specifics if you’re interested, but it’ll be a deep dive into memory mapping and the whole memory buffering mechanism at the OS level…

Given you seem to be running within a virtual machine, I’d suggest the first thing to try is to give it more RAM. Personally, I would recommend using dedicated high-performance hardware if you’re going to be looking at HCP data – they’re very large datasets, and if you’re trying to run that on a VM, I suspect you’ll often end up hitting performance bottlenecks like this…

Cheers,
Donald.

Thanks so much for your prompt response Donald. i’ll look into this.