diff --git a/python_binding/operator/pybind_Stack.cpp b/python_binding/operator/pybind_Stack.cpp index 9bd429002b721d56a1901ae44b2203a01ece9759..2328892108d724438a39cc37eaf97b856caa3a8a 100644 --- a/python_binding/operator/pybind_Stack.cpp +++ b/python_binding/operator/pybind_Stack.cpp @@ -12,18 +12,30 @@ #include <pybind11/pybind11.h> #include "aidge/data/Tensor.hpp" -#include "aidge/operator/Stack.hpp" #include "aidge/operator/OperatorTensor.hpp" +#include "aidge/operator/Stack.hpp" namespace py = pybind11; namespace Aidge { -void init_Stack(py::module& m) { - py::class_<StackOp, std::shared_ptr<StackOp>, OperatorTensor>(m, "StackOp", py::multiple_inheritance()) - .def(py::init<const std::uint32_t>(), py::arg("max_elements")) - .def_static("get_inputs_name", &StackOp::getInputsName) - .def_static("get_outputs_name", &StackOp::getOutputsName) - .def_readonly_static("Type", &StackOp::s_type); +void init_Stack(py::module &m) { + py::class_<StackOp, std::shared_ptr<StackOp>, OperatorTensor>( + m, + "StackOp", + py::multiple_inheritance(), + R"mydelimiter(Initialize a Stack operator.)mydelimiter") + .def(py::init<const std::uint32_t>(), py::arg("max_elements")) + .def_static("get_inputs_name", &StackOp::getInputsName) + .def_static("get_outputs_name", &StackOp::getOutputsName) + .def_readonly_static("Type", &StackOp::s_type); - m.def("Stack", &stack, py::arg("max_elements"), py::arg("name") = ""); -} + m.def("Stack", + &stack, + py::arg("max_elements"), + py::arg("name") = "", + R"mydelimiter( + Initialize a node containing a Stack operator. + :param max_elements : the maximum number of tensors to be stacked. + :param name: name of the node. + )mydelimiter"); } +} // namespace Aidge