From 641166a50774a11d2d96327f6e6dff25e3c02cac Mon Sep 17 00:00:00 2001 From: Ivan Volgushev <41115145+VanyaVolgushev@users.noreply.github.com> Date: Wed, 15 Jan 2025 14:26:30 +0300 Subject: [PATCH] Update src/python_bindings/nar/bind_nar.cpp Co-authored-by: BUYT-1 <59949541+BUYT-1@users.noreply.github.com> --- src/python_bindings/nar/bind_nar.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/python_bindings/nar/bind_nar.cpp b/src/python_bindings/nar/bind_nar.cpp index 553cd0153a..6ba4ee7986 100644 --- a/src/python_bindings/nar/bind_nar.cpp +++ b/src/python_bindings/nar/bind_nar.cpp @@ -55,11 +55,6 @@ void BindNar(py::module_& main_module) { .def_property_readonly("ante", &NAR::GetAnte, py::return_value_policy::move) .def_property_readonly("cons", &NAR::GetCons, py::return_value_policy::move); - py::class_(nar_module, "NarAlgorithm") - .def("get_nars", &NARAlgorithm::GetNARVector); - - auto algos_module = nar_module.def_submodule("algorithms"); - auto default_algorithm = detail::RegisterAlgorithm(algos_module, "des"); - algos_module.attr("Default") = default_algorithm; + BindPrimitive(nar_module, &NARAlgorithm::GetNARVector, "NarAlgorithm", "get_nars", {"DES"}, pybind11::return_value_policy::copy); } } // namespace python_bindings