Code Monkey home page Code Monkey logo

Comments (1)

CuthbertCai avatar CuthbertCai commented on August 13, 2024

Hi @tengerye @CuthbertCai! Thank you for sharing the code.

I was wondering if this particular domain adaptation technique can be used in a regression problem. Let's say if I want to use this domain adaptation technique for a regression problem where the loss function for the main task is MAE or MSE. I am a bit confused about how to actually backpropagate the loss in such a case. Since in the classification problem, the total loss is a summation (according to the code) of the class loss and domain loss and as both of them are negative log-likelihood loss there is no issue while adding them. However, if the loss for the actual task and the loss for the domain classification task are different what should we do in that case? Your insight would be really helpful! Thanks!

Thanks for your appreciation! I'm not familiar with the regression problem. But I think this adversarial technique can be directly used in a regression problem if you also adopt a neural network in your task. This technique is conducted in the feature space, so I think maybe you can just add the adversarial loss to an intermediate feature space. As for combining the task loss and the adversarial loss, I think we can directly add them together. Besides, maybe a hyper-parameter is needed to balance different losses.

from pytorch_dann.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.