Skip to content

Commit

Permalink
Use shared_ptr holde for Problem (#45)
Browse files Browse the repository at this point in the history
  • Loading branch information
sarlinpe authored May 27, 2024
1 parent 3f34fa4 commit 807ee5d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion _pyceres/core/problem.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ void BindProblem(py::module& m) {

py::class_<ResidualBlockIDWrapper> residual_block_wrapper(m, "ResidualBlock");

py::class_<ceres::Problem>(m, "Problem")
py::class_<ceres::Problem, std::shared_ptr<ceres::Problem>>(m, "Problem")
.def(py::init(&CreatePythonProblem))
.def(py::init<ceres::Problem::Options>())
.def("num_parameter_blocks", &ceres::Problem::NumParameterBlocks)
Expand Down

0 comments on commit 807ee5d

Please sign in to comment.