diff --git a/include/aidge/graph/GraphView.hpp b/include/aidge/graph/GraphView.hpp index a1eacf74aa5273af75209db6fe0069fa33b2d29f..0e55db15abf80fc1ab7e416549cc9625a2785f7b 100644 --- a/include/aidge/graph/GraphView.hpp +++ b/include/aidge/graph/GraphView.hpp @@ -273,6 +273,15 @@ public: /** * Get the ranked list of nodes in the GraphView. + * Node ranking if performed the following: + * - The root node is put in the ranked list first (rank 1); + * - Then, its childs (in order of outputs) are added in the ranked list; + * - Then, its parents (in order of inputs) are added in the ranked list; + * - The childs and parents of the next node in the ranked list are then + * added to the list, and so on. + * - Any remaining nodes have no path to the root node and are added in + * arbitrary order. In this case, the ranking is not garanteed to be unique. + * * If the ranking cannot be garanteed to be unique, the second item indicates * the rank from which unicity cannot be garanteed. * @return std::pair<std::vector<NodePtr>, size_t> Pair with the list of ranked diff --git a/python_binding/operator/pybind_MetaOperatorDefs.cpp b/python_binding/operator/pybind_MetaOperatorDefs.cpp index 443baacf81e6228f5371a2ea1c557fa83b86a067..20a620cee737db5380ee7641b161cf6296ef7e5b 100644 --- a/python_binding/operator/pybind_MetaOperatorDefs.cpp +++ b/python_binding/operator/pybind_MetaOperatorDefs.cpp @@ -109,14 +109,7 @@ template <DimIdx_t DIM> void declare_PaddedMaxPoolingOp(py::module &m) { } void declare_LSTMOp(py::module &m) { - m.def("LSTM", [](DimSize_t in_channels, - DimSize_t hidden_channels, - DimSize_t seq_length, - bool nobias, - const std::string& name) - { - return LSTM(in_channels, hidden_channels, seq_length, nobias, name); - }, py::arg("in_channels"), + m.def("LSTM", &LSTM, py::arg("in_channels"), py::arg("hidden_channels"), py::arg("seq_length"), py::arg("nobias") = false,