lsst.afw gba399f52f3+9b61cfce8e
Loading...
Searching...
No Matches
lsst::afw::detection::PsfTrampoline< Base > Class Template Reference

"Trampoline" for Psf to let it be used as a base class in Python. More...

#include <python.h>

Inheritance diagram for lsst::afw::detection::PsfTrampoline< Base >:
lsst::afw::typehandling::StorableHelper< Base >

Public Types

using Image = typename Base::Image

Public Member Functions

template<typename... Args>
 PsfTrampoline (Args... args)
 Delegating constructor for wrapped class.
std::shared_ptr< Psf > clone () const override
std::shared_ptr< Psf > resized (int width, int height) const override
lsst::geom::Point2D getAveragePosition () const override
std::shared_ptr< Image > doComputeImage (lsst::geom::Point2D const &position, image::Color const &color) const override
lsst::geom::Box2I doComputeImageBBox (lsst::geom::Point2D const &position, image::Color const &color) const override
std::shared_ptr< Image > doComputeKernelImage (lsst::geom::Point2D const &position, image::Color const &color) const override
double doComputeApertureFlux (double radius, lsst::geom::Point2D const &position, image::Color const &color) const override
geom::ellipses::Quadrupole doComputeShape (lsst::geom::Point2D const &position, image::Color const &color) const override
lsst::geom::Box2I doComputeBBox (lsst::geom::Point2D const &position, image::Color const &color) const override
std::shared_ptr< Storable > cloneStorable () const override
std::string toString () const override
std::size_t hash_value () const override
bool equals (Storable const &other) const noexcept override
bool isPersistable () const noexcept override
std::string getPersistenceName () const override
std::string getPythonModule () const override
void write (table::io::OutputArchiveHandle &handle) const override

(Note that these are not member symbols.)

#define LSST_EXCEPTION_TYPE(t, b, c)

Detailed Description

template<typename Base = Psf>
class lsst::afw::detection::PsfTrampoline< Base >

"Trampoline" for Psf to let it be used as a base class in Python.

Subclasses of Psf that are wrapped in pybind11 should have a similar helper that subclasses PsfTrampoline<subclass>. This helper can be skipped if the subclass neither adds any virtual methods nor implements any abstract methods.

Template Parameters
Basethe exact (most specific) class being wrapped
See also
pybind11 documentation

Definition at line 50 of file python.h.

Member Typedef Documentation

◆ Image

template<typename Base = Psf>
using lsst::afw::detection::PsfTrampoline< Base >::Image = typename Base::Image

Definition at line 52 of file python.h.

Constructor & Destructor Documentation

◆ PsfTrampoline()

template<typename Base = Psf>
template<typename... Args>
lsst::afw::detection::PsfTrampoline< Base >::PsfTrampoline ( Args... args)
inlineexplicit

Delegating constructor for wrapped class.

While we would like to simply inherit base class constructors, when doing so, we cannot change their access specifiers. One consequence is that it's not possible to use inheritance to expose a protected constructor to python. The alternative, used here, is to create a new public constructor that delegates to the base class public or protected constructor with the same signature.

Template Parameters
ArgsVariadic type specification
Parameters
...argsArguments to forward to the Base class constructor.

Definition at line 1 of file python.h.

Member Function Documentation

◆ clone()

template<typename Base = Psf>
std::shared_ptr< Psf > lsst::afw::detection::PsfTrampoline< Base >::clone ( ) const
inlineoverride

Definition at line 69 of file python.h.

◆ cloneStorable()

template<class Base = Storable>
std::shared_ptr< Storable > lsst::afw::typehandling::StorableHelper< Base >::cloneStorable ( ) const
inlineoverrideinherited

Definition at line 73 of file python.h.

◆ doComputeApertureFlux()

template<typename Base = Psf>
double lsst::afw::detection::PsfTrampoline< Base >::doComputeApertureFlux ( double radius,
lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 112 of file python.h.

◆ doComputeBBox()

template<typename Base = Psf>
lsst::geom::Box2I lsst::afw::detection::PsfTrampoline< Base >::doComputeBBox ( lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 130 of file python.h.

◆ doComputeImage()

template<typename Base = Psf>
std::shared_ptr< Image > lsst::afw::detection::PsfTrampoline< Base >::doComputeImage ( lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 85 of file python.h.

◆ doComputeImageBBox()

template<typename Base = Psf>
lsst::geom::Box2I lsst::afw::detection::PsfTrampoline< Base >::doComputeImageBBox ( lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 94 of file python.h.

◆ doComputeKernelImage()

template<typename Base = Psf>
std::shared_ptr< Image > lsst::afw::detection::PsfTrampoline< Base >::doComputeKernelImage ( lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 103 of file python.h.

◆ doComputeShape()

template<typename Base = Psf>
geom::ellipses::Quadrupole lsst::afw::detection::PsfTrampoline< Base >::doComputeShape ( lsst::geom::Point2D const & position,
image::Color const & color ) const
inlineoverride

Definition at line 121 of file python.h.

◆ equals()

template<class Base = Storable>
bool lsst::afw::typehandling::StorableHelper< Base >::equals ( Storable const & other) const
inlineoverridenoexceptinherited

Definition at line 88 of file python.h.

◆ getAveragePosition()

template<typename Base = Psf>
lsst::geom::Point2D lsst::afw::detection::PsfTrampoline< Base >::getAveragePosition ( ) const
inlineoverride

Definition at line 80 of file python.h.

◆ getPersistenceName()

template<class Base = Storable>
std::string lsst::afw::typehandling::StorableHelper< Base >::getPersistenceName ( ) const
inlineoverrideinherited

Definition at line 98 of file python.h.

◆ getPythonModule()

template<class Base = Storable>
std::string lsst::afw::typehandling::StorableHelper< Base >::getPythonModule ( ) const
inlineoverrideinherited

Definition at line 104 of file python.h.

◆ hash_value()

template<class Base = Storable>
std::size_t lsst::afw::typehandling::StorableHelper< Base >::hash_value ( ) const
inlineoverrideinherited

Definition at line 84 of file python.h.

◆ isPersistable()

template<class Base = Storable>
bool lsst::afw::typehandling::StorableHelper< Base >::isPersistable ( ) const
inlineoverridenoexceptinherited

Definition at line 92 of file python.h.

◆ resized()

template<typename Base = Psf>
std::shared_ptr< Psf > lsst::afw::detection::PsfTrampoline< Base >::resized ( int width,
int height ) const
inlineoverride

Definition at line 76 of file python.h.

◆ toString()

template<class Base = Storable>
std::string lsst::afw::typehandling::StorableHelper< Base >::toString ( ) const
inlineoverrideinherited

Definition at line 80 of file python.h.

◆ write()

template<typename Base>
void lsst::afw::typehandling::StorableHelper< Base >::write ( table::io::OutputArchiveHandle & handle) const
overrideinherited

Definition at line 193 of file python.h.


The documentation for this class was generated from the following file: