```
(e) .env In [1] from torch.autograd import Variable │
│
(e) .env In [2] import torch │
│
(e) .env In [3] a = Variable(torch.Tensor(1)) │
(e) .env In [4] a.ne(0) │
Out[4]
Variable containing:
1 │
[torch.ByteTensor of size 1] │
│
(e) .env In [5] a.ne(0).sum() │
Out[5] │
Variable containing: │
1 │
[torch.ByteTensor of size 1] │
(e) .env In [6] a.data.ne(0).sum()
Out[6] 1 │
(e) .env In [7]
```

However, the document about Tensor says Tensor’s sum return float.