IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
EstimationConfig.h
1 // EstimationConfig.h:
3 // -------------------
4 //
15 
16 #ifndef __IPSDKMATH_ESTIMATIONCONFIG_H__
17 #define __IPSDKMATH_ESTIMATIONCONFIG_H__
18 
19 // suppression warnings
20 // warning C4251: 'ipsdk::math::EstimationConfig::_robustEstimationType': class 'ipsdk::math::eRobustEstimationType' needs to have dll-interface to be used by clients of class 'ipsdk::math::EstimationConfig'
21 #pragma warning (push)
22 #pragma warning (disable : 4251)
23 
26 #include <IPSDKSerialization/Engine/BaseSerializationObject.h>
27 
28 namespace ipsdk {
29 namespace math {
30 
33 
35 {
36  // declare serial class
38 
39 public:
45 
46 // methods
47 public:
49  bool isInit() const;
50 
51  //------------------------------
54  //------------------------------
55 
57  void initNonRobust();
58 
62  void initLMS(const ipReal64 expectedOutlierRatio = 0.4);
63 
68  void initRANSAC(const ipReal64 outlierThreshold,
69  const ipReal64 expectedOutlierRatio = 0.4);
70 
75  void initMSAC(const ipReal64 outlierThreshold,
76  const ipReal64 expectedOutlierRatio = 0.4);
77 
88  void initMLESAC(const ipReal64 gaussianSigma,
89  const ipReal64 outlierThresholdFactor = 3,
90  const ipReal64 outlierRangeFactor = 10,
91  const ipReal64 expectedOutlierRatio = 0.4);
92 
95  const eRobustEstimationType& getRobustEstimationType() const;
96 
99  ipReal64 getOutlierThreshold() const;
100 
103  ipReal64 getGaussianSigma() const;
104 
107  ipReal64 getOutlierThresholdFactor() const;
108 
111  ipReal64 getOutlierRangeFactor() const;
112 
115  ipReal64 getExpectedOutlierRatio() const;
117 
124  void setAllowSimpleEstimation(const bool bAllowSimpleEstimation);
125  bool getAllowSimpleEstimation() const;
127 
137  void setSuccessRatio(const ipReal64 successRatio);
138 
141  ipReal64 getSuccessRatio() const;
142 
147  void setDataPartition(const DataPartitionPtr& pDataPartition);
148 
153  void setAdaptiveGridPartition();
154  void setAdaptiveGridPartition(const ipUInt32 nbBucketsByAxis);
156 
160  void setRegularGridPartition();
161  void setRegularGridPartition(const ipUInt32 nbBucketsByAxis);
163 
166  DataPartitionPtr getDataPartitionPtr() const;
167 
169  void clear();
170 
171 // attributes
172 protected:
174  bool _bInit;
175 
178 
181 
184 
187 
195 
200 
208 
212 };
213 
216 
217 inline bool
219 {
220  return _bInit;
221 }
222 
225 
226 } // end of namespace math
227 } // end of namespace ipsdk
228 
229 #pragma warning (pop)
230 
231 #endif // __IPSDKMATH_ESTIMATIONCONFIG_H__
#define IPSDK_DECLARE_SERIAL_WITH_COPY(libraryName, className)
macro enabling serialization on class
Definition: SerializationHdrMacro.h:73
Definition of import/export macro for library.
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
boost::shared_ptr< BaseDataPartition > DataPartitionPtr
shared pointer to BaseDataPartition class
Definition: DataPartitionTypes.h:46
ipReal64 _outlierRangeFactor
used outlier range factor for processing
Definition: EstimationConfig.h:186
ipReal64 _expectedOutlierRatio
Definition: EstimationConfig.h:194
double ipReal64
Base types definition.
Definition: BaseTypes.h:57
eRobustEstimationType
Definition: EstimationTypes.h:40
ipReal64 _successRatio
Definition: EstimationConfig.h:207
bool isInit() const
check whether objet has been initialized
Definition: EstimationConfig.h:218
#define IPSDKMATH_API
Import/Export macro for library IPSDKMath.
Definition: IPSDKMathExports.h:27
DataPartitionPtr _pDataPartition
Definition: EstimationConfig.h:211
ipReal64 _gaussianSigma
used sigma for gaussian noise estimation
Definition: EstimationConfig.h:183
Configuration structure used for estimation management.
Definition: EstimationConfig.h:34
Predefined types for parametric estimation from data set.
eRobustEstimationType _robustEstimationType
robust estimation method
Definition: EstimationConfig.h:177
ipReal64 _outlierThreshold
used outlier threshold for processing
Definition: EstimationConfig.h:180
bool _bAllowSimpleEstimation
Definition: EstimationConfig.h:199
Base class for serializable class.
Definition: BaseSerializationObject.h:33
bool _bInit
flag indicating whether object has been initialized
Definition: EstimationConfig.h:174
uint32_t ipUInt32
Base types definition.
Definition: BaseTypes.h:53