Open rwagner2017 opened 3 years ago
If you convolve a sparse tensor with some np.nan in its features, the output sparse tensor would have nans with all elements adjacent to the element with input nan features.
This nan value would spread out quickly after a few convolutions until you get nan on all sparse tensors. Also, the gradients would be invalid.
Could you explain some use cases for this?
Another option is to use one-hot vector to indicate that some elements have a specific property like what you described here.
It looks like the API has change since #137. Is it possible to get a nan value (or some custom value) to differentiate between a coordinate with a feature value of zero vs a coordinate with no feature value? Here is an example:
coords = torch.IntTensor([[0, 1], [1, 2], [2, 1], [1, 0], [1, 1]]) feats = torch.FloatTensor([[1, 2.1, 3.2, 4.5, 0]]).t()
(tensor([[[0.0000, 1.0000, 0.0000]], [[4.5000, 0.0000, 2.1000]], [[0.0000, 3.2000, 0.0000]]]), tensor([[0]], dtype=torch.int32), tensor([1], dtype=torch.int32))
[1.00, 1.00] = 0.0000 [0.00, 2.00] = 0.0000
It would be nice if [0, 2] == np.nan or some user defined val.