tedana icon indicating copy to clipboard operation
tedana copied to clipboard

`reshape_niimg()` may be too flexible

Open tsalo opened this issue 10 months ago • 1 comments

Summary

reshape_niimg is more flexible than documented. reshape_niimg will sometimes take as input a file name, sometimes a 3D image array, and sometimes a 1D image array. It seems to work for all those conditions.

If it's a file name, it loads the file and then reshapes and if it's already a loaded image, it just uses it. If it's already 1D, it squeezes the file and is still 1D.

Additional Detail

Stems from https://github.com/ME-ICA/tedana/pull/1060#issuecomment-2043671230.

tsalo avatar Apr 10 '24 12:04 tsalo

From our April 2024 dev call, the decision is that the function has fine behavior, but we should update the document to accurately reflect what the function can do.

handwerkerd avatar May 16 '24 01:05 handwerkerd