OTB  10.0.0
Orfeo Toolbox
otbShiftScaleSampleListFilter.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2024 Centre National d'Etudes Spatiales (CNES)
3  *
4  * This file is part of Orfeo Toolbox
5  *
6  * https://www.orfeo-toolbox.org/
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 #ifndef otbShiftScaleSampleListFilter_h
22 #define otbShiftScaleSampleListFilter_h
23 
25 
26 
27 namespace otb
28 {
29 namespace Statistics
30 {
31 
50 template <class TInputSampleList, class TOutputSampleList = TInputSampleList>
51 class ITK_EXPORT ShiftScaleSampleListFilter : public otb::Statistics::ListSampleToListSampleFilter<TInputSampleList, TOutputSampleList>
52 {
53 public:
57  typedef itk::SmartPointer<Self> Pointer;
58  typedef itk::SmartPointer<const Self> ConstPointer;
59 
62 
64  itkNewMacro(Self);
65 
67  typedef TInputSampleList InputSampleListType;
68  typedef typename InputSampleListType::Pointer InputSampleListPointer;
69  typedef typename InputSampleListType::ConstPointer InputSampleListConstPointer;
70  typedef typename InputSampleListType::MeasurementVectorType InputMeasurementVectorType;
71  typedef typename InputMeasurementVectorType::ValueType InputValueType;
72 
74  typedef TOutputSampleList OutputSampleListType;
75  typedef typename OutputSampleListType::Pointer OutputSampleListPointer;
76  typedef typename OutputSampleListType::ConstPointer OutputSampleListConstPointer;
77  typedef typename OutputSampleListType::MeasurementVectorType OutputMeasurementVectorType;
78  typedef typename OutputMeasurementVectorType::ValueType OutputValueType;
79 
81  itkSetMacro(Shifts, InputMeasurementVectorType);
82  itkGetMacro(Shifts, InputMeasurementVectorType);
84 
86  itkSetMacro(Scales, InputMeasurementVectorType);
87  itkGetMacro(Scales, InputMeasurementVectorType);
89 
90 protected:
92  void GenerateData() override;
93 
96  {
97  }
98  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
99 
100 private:
102  void operator=(const Self&) = delete;
103 
106 
109 
110 }; // end of class ShiftScaleSampleListFilter
111 
112 } // end of namespace Statistics
113 } // end of namespace otb
114 
115 #ifndef OTB_MANUAL_INSTANTIATION
117 #endif
118 
119 #endif
This class is a base class for filters using ListSample as input and returning ListSample.
This class is a base class for filters using ListSample as input and returning ListSample.
This class generate a shifted and scaled version of the input sample list.
OutputSampleListType::MeasurementVectorType OutputMeasurementVectorType
OutputMeasurementVectorType::ValueType OutputValueType
InputMeasurementVectorType::ValueType InputValueType
InputSampleListType::MeasurementVectorType InputMeasurementVectorType
otb::Statistics::ListSampleToListSampleFilter< TInputSampleList, TOutputSampleList > Superclass
OutputSampleListType::ConstPointer OutputSampleListConstPointer
InputSampleListType::ConstPointer InputSampleListConstPointer
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.