add the hamming loss