Lets say I have a tensor of size [100, 100] and I have a set of start_indices and end_indices of size [100]
I want to be able to do something like this:
tensor[start_indices:end_indices, :] = 0
Unfortunately, I get an error saying
TypeError: only integer tensors of a single element can be converted to an index
So is this actually possible without a for loop?