23 #include <pybind11/pybind11.h> 36 py::class_<detail::EllipticityBase>
cls(mod,
"EllipticityBase");
39 py::enum_<detail::EllipticityBase::ParameterEnum>(
cls,
"ParameterEnum")
40 .value(
"E1", detail::EllipticityBase::ParameterEnum::E1)
41 .value(
"E2", detail::EllipticityBase::ParameterEnum::E2)
47 cls.def(
"setComplex", &detail::EllipticityBase::setComplex);
48 cls.def(
"getE1", &detail::EllipticityBase::getE1);
49 cls.def(
"setE1", &detail::EllipticityBase::setE1);
50 cls.def(
"getE2", &detail::EllipticityBase::getE2);
51 cls.def(
"setE2", &detail::EllipticityBase::setE2);
52 cls.def(
"getTheta", &detail::EllipticityBase::getTheta);
54 return py::str(
"(%g, %g)").format(
self.getE1(),
self.getE2());
PYBIND11_MODULE(ellipticityBase, mod)
EllipticityBase is a base class for complex ellipticity types.