[-0.7124, -0.1631, -0.2272],
              [ 0.1356,  0.3933, -0.5023],
              [-0.0308, -0.1725, -0.5216]])
  >>> A = torch.randn(2, 6, 3)
  >>> Apinv = torch.linalg.pinv(A)
  >>> torch.dist(Apinv @ A, torch.eye(3))
  tensor(8.5633e-07)

  >>> A = torch.randn(3, 3, dtype=torch.complex64)
  >>> A = A + A.T.conj()  # creates a Hermitian matrix
  >>> Apinv = torch.linalg.pinv(A, hermitian=True)
  >>> torch.dist(Apinv @ A, torch.eye(3))
  tensor(1.0830e-06)
