diffractem.compute module

diffractem.compute.map_reduction_func(imgs, fun, *args, output_len=1, dtype=<class 'float'>, **kwargs)[source]

Use dask array map blocks for functions that return a numpy vector of values (e.g. fit functions or 1D profiles) :param imgs: image stack as dask array, stacked along dimension 0 :param fun: function to apply, needs to be able to process image stacks :param args: positional arguments to be supplied to the function. Note that these have to have three dimensions :param output_len: length of output numpy vector :param dtype: data type of output numpy vector :param kwargs: keyword arguments to be supplied to the function :return: