Skip to content

Commit 3f5a441

Browse files
Merge pull request #16926 from tink2123/cherry-pick-yolov3
[Cherry-pick] polish yolov3_loss annotation
2 parents d8326ec + 36b22bb commit 3f5a441

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

paddle/fluid/API.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ paddle.fluid.layers.generate_mask_labels (ArgSpec(args=['im_info', 'gt_classes',
348348
paddle.fluid.layers.iou_similarity (ArgSpec(args=['x', 'y', 'name'], varargs=None, keywords=None, defaults=(None,)), ('document', '587845f60c5d97ffdf2dfd21da52eca1'))
349349
paddle.fluid.layers.box_coder (ArgSpec(args=['prior_box', 'prior_box_var', 'target_box', 'code_type', 'box_normalized', 'name', 'axis'], varargs=None, keywords=None, defaults=('encode_center_size', True, None, 0)), ('document', '032d0f4b7d8f6235ee5d91e473344f0e'))
350350
paddle.fluid.layers.polygon_box_transform (ArgSpec(args=['input', 'name'], varargs=None, keywords=None, defaults=(None,)), ('document', '0e5ac2507723a0b5adec473f9556799b'))
351-
paddle.fluid.layers.yolov3_loss (ArgSpec(args=['x', 'gt_box', 'gt_label', 'anchors', 'anchor_mask', 'class_num', 'ignore_thresh', 'downsample_ratio', 'gt_score', 'use_label_smooth', 'name'], varargs=None, keywords=None, defaults=(None, True, None)), ('document', '059021025283ad1ee6f4d32228cf3e4e'))
351+
paddle.fluid.layers.yolov3_loss (ArgSpec(args=['x', 'gt_box', 'gt_label', 'anchors', 'anchor_mask', 'class_num', 'ignore_thresh', 'downsample_ratio', 'gt_score', 'use_label_smooth', 'name'], varargs=None, keywords=None, defaults=(None, True, None)), ('document', '4d170807a13d33925d1049d2892832bf'))
352352
paddle.fluid.layers.yolo_box (ArgSpec(args=['x', 'img_size', 'anchors', 'class_num', 'conf_thresh', 'downsample_ratio', 'name'], varargs=None, keywords=None, defaults=(None,)), ('document', '5566169a5ab993d177792c023c7fb340'))
353353
paddle.fluid.layers.box_clip (ArgSpec(args=['input', 'im_info', 'name'], varargs=None, keywords=None, defaults=(None,)), ('document', '397e9e02b451d99c56e20f268fa03f2e'))
354354
paddle.fluid.layers.multiclass_nms (ArgSpec(args=['bboxes', 'scores', 'score_threshold', 'nms_top_k', 'keep_top_k', 'nms_threshold', 'normalized', 'nms_eta', 'background_label', 'name'], varargs=None, keywords=None, defaults=(0.3, True, 1.0, 0, None)), ('document', 'ca7d1107b6c5d2d6d8221039a220fde0'))

paddle/fluid/operators/detection/yolov3_loss_op.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,8 +171,8 @@ class Yolov3LossOpMaker : public framework::OpProtoAndCheckerMaker {
171171
172172
The output of previous network is in shape [N, C, H, W], while H and W
173173
should be the same, H and W specify the grid size, each grid point predict
174-
given number boxes, this given number, which following will be represented as S,
175-
is specified by the number of anchors, In the second dimension(the channel
174+
given number bounding boxes, this given number, which following will be represented as S,
175+
is specified by the number of anchor clusters in each scale. In the second dimension(the channel
176176
dimension), C should be equal to S * (class_num + 5), class_num is the object
177177
category number of source dataset(such as 80 in coco dataset), so in the
178178
second(channel) dimension, apart from 4 box location coordinates x, y, w, h,
@@ -203,7 +203,7 @@ class Yolov3LossOpMaker : public framework::OpProtoAndCheckerMaker {
203203
thresh, the confidence score loss of this anchor box will be ignored.
204204
205205
Therefore, the yolov3 loss consist of three major parts, box location loss,
206-
confidence score loss, and classification loss. The L2 loss is used for
206+
confidence score loss, and classification loss. The L1 loss is used for
207207
box coordinates (w, h), and sigmoid cross entropy loss is used for box
208208
coordinates (x, y), confidence score loss and classification loss.
209209

0 commit comments

Comments
 (0)