You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i've seen many implementation of DANN...but every of it just get the loss with three parts .
could you tell me why this model is not care about the loss of taget dataset's label??
The text was updated successfully, but these errors were encountered:
1.Classification loss
class_pred = classifier(source_feature)
class_loss = classifier_criterion(class_pred, source_label)
2. Domain loss
domain_pred = discriminator(combined_feature, alpha)
domain_source_labels = torch.zeros(source_label.shape[0]).type(torch.LongTensor)
domain_target_labels = torch.ones(target_label.shape[0]).type(torch.LongTensor)
domain_combined_label = torch.cat((domain_source_labels, domain_target_labels), 0).cuda()
domain_loss = discriminator_criterion(domain_pred, domain_combined_label)
total_loss = class_loss + domain_loss
total_loss.backward()
i've seen many implementation of DANN...but every of it just get the loss with three parts .
could you tell me why this model is not care about the loss of taget dataset's label??
The text was updated successfully, but these errors were encountered: