Hi all,

This is related to Is there a way to insert a tensor into an existing tensor? but vectorized.

I want to add additional dummy categories to an object detector. Suppose the original vision model predicts 151 categories. How would I add 22 new 0 categories with a known order (they can be in the middle of the 151 so it wouldn’t be left/right-padding).

```
obj_dists = torch.rand(650, 151) # suppose there are 650 RoIs in this image.
mapping_151_177 = torch.randint(151) # index of the 177 corresponding to the
mapping_177_151 = torch.randint(177) # index of the 177 corresponding to the
```

Now my additional question is whether this is a dumb idea to start with, even if it’s feasible. Does this affect the gradient flow of the original data, for example? Or does this totally calls into question the losses?