DataModule.inverse_transform_x
- DataModule.inverse_transform_x(x: torch.Tensor | ndarray, out_type: str = 'numpy') torch.Tensor | ndarray [source]
Unnormalize only the input data. Takes care of the case where x is a numpy array or a torch tensor.
- Parameters:
x (Union[torch.Tensor, np.ndarray]) – A numpy array or a torch tensor to be unnormalized.
out_type (str, optional) – The type of the output. Can be “numpy”, “torch”, or “same”. The default is “numpy”.
- Returns:
Union[torch.Tensor, np.ndarray] – The unnormalized data.