SourceXtractorPlusPlus  0.12
Please provide a description of the project.
Public Member Functions | Private Attributes | List of all members
TestImage Class Reference
Inheritance diagram for TestImage:
[legend]
Collaboration diagram for TestImage:
[legend]

Public Member Functions

po::options_description defineSpecificProgramOptions () override
 
void addSource (std::vector< PointModel > &point_models, std::vector< std::shared_ptr< ModelFitting::ExtendedModel< WriteableInterfaceTypePtr >>> &extended_models, double size, const TestImageSource &source, std::tuple< double, double, double, double > jacobian)
 
void addPointSource (std::vector< PointModel > &point_models, double x, double y, double flux)
 
void addBackgroundNoise (std::shared_ptr< WriteableImage< SeFloat >> image, double background_level, double background_sigma)
 
void addPoissonNoise (std::shared_ptr< WriteableImage< SeFloat >> image, double gain)
 
void saturate (std::shared_ptr< WriteableImage< SeFloat >> image, double saturation_level)
 
void addBadPixels (std::shared_ptr< WriteableImage< SeFloat >> weight_map, double probability)
 
void addBadColumns (std::shared_ptr< WriteableImage< SeFloat >> weight_map, double probability)
 
std::vector< TestImageSourcegenerateRandomSources (int number_of_sources, double x_min, double y_min, double x_max, double y_max)
 
std::vector< TestImageSourceloadSourcesFromFile (const std::string &filename)
 
void saveSources (const std::vector< TestImageSource > &sources, const std::string &filename)
 
void transformSources (std::vector< TestImageSource > &sources, int image_size, double rot_angle, double scale, double shift_x, double shift_y)
 
std::vector< TestImageSourceloadSourcesFromCatalog (const std::string &filename)
 
Elements::ExitCode mainMethod (std::map< std::string, po::variable_value > &args) override
 
- Public Member Functions inherited from Elements::Program
 Program ()=default
 
virtual ~Program ()
 
virtual std::pair< boost::program_options::options_description, boost::program_options::positional_options_description > defineProgramArguments ()
 
virtual ExitCode mainMethod (std::map< std::string, boost::program_options::variable_value > &args)=0
 

Private Attributes

boost::random::mt19937 m_rng { (unsigned int) time(NULL) }
 
double m_zero_point = 0.0
 
double m_exp_time = 300.
 

Detailed Description

Definition at line 165 of file TestImage.cpp.

Member Function Documentation

◆ addBackgroundNoise()

void TestImage::addBackgroundNoise ( std::shared_ptr< WriteableImage< SeFloat >>  image,
double  background_level,
double  background_sigma 
)
inline

Definition at line 266 of file TestImage.cpp.

References x, and y.

◆ addBadColumns()

void TestImage::addBadColumns ( std::shared_ptr< WriteableImage< SeFloat >>  weight_map,
double  probability 
)
inline

Definition at line 313 of file TestImage.cpp.

References x, and y.

◆ addBadPixels()

void TestImage::addBadPixels ( std::shared_ptr< WriteableImage< SeFloat >>  weight_map,
double  probability 
)
inline

Definition at line 301 of file TestImage.cpp.

References x, and y.

◆ addPointSource()

void TestImage::addPointSource ( std::vector< PointModel > &  point_models,
double  x,
double  y,
double  flux 
)
inline

Definition at line 258 of file TestImage.cpp.

References std::vector< T >::emplace_back(), x, and y.

Here is the call graph for this function:

◆ addPoissonNoise()

void TestImage::addPoissonNoise ( std::shared_ptr< WriteableImage< SeFloat >>  image,
double  gain 
)
inline

Definition at line 277 of file TestImage.cpp.

References x, and y.

◆ addSource()

void TestImage::addSource ( std::vector< PointModel > &  point_models,
std::vector< std::shared_ptr< ModelFitting::ExtendedModel< WriteableInterfaceTypePtr >>> &  extended_models,
double  size,
const TestImageSource source,
std::tuple< double, double, double, double >  jacobian 
)
inline

◆ defineSpecificProgramOptions()

po::options_description TestImage::defineSpecificProgramOptions ( )
inlineoverridevirtual

Reimplemented from Elements::Program.

Definition at line 169 of file TestImage.cpp.

◆ generateRandomSources()

std::vector<TestImageSource> TestImage::generateRandomSources ( int  number_of_sources,
double  x_min,
double  y_min,
double  x_max,
double  y_max 
)
inline

Definition at line 325 of file TestImage.cpp.

References gal_dev_max_i0, gal_dev_min_i0, gal_exp_max_i0, gal_exp_min_i0, and std::vector< T >::push_back().

Here is the call graph for this function:

◆ loadSourcesFromCatalog()

std::vector<TestImageSource> TestImage::loadSourcesFromCatalog ( const std::string filename)
inline

◆ loadSourcesFromFile()

std::vector<TestImageSource> TestImage::loadSourcesFromFile ( const std::string filename)
inline

◆ mainMethod()

Elements::ExitCode TestImage::mainMethod ( std::map< std::string, po::variable_value > &  args)
inlineoverride

◆ saturate()

void TestImage::saturate ( std::shared_ptr< WriteableImage< SeFloat >>  image,
double  saturation_level 
)
inline

Definition at line 291 of file TestImage.cpp.

References std::min(), x, and y.

Here is the call graph for this function:

◆ saveSources()

void TestImage::saveSources ( const std::vector< TestImageSource > &  sources,
const std::string filename 
)
inline

Definition at line 391 of file TestImage.cpp.

References conf::filename, and std::ofstream::open().

Here is the call graph for this function:

◆ transformSources()

void TestImage::transformSources ( std::vector< TestImageSource > &  sources,
int  image_size,
double  rot_angle,
double  scale,
double  shift_x,
double  shift_y 
)
inline

Definition at line 403 of file TestImage.cpp.

References std::cos(), s, std::sin(), x, and y.

Here is the call graph for this function:

Member Data Documentation

◆ m_exp_time

double TestImage::m_exp_time = 300.
private

Definition at line 658 of file TestImage.cpp.

◆ m_rng

boost::random::mt19937 TestImage::m_rng { (unsigned int) time(NULL) }
private

Definition at line 657 of file TestImage.cpp.

◆ m_zero_point

double TestImage::m_zero_point = 0.0
private

Definition at line 658 of file TestImage.cpp.


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