diff --git a/paddle/fluid/framework/op_proto_maker.h b/paddle/fluid/framework/op_proto_maker.h index 51aeed2e5d734ebf9d5018eaf2d2fce50dcd005e..9cea78c92c6a01bdeec1b766b6dea476c27767a4 100644 --- a/paddle/fluid/framework/op_proto_maker.h +++ b/paddle/fluid/framework/op_proto_maker.h @@ -96,12 +96,10 @@ class OpProtoAndCheckerMaker { template TypedAttrChecker &AddAttr(const std::string &name, - const std::string &comment, - bool generated = false) { + const std::string &comment) { auto *attr = proto_->add_attrs(); attr->set_name(name); attr->set_comment(comment); - attr->set_generated(generated); attr->set_type(AttrTypeID()); return op_checker_->AddAttrChecker(name, attr); } diff --git a/paddle/fluid/operators/detection/distribute_fpn_proposals_op.cc b/paddle/fluid/operators/detection/distribute_fpn_proposals_op.cc index 26db517690ef6767fe5162ca2752a710efb4a063..ec8d8a71008cbbda4a1ab8755a04829c8e3b8b7c 100644 --- a/paddle/fluid/operators/detection/distribute_fpn_proposals_op.cc +++ b/paddle/fluid/operators/detection/distribute_fpn_proposals_op.cc @@ -109,7 +109,7 @@ class DistributeFpnProposalsOpMaker : public framework::OpProtoAndCheckerMaker { "The referring scale of FPN layer with" " specified level"); AddAttr("pixel_offset", - "(bool, default True),", + "(bool, default True)," "If true, im_shape pixel offset is 1.") .SetDefault(true); AddComment(R"DOC( diff --git a/paddle/fluid/operators/detection/generate_proposals_v2_op.cc b/paddle/fluid/operators/detection/generate_proposals_v2_op.cc index e3b9219f249ccb7055011b6cea6895ea723aea90..eeda4c819e12aa074102b66b904a40f17b677aa3 100644 --- a/paddle/fluid/operators/detection/generate_proposals_v2_op.cc +++ b/paddle/fluid/operators/detection/generate_proposals_v2_op.cc @@ -82,7 +82,7 @@ class GenerateProposalsV2OpMaker : public framework::OpProtoAndCheckerMaker { "than this min_size."); AddAttr("eta", "The parameter for adaptive NMS."); AddAttr("pixel_offset", - "(bool, default True),", + "(bool, default True)," "If true, im_shape pixel offset is 1.") .SetDefault(true); AddComment(R"DOC( diff --git a/paddle/fluid/operators/detection/matrix_nms_op.cc b/paddle/fluid/operators/detection/matrix_nms_op.cc index 12fb9cb7dbc50af018908b240b40754dca6c86a6..1c0d19d9d5937d8e64e4fee9465a05ddf62333d0 100644 --- a/paddle/fluid/operators/detection/matrix_nms_op.cc +++ b/paddle/fluid/operators/detection/matrix_nms_op.cc @@ -85,7 +85,7 @@ class MatrixNMSOpMaker : public framework::OpProtoAndCheckerMaker { .SetDefault(false); AddAttr("gaussian_sigma", "(float) " - "Sigma for Gaussian decreasing function, only takes effect ", + "Sigma for Gaussian decreasing function, only takes effect " "when 'use_gaussian' is enabled.") .SetDefault(2.); AddOutput("Out", diff --git a/paddle/fluid/operators/graph_sample_neighbors_op.cc b/paddle/fluid/operators/graph_sample_neighbors_op.cc index b44a2823732d80fd54e27ea13004760022fc474e..14f17f77dcb6f34f29c91af4f1a7238d0f87b8c1 100644 --- a/paddle/fluid/operators/graph_sample_neighbors_op.cc +++ b/paddle/fluid/operators/graph_sample_neighbors_op.cc @@ -50,7 +50,7 @@ class GraphSampleNeighborsOpMaker : public framework::OpProtoAndCheckerMaker { AddOutput("Out_Eids", "The eids of the sample edges"); AddAttr( "sample_size", - "The sample size of graph sample neighbors method. ", + "The sample size of graph sample neighbors method. " "Set default value as -1, means return all neighbors of nodes.") .SetDefault(-1); AddAttr("return_eids", diff --git a/paddle/fluid/operators/tdm_child_op.cc b/paddle/fluid/operators/tdm_child_op.cc index 2dab74838a0b4ace591a8b4a34ddf0b6bc2ddb3b..1e98035039f85d86021f7ebf68bdb3b65a808e1f 100644 --- a/paddle/fluid/operators/tdm_child_op.cc +++ b/paddle/fluid/operators/tdm_child_op.cc @@ -34,7 +34,7 @@ class TDMChildOpMaker : public framework::OpProtoAndCheckerMaker { "information in the following format: item_id(shape=1), " "layer_id(shape=1), parent_id(shape=1), child_id(shape=child_nums)"); AddAttr("child_nums", - "child_nums(int)", + "child_nums(int)" "The child nums of one node, if the node hasn't enough child, " "it should padding 0 until child nums equal to child_nums"); AddOutput("Child",