|
@@ -173,6 +173,7 @@ py::class_<Type> bind_eigen_2(py::module &m, const char *name,
|
|
|
.def("cwiseQuotient", [](const Type &m1, const Type &m2) -> Type { return m1.cwiseQuotient(m2); })
|
|
|
|
|
|
/* Row and column-wise operations */
|
|
|
+ .def("rowwiseSet", [](Type &m, const Type &m2) {return Type(m.rowwise() = Eigen::Matrix<Scalar, 1, Eigen::Dynamic>(m2));} )
|
|
|
.def("rowwiseSum", [](const Type &m) {return Type(m.rowwise().sum());} )
|
|
|
.def("rowwiseProd", [](const Type &m) {return Type(m.rowwise().prod());} )
|
|
|
.def("rowwiseMean", [](const Type &m) {return Type(m.rowwise().mean());} )
|
|
@@ -181,6 +182,7 @@ py::class_<Type> bind_eigen_2(py::module &m, const char *name,
|
|
|
.def("rowwiseMinCoeff", [](const Type &m) {return Type(m.rowwise().minCoeff());} )
|
|
|
.def("rowwiseMaxCoeff", [](const Type &m) {return Type(m.rowwise().maxCoeff());} )
|
|
|
|
|
|
+ .def("colwiseSet", [](Type &m, const Type &m2) {return Type(m.colwise() = Eigen::Matrix<Scalar, Eigen::Dynamic, 1>(m2));} )
|
|
|
.def("colwiseSum", [](const Type &m) {return Type(m.colwise().sum());} )
|
|
|
.def("colwiseProd", [](const Type &m) {return Type(m.colwise().prod());} )
|
|
|
.def("colwiseMean", [](const Type &m) {return Type(m.colwise().mean());} )
|