Guest User

Untitled

a guest
Jun 19th, 2019
55
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. a = torch.rand(2,4)
  2. print(a)
  3. print(a.exp())
  4. print(a.exp().sum(-1))
  5. print(a.exp().sum(-1).shape)
  6. print(a.exp().sum(-1).unsqueeze(-1))
  7. print(a.exp().sum(-1).unsqueeze(-1).shape)
RAW Paste Data