23 #include <pybind11/pybind11.h>
32 using namespace py::literals;
37 py::class_<Distortion, detail::EllipticityBase>
cls(mod,
"Distortion");
41 cls.def(py::init<double, double>(),
"e1"_a = 0.0,
"e2"_a = 0.0);
46 cls.def(
"getAxisRatio", &Distortion::getAxisRatio);
47 cls.def(
"normalize", &Distortion::normalize);
48 cls.def(
"getName", &Distortion::getName);
50 return py::str(
"{}({}, {})").format(
self.getName(),
self.getE1(),
self.getE2());