Closed dan-zheng closed 5 years ago
nllLoss
nllLoss_grad
GPUArrayFromSeq
Array[Int]
Tensor
Rep[Array[Int]]
GPU nllLoss and nllLoss_grad behave as expected (verified in lantern-cudnn-nll-loss). MNIST CNN works using GPU nllLoss.
lantern-cudnn-nll-loss
Ready for review. There are two main changes:
target
target.moveToGPU()
MNIST CNN works using GPU nllLoss.
nllLoss
andnllLoss_grad
kernels.GPUArrayFromSeq
expression.Array[Int]
on GPU.Tensor
arrays, e.g. target labels of typeRep[Array[Int]]
.GPU
nllLoss
andnllLoss_grad
behave as expected (verified inlantern-cudnn-nll-loss
). MNIST CNN works using GPUnllLoss
.