diff --git a/fluid/face_detction/image_util.py b/fluid/face_detction/image_util.py index eb7be3ff84..210c49720b 100644 --- a/fluid/face_detction/image_util.py +++ b/fluid/face_detction/image_util.py @@ -75,11 +75,8 @@ def satisfy_sample_constraint(sampler, sample_bbox, bbox_labels): if sampler.min_jaccard_overlap == 0 and sampler.max_jaccard_overlap == 0: return True for i in range(len(bbox_labels)): - object_bbox = bbox( - bbox_labels[i][0], - bbox_labels[i][1], # tangxu @ 2018-05-17 - bbox_labels[i][2], - bbox_labels[i][3]) + object_bbox = bbox(bbox_labels[i][0], bbox_labels[i][1], + bbox_labels[i][2], bbox_labels[i][3]) overlap = jaccard_overlap(sample_bbox, object_bbox) if sampler.min_jaccard_overlap != 0 and \ overlap < sampler.min_jaccard_overlap: diff --git a/fluid/face_detction/pyramidbox.py b/fluid/face_detction/pyramidbox.py index 93faad05bf..ed80bea532 100644 --- a/fluid/face_detction/pyramidbox.py +++ b/fluid/face_detction/pyramidbox.py @@ -240,8 +240,7 @@ def permute_and_reshape(input, last_dim): self.prior_boxes = fluid.layers.concat(boxes) self.box_vars = fluid.layers.concat(vars) - def vgg_ssd(self, num_classes, image_shape): # tangxu - + def vgg_ssd(self, num_classes, image_shape): self.conv3_norm = self._l2_norm_scale(self.conv3) self.conv4_norm = self._l2_norm_scale(self.conv4) self.conv5_norm = self._l2_norm_scale(self.conv5) diff --git a/fluid/face_detction/train.py b/fluid/face_detction/train.py index fcd7a0da26..ae79f6f3dc 100644 --- a/fluid/face_detction/train.py +++ b/fluid/face_detction/train.py @@ -19,7 +19,7 @@ add_arg('batch_size', int, 16, "Minibatch size.") add_arg('num_passes', int, 120, "Epoch number.") add_arg('use_gpu', bool, True, "Whether use GPU.") -add_arg('use_pyramidbox', bool, False, "Whether use GPU.") +add_arg('use_pyramidbox', bool, False, "Whether use PyramidBox model.") add_arg('dataset', str, 'WIDERFACE', "coco2014, coco2017, and pascalvoc.") add_arg('model_save_dir', str, 'model', "The path to save model.") add_arg('pretrained_model', str, './vgg_model/', "The init model path.")