Closed tstsrt closed 3 years ago
This would complicate things a lot, and very likely give a significant performance drop. Why not just transpose the data between the fft steps? Check "transpose" on crates.io for nice fast 2D transposes.
I did end up manually transposing the data. I just thought that adding a stride parameter would have a minimal performance impact. However, if this is not the case, I think the library's speed is more valuable than the convenience of having a stride parameter.
I do think there is some room in rustFFT for stride, but it would work by copying the data to a contiguous scratch buffer, and then doing the FFT contiguously. This would have the potential for being faster than the standard width -> transpose -> height ->transpose process, since it would be much more cache friendly.
I don't think I'll be able to get to it in the near future, unfortunately.
I would like to be able to set the stride of the FFT. This is very useful for computing 2D and 3D FFTs.
Example usage: