SourceXtractorPlusPlus
0.10
Please provide a description of the project.
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
SEImplementation
src
lib
CheckImages
MoffatCheckImage.cpp
Go to the documentation of this file.
1
17
/*
18
* MoffatCheckImage.cpp
19
*
20
* Created on: 2019 M02 5
21
* Author: mschefer
22
*/
23
24
25
#include "
SEFramework/Source/SourceGroupInterface.h
"
26
27
#include "
SEImplementation/Property/PixelCoordinateList.h
"
28
#include "
SEImplementation/CheckImages/CheckImages.h
"
29
30
#include "
SEImplementation/Plugin/MoffatModelFitting/MoffatModelFitting.h
"
31
#include "
SEImplementation/Plugin/MoffatModelFitting/MoffatModelEvaluator.h
"
32
33
#include "
SEImplementation/CheckImages/MoffatCheckImage.h
"
34
35
namespace
SourceXtractor {
36
37
using namespace
ModelFitting;
38
39
void
MoffatCheckImage::handleMessage
(
const
std::shared_ptr<SourceGroupInterface>
& group) {
40
if
(m_check_image) {
41
42
for
(
auto
& source : *group) {
43
auto
& model = source.getProperty<
MoffatModelEvaluator
>();
44
45
if
(model.getIterations() == 0) {
46
continue
;
47
}
48
49
std::lock_guard<std::mutex>
lock
(
CheckImages::getInstance
().m_access_mutex);
50
for
(
int
y
=0;
y
<m_check_image->getHeight();
y
++) {
51
for
(
int
x
=0;
x
<m_check_image->getWidth();
x
++) {
52
m_check_image->setValue(
x
,
y
, m_check_image->getValue(
x
,
y
) + model.getValue(
x
- 0.5,
y
- 0.5));
53
}
54
}
55
}
56
}
57
}
58
59
}
60
61
62
PixelCoordinateList.h
std::shared_ptr< SourceGroupInterface >
MoffatCheckImage.h
x
std::shared_ptr< DependentParameter< std::shared_ptr< EngineParameter > > > x
Definition:
MoffatModelFittingTask.cpp:93
SourceXtractor::MoffatCheckImage::handleMessage
virtual void handleMessage(const std::shared_ptr< SourceGroupInterface > &group)
Definition:
MoffatCheckImage.cpp:39
SourceGroupInterface.h
y
std::shared_ptr< DependentParameter< std::shared_ptr< EngineParameter > > > y
Definition:
MoffatModelFittingTask.cpp:93
SourceXtractor::CheckImages::getInstance
static CheckImages & getInstance()
Definition:
CheckImages.h:114
std::lock
T lock(T...args)
MoffatModelFitting.h
SourceXtractor::MoffatModelEvaluator
Definition:
MoffatModelEvaluator.h:35
std::lock_guard
MoffatModelEvaluator.h
CheckImages.h
Generated by
1.8.5