Build your own loss function in PyTorch

Hi Adam,

If we were to define our own loss function, and during the middle there’s a sort and index_copy_ action that requires Tensor instead of Variable. Seems like unpacking data is unavoidable. Do you have any suggestions? Thanks.