aixd.data.utils_data.reformat_torch_to_array

aixd.data.utils_data.reformat_torch_to_array(data: torch.Tensor) ndarray[source]

Converts a torch tensor into a numpy array.

Parameters:

data (torch.Tensor) – The input data, either as a tensor or a numpy array.

Returns:

np.array – The data as a numpy array.