Open taylover-pei opened 5 years ago
It's an unbiased estimation of MMD with linear complexity, and you can find it in the DAN paper. We have updated the code and both the batch MMD and linear estimation of MMD are included.
and there may be an error. It should be kernels[t1,s2]
You have done a great job.
But I have a question about the MMD Loss. The proposed MMD Loss in the paper are as follows, we can see that source domain data is paired with each other so as to the target domain data.
For exsample, if the batch size is 10 for source and target domain, there are 100 pairs in the first iterm of the loss, 100 pairs in the second iterm of the loss and 100 pairs in the third iterm of the loss.
But, in your code just as follows, there are only 10 pairs in the first iterm of the loss, 10 pairs in the second iterm of the loss and 20pairs in the third iterm of the loss.
So, I think this code did not match to the original loss propsosed in paper, can you explain it to me?
Thank you very much. Looking forward to your reply.