Closed rtaiello closed 1 year ago
I pushed a change to the dev branch:
pip install pytorch-adapt==0.0.82.dev0
Now your code should work, assuming that target_labels
is available in your data
dict.
You can also pass in domains
directly to CLossHook
:
c_hook = CLossHook(domains=["src", "target"])
The reason why your code broke is that CLossHook
was hard-coded to expect "src" logits only. So when FeaturesAndLogitsHook
returned two tensors for logits, it was "too many values to unpack".
Let me know if the latest version works and I'll push it to 0.0.82
.
It worked, many thanks !
Hi @KevinMusgrave,
How could I use DANN with target labels, I tried to do that:
But I'm having this issue:
Thanks in advance!