22 #ifndef otbStreamingHistogramVectorImageFilter_h
23 #define otbStreamingHistogramVectorImageFilter_h
29 #include "itkStatisticsAlgorithm.h"
30 #include "itkNumericTraits.h"
31 #include "itkHistogram.h"
54 template <
class TInputImage>
74 typedef typename TInputImage::SizeType
SizeType;
79 itkStaticConstMacro(InputImageDimension,
unsigned int, TInputImage::ImageDimension);
82 itkStaticConstMacro(ImageDimension,
unsigned int, TInputImage::ImageDimension);
85 typedef typename itk::NumericTraits<InternalPixelType>::RealType
RealType;
97 typedef itk::Statistics::Histogram<HistogramMeasurementRealType, DFContainerType>
HistogramType;
120 itkSetMacro(NoDataFlag,
bool);
125 itkGetMacro(NoDataFlag,
bool);
130 itkBooleanMacro(NoDataFlag);
143 HistogramListType* GetHistogramListOutput();
144 const HistogramListType* GetHistogramListOutput()
const;
160 itkSetMacro(SubSamplingRate,
unsigned int);
163 itkGetMacro(SubSamplingRate,
unsigned int);
169 using Superclass::MakeOutput;
174 void AllocateOutputs()
override;
175 void GenerateOutputInformation()
override;
176 void Synthetize(
void)
override;
177 void Reset(
void)
override;
185 void PrintSelf(std::ostream& os, itk::Indent indent)
const override;
187 void ThreadedGenerateData(
const RegionType& outputRegionForThread, itk::ThreadIdType threadId)
override;
227 template <
class TInputImage>
250 using Superclass::SetInput;
253 this->GetFilter()->SetInput(input);
257 return this->GetFilter()->GetInput();
263 return this->GetFilter()->GetHistogramListOutput();
283 #ifndef OTB_MANUAL_INSTANTIATION
This class is a generic all-purpose wrapping around an std::vector<itk::SmartPointer<ObjectType> >.
itk::SmartPointer< Self > Pointer
This filter link a persistent filter with a StreamingImageVirtualWriter.
Compute the histogram of a large image using streaming.
itk::NumericTraits< InternalPixelType >::RealType RealType
~PersistentHistogramVectorImageFilter() override
InternalPixelType m_NoDataValue
itk::Statistics::DenseFrequencyContainer2 DFContainerType
PersistentHistogramVectorImageFilter Self
itk::ProcessObject::DataObjectPointerArraySizeType DataObjectPointerArraySizeType
PersistentImageFilter< TInputImage, TInputImage > Superclass
PixelType MeasurementVectorType
itk::VariableLengthVector< unsigned int > CountVectorType
TInputImage::RegionType RegionType
unsigned int m_SubSamplingRate
void operator=(const Self &)=delete
MeasurementVectorType m_HistogramMin
ObjectList< HistogramType > HistogramListType
itk::DataObject::Pointer DataObjectPointer
HistogramListType::Pointer HistogramListPointerType
itk::VariableLengthVector< RealType > RealPixelType
itk::Statistics::Histogram< HistogramMeasurementRealType, DFContainerType > HistogramType
TInputImage::Pointer InputImagePointer
std::vector< HistogramListPointerType > ArrayHistogramListType
itk::NumericTraits< InternalPixelType >::RealType HistogramMeasurementRealType
ArrayHistogramListType m_ThreadHistogramList
itk::SmartPointer< const Self > ConstPointer
void SetNumberOfBins(unsigned int i, CountVectorType::ValueType size)
PersistentHistogramVectorImageFilter(const Self &)=delete
MeasurementVectorType m_HistogramMax
TInputImage::PixelType PixelType
itk::SmartPointer< Self > Pointer
TInputImage::InternalPixelType InternalPixelType
TInputImage::IndexType IndexType
void SetNumberOfBins(const CountVectorType &size)
TInputImage::SizeType SizeType
This filter is the base class for all filter persisting data through multiple update....
This class streams the whole input image through the PersistentHistogramVectorImageFilter.
HistogramListType * GetHistogramList()
StreamingHistogramVectorImageFilter()
itk::SmartPointer< const Self > ConstPointer
const InputImageType * GetInput()
Superclass::FilterType InternalFilterType
itk::SmartPointer< Self > Pointer
void SetInput(InputImageType *input)
InternalFilterType::HistogramType HistogramType
PersistentFilterStreamingDecorator< PersistentHistogramVectorImageFilter< TInputImage > > Superclass
StreamingHistogramVectorImageFilter Self
InternalFilterType::HistogramListType HistogramListType
StreamingHistogramVectorImageFilter(const Self &)=delete
void operator=(const Self &)=delete
TInputImage InputImageType
~StreamingHistogramVectorImageFilter() override
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.