It’s using integer array indexing to get the logp for the correct target; I was puzzled at this for some time too when I first encountered it here What is torch.nn really?
1 Like
It’s using integer array indexing to get the logp for the correct target; I was puzzled at this for some time too when I first encountered it here What is torch.nn really?