Each channel has therefore it’s own probability, i.e. the probabilities for each channel do not have to sum to 1, is that correct?
A valid probability tensor would also be: torch.tensor([0.9, 0.9, 0.9, 0.9])?
Well you could use torch.bernoulli to sample the channels, but you could end up with 0 to 4 valid channels.
How would you like to keep 50% of the channels having the high probabilities?
If I understand your use case correctly, you could try to sample many times until you get two channels:
probs = torch.tensor([0.5, 0.3, 0.1, 0.1])
channel_idx = torch.bernoulli(probs)
while channel_idx.sum() != torch.tensor([2.]):
    channel_idx = torch.bernoulli(probs)

Would that work or am I misunderstanding the issue?