SourceXtractorPlusPlus 0.21
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
AutoPhotometryFlagTask.cpp
Go to the documentation of this file.
1
17/*
18 * AutoPhotometryFlagTask.cpp
19 *
20 * Created on: Oct 10, 2018
21 * Author: Alejandro Alvarez Ayllon
22 */
23
27
36
40
41namespace SourceXtractor {
42
44
46 // get the detection frame info
47 const auto& detection_frame_info = source.getProperty<DetectionFrameInfo>();
48 const auto variance_threshold = detection_frame_info.getVarianceThreshold();
49
50 // get detection frame images
51 const auto& detection_frame_images = source.getProperty<DetectionFrameImages>();
52
56
57 // get the object center
58 const auto& centroid_x = source.getProperty<PixelCentroid>().getCentroidX();
59 const auto& centroid_y = source.getProperty<PixelCentroid>().getCentroidY();
60
61 // get the shape parameters
62 const auto& cxx = source.getProperty<ShapeParameters>().getEllipseCxx();
63 const auto& cyy = source.getProperty<ShapeParameters>().getEllipseCyy();
64 const auto& cxy = source.getProperty<ShapeParameters>().getEllipseCxy();
65
66 // get the pixel list
67 const auto& pix_list = source.getProperty<PixelCoordinateList>().getCoordinateList();
68
69 // get the kron-radius
70 SeFloat kron_radius_auto = m_kron_factor * source.getProperty<KronRadius>().getKronRadius();
73
74 // create the elliptical aperture
76
77 // get the neighbourhood information
80
81 // set the source properties
83
84 // Draw the aperture
85 auto aperture_check_img = CheckImages::getInstance().getDetectionAutoApertureImage(detection_frame_info.getHduIndex());
87 auto src_id = source.getProperty<SourceID>().getId();
89 }
90}
91
92}
void computeProperties(SourceInterface &source) const override
Computes one or more properties for the Source.
static CheckImages & getInstance()
The centroid of all the pixels in the source, weighted by their DetectionImage pixel values.
The SourceInterface is an abstract "source" that has properties attached to it.
Flags computeFlags(const std::shared_ptr< Aperture > &aperture, SeFloat centroid_x, SeFloat centroid_y, const std::vector< PixelCoordinate > &pix_list, const std::shared_ptr< Image< SeFloat > > &detection_img, const std::shared_ptr< Image< SeFloat > > &detection_variance, const std::shared_ptr< Image< SeFloat > > &threshold_image, SeFloat variance_threshold)
Definition Flagging.cpp:27
Flags
Flagging of bad sources.
Definition SourceFlags.h:37
@ LayerVarianceMap
Definition Frame.h:45
@ LayerThresholdedImage
Definition Frame.h:41
@ LayerSubtractedImage
Definition Frame.h:39