Add optional dtype argument to _get_freq_grid
Add optional dtype argument to _get_freq_grid

Allow the dtype of _get_freq_grid to be overridden externally if needed.
Make sure the conversion occurs right after getting the frequencies for
each dimension. This should minimize copying to small pieces of the
array.

dask-image/dask-ndfourier