def worker_nll_loss(self, target, leak_out_array):
        """
        Get NLL loss for worker

        :return loss: batch_size * seq_len
        """
        loss_fn = nn.NLLLoss(reduction='none')
        loss = loss_fn(leak_out_array.permute([0, 2, 1]), target)

        return loss

        Get NLL loss for worker

        :return loss: batch_size * seq_len
        
models/LeakGAN_G.py