SourceXtractorPlusPlus
0.15
Please provide a description of the project.
SEFramework
SEFramework
Psf
VariablePsf.h
Go to the documentation of this file.
1
17
/*
18
* VariablePsf.h
19
*
20
* Created on: Jun 25, 2018
21
* Author: Alejandro Álvarez Ayllón
22
*/
23
24
#ifndef _SEIMPLEMENTATION_PSF_VARIABLEPSF_H_
25
#define _SEIMPLEMENTATION_PSF_VARIABLEPSF_H_
26
27
#include "
SEFramework/Image/VectorImage.h
"
28
#include "
SEFramework/Psf/Psf.h
"
29
30
namespace
SourceXtractor
{
31
48
class
VariablePsf
final :
public
Psf
{
49
public
:
56
struct
Component
{
57
std::string
name
;
58
int
group_id
;
59
double
offset
,
scale
;
60
};
61
74
VariablePsf
(
double
pixel_sampling,
const
std::vector<Component>
& components,
const
std::vector<int>
& group_degrees,
75
const
std::vector
<
std::shared_ptr
<
VectorImage<SeFloat>
>>& coefficients);
76
81
VariablePsf
(
double
pixel_sampling,
const
std::shared_ptr
<
VectorImage<SeFloat>
>& constant);
82
86
virtual
~VariablePsf
() =
default
;
87
91
int
getWidth
()
const override
;
92
96
int
getHeight
()
const override
;
97
101
double
getPixelSampling
()
const override
;
102
106
const
std::vector<std::string>
&
getComponents
()
const override
;
107
118
std::shared_ptr<VectorImage<SeFloat>
>
getPsf
(
const
std::vector<double>
& values)
const override
;
119
120
private
:
121
double
m_pixel_sampling
;
122
std::vector<Component>
m_components
;
123
std::vector<std::string>
m_component_names
;
124
std::vector<int>
m_group_degrees
;
125
std::vector<std::shared_ptr<VectorImage<SeFloat>
>>
m_coefficients
;
126
std::vector<std::vector<int>
>
m_exponents
;
127
129
void
selfTest
();
130
132
std::vector<double>
scaleProperties
(
const
std::vector<double>
& values)
const
;
133
147
void
calculateExponents
();
148
};
149
150
}
// namespace SourceXtractor
151
152
#endif
//_SEIMPLEMENTATION_PSF_VARIABLEPSF_H_
Psf.h
VectorImage.h
std::string
SourceXtractor::Psf
Definition:
Psf.h:27
SourceXtractor::VariablePsf
Implements a variable PSF using an arbitrary number of components (i.e. X, Y), and degrees.
Definition:
VariablePsf.h:48
SourceXtractor::VariablePsf::getPsf
std::shared_ptr< VectorImage< SeFloat > > getPsf(const std::vector< double > &values) const override
Definition:
VariablePsf.cpp:65
SourceXtractor::VariablePsf::getHeight
int getHeight() const override
Definition:
VariablePsf.cpp:53
SourceXtractor::VariablePsf::m_component_names
std::vector< std::string > m_component_names
Definition:
VariablePsf.h:123
SourceXtractor::VariablePsf::calculateExponents
void calculateExponents()
Definition:
VariablePsf.cpp:149
SourceXtractor::VariablePsf::getPixelSampling
double getPixelSampling() const override
Definition:
VariablePsf.cpp:57
SourceXtractor::VariablePsf::VariablePsf
VariablePsf(double pixel_sampling, const std::vector< Component > &components, const std::vector< int > &group_degrees, const std::vector< std::shared_ptr< VectorImage< SeFloat >>> &coefficients)
Definition:
VariablePsf.cpp:31
SourceXtractor::VariablePsf::~VariablePsf
virtual ~VariablePsf()=default
SourceXtractor::VariablePsf::scaleProperties
std::vector< double > scaleProperties(const std::vector< double > &values) const
Normalizes the values.
Definition:
VariablePsf.cpp:136
SourceXtractor::VariablePsf::m_exponents
std::vector< std::vector< int > > m_exponents
Definition:
VariablePsf.h:126
SourceXtractor::VariablePsf::m_coefficients
std::vector< std::shared_ptr< VectorImage< SeFloat > > > m_coefficients
Definition:
VariablePsf.h:125
SourceXtractor::VariablePsf::getWidth
int getWidth() const override
Definition:
VariablePsf.cpp:49
SourceXtractor::VariablePsf::m_components
std::vector< Component > m_components
Definition:
VariablePsf.h:122
SourceXtractor::VariablePsf::getComponents
const std::vector< std::string > & getComponents() const override
Definition:
VariablePsf.cpp:61
SourceXtractor::VariablePsf::m_group_degrees
std::vector< int > m_group_degrees
Definition:
VariablePsf.h:124
SourceXtractor::VariablePsf::m_pixel_sampling
double m_pixel_sampling
Definition:
VariablePsf.h:121
SourceXtractor::VariablePsf::selfTest
void selfTest()
Verify that the preconditions of getPsf are met at construction time.
Definition:
VariablePsf.cpp:92
SourceXtractor::VectorImage
Image implementation which keeps the pixel values in memory.
Definition:
VectorImage.h:52
SourceXtractor
Definition:
Aperture.h:30
std::shared_ptr
SourceXtractor::VariablePsf::Component
Definition:
VariablePsf.h:56
SourceXtractor::VariablePsf::Component::name
std::string name
Definition:
VariablePsf.h:57
SourceXtractor::VariablePsf::Component::offset
double offset
Definition:
VariablePsf.h:59
SourceXtractor::VariablePsf::Component::group_id
int group_id
Definition:
VariablePsf.h:58
SourceXtractor::VariablePsf::Component::scale
double scale
Definition:
VariablePsf.h:59
std::vector
Generated by
1.9.1