Should be similar to: - https://pytorch.org/docs/stable/generated/torch.where.html - https://numpy.org/doc/stable/reference/generated/numpy.where.html