CaptainEven / MCMOT

Real time one-stage multi-class & multi-object tracking based on anchor-free detection and ReID
MIT License
383 stars 82 forks source link

only one id #60

Open chengweige opened 3 years ago

chengweige commented 3 years ago

if only has one id for some class, then raise error

print(cls_id, nID)

self.emb_scale_dict[cls_id] = math.sqrt(2) * math.log(nID - 1)

abhaygargab commented 3 years ago

Even i had the same problem. I modified the part of the code like this:

        for cls_id, nID in self.nID_dict.items():
            nID = max(nID, 2)                             # Added Line
            self.emb_scale_dict[cls_id] = math.sqrt(2) * math.log(nID - 1)

But i am not sure if it is the right way. @CaptainEven can you please comment on this.

ThankYou

antonimarek commented 1 year ago

I see this was opened quite some time ago ;) but I stumbled on the same issue and I'm curious if such assumption of a fixed minimum can in some negative way affect the pipeline.