OTB  10.0.0
Orfeo Toolbox
otbJointMassOfBeliefFilter.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 otbJointMassOfBeliefFilter_h
22 #define otbJointMassOfBeliefFilter_h
23 
24 #include "itkProcessObject.h"
25 
26 namespace otb
27 {
40 template <class TMassFunction>
41 class ITK_EXPORT JointMassOfBeliefFilter : public itk::ProcessObject
42 {
43 public:
46  typedef itk::ProcessObject Superclass;
47  typedef itk::SmartPointer<Self> Pointer;
48  typedef itk::SmartPointer<const Self> ConstPointer;
49 
51  itkNewMacro(Self);
52 
54  itkTypeMacro(JointMassOfBeliefFilter, ProcessObject);
55 
57  typedef TMassFunction MassFunctionType;
58  typedef typename MassFunctionType::Pointer MassFunctionPointerType;
59  typedef typename MassFunctionType::LabelType LabelType;
60  typedef typename MassFunctionType::MassType MassType;
61  typedef typename MassFunctionType::LabelSetType LabelSetType;
62  typedef typename MassFunctionType::LabelSetOfSetType LabelSetOfSetType;
63 
65  using Superclass::PushBackInput;
66  virtual void PushBackInput(const MassFunctionType* input);
67 
69  using Superclass::PushFrontInput;
70  virtual void PushFrontInput(const MassFunctionType* input);
71 
73  using Superclass::PopBackInput;
74  void PopBackInput() override;
75 
77  using Superclass::PopFrontInput;
78  void PopFrontInput() override;
79 
81  const MassFunctionType* GetInput(unsigned int idx);
82 
84  MassFunctionType* GetOutput();
85 
86 protected:
89 
92  {
93  }
94 
96  void GenerateData() override;
97 
99  void PrintSelf(std::ostream& os, itk::Indent indent) const override;
100 
101 private:
102  JointMassOfBeliefFilter(const Self&) = delete;
103  void operator=(const Self&) = delete;
104 
106  void CombineMasses(const MassFunctionType* input, MassFunctionType* output);
107 };
108 
109 } // end namespace otb
110 
111 #ifndef OTB_MANUAL_INSTANTIATION
113 #endif
114 
115 #endif
Performs Dempster-Shafer combination of n masses function.
MassFunctionType::MassType MassType
itk::SmartPointer< const Self > ConstPointer
MassFunctionType::LabelSetType LabelSetType
MassFunctionType::LabelType LabelType
MassFunctionType::LabelSetOfSetType LabelSetOfSetType
void operator=(const Self &)=delete
MassFunctionType::Pointer MassFunctionPointerType
JointMassOfBeliefFilter(const Self &)=delete
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.