leon-liangwu / MaskYolo_Caffe

YOLO V2 & V3 , YOLO Combined with RCNN and MaskRCNN
114 stars 50 forks source link

about avg_anyobj #34

Closed chengweige closed 4 years ago

chengweige commented 4 years ago

add avg_anyobj -= avg_obj; ? before avganyobj /= (wh_n*batch - obj_count); all right?

leon-liangwu commented 4 years ago

hi @chengweige why should that be added? avg_anyobj is actually for no-obj confidence.

chengweige commented 4 years ago

for region_loss_layer, avg_anyobj += loutput[index + 4*wh_] is used for all anchor box, avg_obj += l_output[best_index + 4w*h] is used for the matched anchor box, so does avg_anyobj means all the confidence including the object's confidence?

leon-liangwu commented 4 years ago

@chengweige yes I see. If you refer to the original darknet implementation. You can find that the author didn't do the subtraction either. Because the positive places are much less than the non-objects, the outcomes will be similar in both cases. What's more. This is value does not affect the training procedure.