I want to implement focal loss in DARKNET. How can I do that?
Focal loss already implemented for [yolo] layer.
It will be used if you set focal_loss=1 in each [yolo] layer.
what does it mean: in each [yolo] layer.
Find here 3 [yolo] layers: https://github.com/AlexeyAB/darknet/blob/master/cfg/yolov3.cfg
the network show: unused field focal =1
Can you show screenshot?
@AlexeyAB
thanks
below is mine cfg-file
[yolo]
focal_loss=1
mask = 6,7,8
anchors = 14, 13, 69, 16, 43, 56, 151, 33, 74, 93, 110,141, 152,206, 220,276, 332,374
classes=4
num=9
jitter=.3
ignore_thresh = .7
truth_thresh = 1
random=1
is there right?
Most helpful comment
Focal loss already implemented for
[yolo]layer.It will be used if you set
focal_loss=1in each[yolo]layer.https://github.com/AlexeyAB/darknet/blob/7a854302efb7adba80d5e8a747ad5e5ec384a226/src/yolo_layer.c#L158-L177