23 #include <pybind11/pybind11.h>
25 #include <pybind11/stl.h>
30 namespace py = pybind11;
31 using namespace pybind11::literals;
33 using namespace lsst::afw::geom::ellipses;
36 py::module mod(
"_quadrupole",
"Python wrapper for afw _quadrupole library");
39 py::class_<Quadrupole, std::shared_ptr<Quadrupole>,
BaseCore> clsQuadrupole(mod,
"Quadrupole");
42 typedef Eigen::Matrix<double, 2, 2, Eigen::DontAlign> Matrix;
45 clsQuadrupole.def(py::init<double, double, double, bool>(),
"ixx"_a = 1.0,
"iyy"_a = 1.0,
"ixy"_a = 0.0,
46 "normalize"_a =
false);
47 clsQuadrupole.def(py::init<BaseCore::ParameterVector const &, bool>(),
"vector"_a,
"normalize"_a =
false);
48 clsQuadrupole.def(py::init<Matrix const &, bool>(),
"matrix"_a,
"normalize"_a =
true);
49 clsQuadrupole.def(py::init<Quadrupole const &>());
50 clsQuadrupole.def(py::init<BaseCore const &>());
51 clsQuadrupole.def(py::init<BaseCore::Convolution const &>());
53 py::implicitly_convertible<BaseCore::Convolution, Quadrupole>();
62 clsQuadrupole.def(
"getIxx", &Quadrupole::getIxx);
63 clsQuadrupole.def(
"getIyy", &Quadrupole::getIyy);
64 clsQuadrupole.def(
"getIxy", &Quadrupole::getIxy);
65 clsQuadrupole.def(
"setIxx", &Quadrupole::setIxx);
66 clsQuadrupole.def(
"setIyy", &Quadrupole::setIyy);
67 clsQuadrupole.def(
"setIxy", &Quadrupole::setIxy);
71 return std::static_pointer_cast<
Quadrupole>(
self.transform(t).copy());
74 self.transform(t).inPlace();
An ellipse core with quadrupole moments as parameters.
PYBIND11_PLUGIN(_cameraPoint)
void convolve(OutImageT &convolvedImage, InImageT const &inImage, KernelT const &kernel, ConvolutionControl const &convolutionControl=ConvolutionControl())
Convolve an Image or MaskedImage with a Kernel, setting pixels of an existing output image...
A base class for parametrizations of the "core" of an ellipse - the ellipticity and size...