From deec3ac1e95d7b3501c17d10bbeaa673475859a1 Mon Sep 17 00:00:00 2001 From: dengkaipeng Date: Wed, 20 Feb 2019 07:16:00 +0000 Subject: [PATCH] fix infer error. --- python/paddle/fluid/layers/detection.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/python/paddle/fluid/layers/detection.py b/python/paddle/fluid/layers/detection.py index b64e19320bd..aca5f0f1d64 100644 --- a/python/paddle/fluid/layers/detection.py +++ b/python/paddle/fluid/layers/detection.py @@ -655,8 +655,6 @@ def yolo_box(x, raise TypeError("Input img_size of yolo_box must be Variable") if not isinstance(anchors, list) and not isinstance(anchors, tuple): raise TypeError("Attr anchors of yolo_box must be list or tuple") - if not isinstance(anchor_mask, list) and not isinstance(anchor_mask, tuple): - raise TypeError("Attr anchor_mask of yolo_box must be list or tuple") if not isinstance(class_num, int): raise TypeError("Attr class_num of yolo_box must be an integer") if not isinstance(conf_thresh, float): @@ -668,7 +666,7 @@ def yolo_box(x, attrs = { "anchors": anchors, "class_num": class_num, - "conf_thresh": ignore_thresh, + "conf_thresh": conf_thresh, "downsample_ratio": downsample_ratio, } -- GitLab