I see people do it in mask = ~torch.eye(n_samples, device=sim.device).bool()
What does the ~ for?
Thank you.
1 Like
The tilde operation is a bitwise negation and should yield the same output as torch.bitwise_not
.