SourceXtractorPlusPlus 1.0.3
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
LdacOutput.h
Go to the documentation of this file.
1/*
2 * LdacOutput.h
3 *
4 * Created on: Feb 10, 2022
5 * Author: mschefer
6 */
7
8#ifndef _SEIMPLEMENTATION_OUTPUT_LDACOUTPUT_H_
9#define _SEIMPLEMENTATION_OUTPUT_LDACOUTPUT_H_
10
11#include "Table/FitsWriter.h"
12
14
15namespace SourceXtractor {
16
18
19public:
20 LdacOutput (const std::string& filename, SourceToRowConverter source_to_row, size_t flush_size)
21 : FlushableOutput(source_to_row, flush_size), m_filename(filename), m_part_nb(0), m_rms(0), m_gain(0) {
22 }
23
24 void nextPart() override;
25
26 void outputSource(const SourceInterface& source) override;
27
28protected:
29 void writeRows(const std::vector<Euclid::Table::Row>& rows) override {
30 Euclid::Table::Table table {rows};
31 m_fits_writer->addData(table);
32 }
33
34private:
35 void writeHeaders();
36
39
41
44 double m_gain;
45};
46
47}
48
49#endif /* _SEIMPLEMENTATION_OUTPUT_LDACOUTPUT_H_ */
FlushableOutput(SourceToRowConverter source_to_row, size_t flush_size)
std::function< Euclid::Table::Row(const SourceInterface &)> SourceToRowConverter
LdacOutput(const std::string &filename, SourceToRowConverter source_to_row, size_t flush_size)
Definition LdacOutput.h:20
std::map< std::string, MetadataEntry > m_image_metadata
Definition LdacOutput.h:42
std::shared_ptr< Euclid::Table::FitsWriter > m_fits_writer
Definition LdacOutput.h:40
void writeRows(const std::vector< Euclid::Table::Row > &rows) override
Definition LdacOutput.h:29
void outputSource(const SourceInterface &source) override
DetectionImage::PixelType m_rms
Definition LdacOutput.h:43
The SourceInterface is an abstract "source" that has properties attached to it.