Skip to content

Commit

Permalink
Merge pull request #10 from laipaang/init-metric
Browse files Browse the repository at this point in the history
init_metric default arg
  • Loading branch information
qingshui committed Jul 2, 2021
2 parents e49656a + 762f817 commit f720b3a
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions paddle/fluid/pybind/box_helper_py.cc
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,19 @@ void BindBoxWrapper(py::module* m) {
.def("initialize_auc_runner", &framework::BoxWrapper::InitializeAucRunner,
py::call_guard<py::gil_scoped_release>())
.def("init_metric", &framework::BoxWrapper::InitMetric,
py::arg("method"),
py::arg("name"),
py::arg("label_varname"),
py::arg("pred_varname"),
py::arg("cmatch_rank_varname"),
py::arg("mask_varname"),
py::arg("metric_phase"),
py::arg("cmatch_rank_group"),
py::arg("ignore_rank"),
py::arg("bucket_size") = 1000000,
py::arg("mode_collect_in_gpu") = false,
py::arg("max_batch_size") = 0,
py::arg("sample_scale_varnam") = "",
py::call_guard<py::gil_scoped_release>())
.def("get_metric_msg", &framework::BoxWrapper::GetMetricMsg,
py::call_guard<py::gil_scoped_release>())
Expand Down

0 comments on commit f720b3a

Please sign in to comment.