icp_sequence.cpp
Go to the documentation of this file.
1 #include <fstream>
2 
3 #include "icp_sequence.h"
4 
5 namespace python
6 {
7  namespace pointmatcher
8  {
9  void pybindICPSequence(py::class_<PM>& p_class)
10  {
11  py::class_<ICPSequence, ICP> pyICPSequence(p_class, "ICPSequence");
12 
13  pyICPSequence.doc() = R"pbdoc(
14 ICP alogrithm, taking a sequence of clouds and using a map
15 Warning: used with caution, you need to set the map manually.
16 )pbdoc";
17 
18  pyICPSequence.def(py::init<>())
19  .def("__call__", (TransformationParameters(ICPSequence::*)(const DataPoints&)) &ICPSequence::operator(), py::arg("cloudIn"))
20  .def("__call__", (TransformationParameters(ICPSequence::*)(const DataPoints&, const TransformationParameters&)) &ICPSequence::operator(), py::arg("cloudIn"), py::arg("initialTransformationParameters"))
21  .def("compute", &ICPSequence::compute, py::arg("cloudIn"), py::arg("initialTransformationParameters"))
22 
23  .def("hasMap", &ICPSequence::hasMap).def("setMap", &ICPSequence::setMap)
24  .def("clearMap", &ICPSequence::clearMap).def("setDefault", &ICPSequence::setDefault)
25  .def("loadFromYaml", [](ICPSequence& self, const std::string& in)
26  {
27  std::ifstream ifs(in.c_str());
28  self.loadFromYaml(ifs);
29  }).def("getPrefilteredInternalMap", &ICPSequence::getPrefilteredInternalMap)
30  .def("getPrefilteredMap", &ICPSequence::getPrefilteredMap);
31  }
32  }
33 }
void pybindICPSequence(py::class_< PM > &p_class)
Definition: icp_sequence.cpp:9
::std::string string
Definition: gtest.h:1979
PM::ICPSequence ICPSequence
PM::TransformationParameters TransformationParameters


libpointmatcher
Author(s):
autogenerated on Sat May 27 2023 02:38:02