In [2]: x = torch.ones(1,2)
In [3]: x
Out[3]:
1 1
[torch.FloatTensor of size 1x2]
In [4]: x.max(1)
Out[4]:
(
1
[torch.FloatTensor of size 1],
0
[torch.LongTensor of size 1])
In [5]: x.min(1)
Out[5]:
(
1
[torch.FloatTensor of size 1],
0
[torch.LongTensor of size 1])