GHM_Detection
GHM_Detection copied to clipboard
About "target" in ghm_loss.py for GHMC
Many thanks for your GREAT work! I have a question about the "target" in ghm_loss.py:
def forward(self, pred, target, label_weight, *args, **kwargs):
Is the "target" a ont-hot format? and where the "target" from?
Thanks a lot~~
The target is expected to have the one-hot format. If the target is the class number from COCO, these codes are used to deal with it: https://github.com/libuyu/mmdetection/blob/be06992564cc6b995b1ae86a258568e9d7b7a599/mmdet/models/losses/ghm_loss.py#L47-L49