Skip to content

Commit

Permalink
fix spurious copy
Browse files Browse the repository at this point in the history
  • Loading branch information
PierreMarchand20 committed Oct 30, 2024
1 parent cd764b9 commit 3c57c3d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/htool/clustering/cluster_node.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ void declare_cluster_node(py::module &m, const std::string &className) {

py_class.def("get_size", &Class::get_size);
py_class.def("get_offset", &Class::get_offset);
py_class.def("get_minclustersize", &Class::get_minclustersize);
py_class.def("get_permutation", [](const Class &self) {
auto &permutation = self.get_permutation();
return py::array_t<int>(std::array<std::size_t, 1>{permutation.size()}, permutation.data(), py::capsule(permutation.data()));
Expand Down
2 changes: 1 addition & 1 deletion src/htool/solver/utility.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ void declare_solver_utility(py::module &m, std::string prefix = "") {
"solver", [](const DDMSolverBuilder &self) { return &self.solver; }, py::return_value_policy::reference_internal);
ddm_solver_class.def_property_readonly("local_to_global_numbering", [](const DDMSolverBuilder &self) { return &self.local_to_global_numbering; }, py::return_value_policy::reference_internal);
ddm_solver_class.def(
"get_local_hmatrix", [](const DDMSolverBuilder &self) { return *self.local_hmatrix.get(); });
"get_local_hmatrix", [](const DDMSolverBuilder &self) { return self.local_hmatrix.get(); }, py::return_value_policy::reference_internal);
}
#endif

0 comments on commit 3c57c3d

Please sign in to comment.