def pi()

in multiple_futures_prediction/my_utils.py [0:0]


def pi(obj: Union[torch.Tensor, np.ndarray]) -> None:
  """ Prints out some info."""
  if isinstance(obj, torch.Tensor):
    print(str(obj.shape), end=' ')
    print(str(obj.device), end=' ')
    print( 'min:', float(obj.min() ), end=' ')
    print( 'max:', float(obj.max() ), end=' ')
    print( 'std:', float(obj.std() ), end=' ')
    print(str(obj.dtype) )    
  elif isinstance(obj, np.ndarray):
    print(str(obj.shape), end=' ')    
    print( 'min:', float(obj.min() ), end=' ')
    print( 'max:', float(obj.max() ), end=' ')
    print( 'std:', float(obj.std() ), end=' ')
    print(str(obj.dtype) )