13 #ifndef __itkOuterProductVectorImageFilter_h 14 #define __itkOuterProductVectorImageFilter_h 16 #include "itkUnaryFunctorImageFilter.h" 33 template <
class TInput,
class TOutput=TInput>
51 return !( *
this == other );
65 for (
int i = 0; i < N; ++i )
67 for (
int j = 0; j < N; ++j )
80 template <
class TInputImage,
class TOutputImage=TInputImage>
83 UnaryFunctorImageFilter<TInputImage, TOutputImage,
84 Functor::OuterProduct<
85 typename TInputImage::PixelType,
86 typename TOutputImage::PixelType> >
91 typedef UnaryFunctorImageFilter<
92 TInputImage, TOutputImage,
94 typename TInputImage::PixelType,
typename TOutputImage::PixelType> >
Superclass;
116 Superclass::GenerateOutputInformation();
117 typename TInputImage::ConstPointer inputPtr = this->GetInput();
118 typename Superclass::OutputImagePointer outputPtr = this->GetOutput();
119 int N = inputPtr->GetNumberOfComponentsPerPixel();
120 outputPtr->SetNumberOfComponentsPerPixel(N*N);
126 void operator=(
const Self &);
TOutput operator()(const TInput &A)
NDArray is a N-Dimensional array class (row-major, c version)
TOutput::ValueType OutputValueType
virtual ~OuterProductVectorImageFilter()
TInput::ValueType InputValueType
SmartPointer< const Self > ConstPointer
bool operator!=(const OuterProduct &other) const
virtual void GenerateOutputInformation() ITK_OVERRIDE
OuterProductVectorImageFilter()
UnaryFunctorImageFilter< TInputImage, TOutputImage, Functor::OuterProduct< typename TInputImage::PixelType, typename TOutputImage::PixelType > > Superclass
In each vxoel, multiply the input vector by a matrix.
bool operator==(const OuterProduct &other) const
utl::NDArray< double, 1 > VectorType
OuterProductVectorImageFilter Self
SmartPointer< Self > Pointer