fix some device issues for pt 1.13
# What does this PR do?

`PyTorch 1.13` is coming. We have 2 models with a lot of test failures due to some tensor indexing with `indexed tensor` and `indices` on the different devices. (It works with torch <= 1.12.1 though).

This PR fixes this device issue, so we are better prepared for torch 1.13.
_The documentation is not available anymore as the PR was closed or merged._