I am initiating a sparse tensor using x = torch.sparse.FloatTensor(100,100,3). I want to fill it up later at different times. How can I do so? I am using this as a representation of a growing graph.

Doing x[1,1,:] = torch.Tensor([1,2,3]) throws RuntimeError: sparse tensors do not have strides.
Or just doing x[1] returns the same error.

A sparse tensor in pytorch is represented as a pair of dense tensors: a tensor of values and a 2D tensor of indices. sparse tensor donâ€™t have strides, the directed indexing operation such as x[1] is not allow. torch.sparse module is currently experimental, maybe using dense tensor is preferred