DMRITool
v0.1.1-139-g860d86b4
Diffusion MRI Tool
|
#include <utlMatrix.h>
Base class for utl::NDArray.
Definition at line 22 of file utlMatrix.h.
Classes | |
class | ConstReverseIterator |
class | ReverseIterator |
Public Types | |
enum | { Dimension = Dim } |
typedef const ValueType * | ConstIterator |
typedef const ValueType * | ConstPointer |
typedef const ValueType & | ConstReference |
typedef ValueType * | Iterator |
typedef ValueType * | Pointer |
typedef ValueType & | Reference |
typedef utl::remove_complex_t< T > | ScalarValueType |
typedef NDArrayBase | Self |
typedef Superclass::ShapeType | ShapeType |
typedef Superclass::SizeType | SizeType |
typedef Expr< NDArrayBase< T, Dim >, T > | Superclass |
typedef T | ValueType |
Public Types inherited from utl::Expr< NDArrayBase< T, Dim >, T > | |
typedef SizeType const * | ShapeType |
typedef unsigned int | SizeType |
typedef T | ValueType |
Public Member Functions | |
__Array_Saver_Scalar (+=) __Array_Saver_Scalar(- | |
T | AbsoluteMaxValue () const |
T | AbsoluteMinValue () const |
template<typename FuncT > | |
void | Apply (const FuncT &func, NDArrayBase< T, Dim > &vec) const |
void | Apply (T(*f)(T), NDArrayBase< T, Dim > &vec) const |
void | Apply (T(*f)(T const &), NDArrayBase< T, Dim > &vec) const |
unsigned | ArgAbsoluteMax () const |
unsigned | ArgAbsoluteMin () const |
unsigned | ArgMax () const |
unsigned | ArgMin () const |
Reference | Back () |
ConstReference | Back () const |
Iterator | Begin () |
ConstIterator | Begin () const |
ConstIterator | cBegin () const |
ConstIterator | cEnd () const |
void | Clear () |
void | CopyData (T *const data, const ShapeType &shape) |
NDArrayBase< T, Dim > & | CopyIn (T const *ptr, const int size, const int start=0) |
void | CopyOut (T *ptr, const int size, const int start=0) const |
ConstReverseIterator | crBegin () const |
ConstReverseIterator | crEnd () const |
NDArrayBase< T, Dim > & | ElementAbsolute (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementAbsolute (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementAdd (T *const vec, T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementAxpby (T *const vec, const T alpha, const T beta) |
NDArrayBase< T, Dim > & | ElementCos (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementCos (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementDivide (T *const vec, T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementExp (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementExp (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementInverse (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementInverse (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementMultiply (T *const vec, T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementSin (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementSin (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementSqrt (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementSqrt (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementSquare (T *outVec=NULL) |
NDArrayBase< T, Dim > & | ElementSquare (NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | ElementSubstract (T *const vec, T *outVec=NULL) |
Iterator | End () |
ConstIterator | End () const |
T | Eval (int i) const |
void | Fill (const T &value) |
NDArrayBase< T, Dim > & | Flip () |
T * | GetData () |
const T * | GetData () const |
ConstReference | GetElement (unsigned short index) const |
NDArrayBase< T, Dim > | GetElementAbsolute () const |
NDArrayBase< T, Dim > | GetElementCos () const |
NDArrayBase< T, Dim > | GetElementExp () const |
NDArrayBase< T, Dim > | GetElementInverse () const |
NDArrayBase< T, Dim > | GetElementSin () const |
NDArrayBase< T, Dim > | GetElementSqrt () const |
NDArrayBase< T, Dim > | GetElementSquare () const |
void | GetIndex (const SizeType offset, SizeType index[Dimension]) const |
double | GetInfNorm () const |
bool | GetIsShared () const |
T | GetMean () const |
T | GetMedian () const |
SizeType | GetOffset (const ShapeType &shapeIndex) const |
const SizeType * | GetOffSetTable () const |
double | GetOneNorm () const |
NDArray< T, SubDimension > | GetRefSubArray (const int i) const |
NDArray< T, Dim > | GetRefSubArray (const int istart, const int iend) const |
double | GetRootMeanSquares () const |
const ShapeType | GetShape () const |
SizeType | GetSize () const |
double | GetSquaredTwoNorm () const |
T | GetSum () const |
double | GetTwoNorm () const |
int | GetZeroNorm (const double eps=1e-10) const |
void | HardThreshold (const double threshold) |
ValueType | InnerProduct (const NDArrayBase< T, Dim > &vec) const |
bool | IsEmpty () const |
bool | IsEqual (const NDArrayBase< T, Dim > &r, const double eps) const |
template<typename EType > | |
bool | IsSameShape (const EType &src) const |
bool | IsSameShape (const ShapeType &shape) const |
bool | IsSameSize (const ShapeType &shape) const |
bool | IsSameValues (const NDArrayBase< T, Dim > &r, const double eps) const |
bool | IsZero () const |
T | MaxValue () const |
T | MinValue () const |
NDArrayBase () | |
NDArrayBase (const ShapeType &shape) | |
NDArrayBase (const NDArrayBase< T, Dim > &vec) | |
NDArrayBase (NDArrayBase< T, Dim > &&vec) | |
template<typename EType > | |
NDArrayBase (const Expr< EType, typename EType::ValueType > &expr) | |
NDArrayBase (const T *vec, const ShapeType &shape) | |
NDArrayBase (const ShapeType &shape, const T r) | |
template<typename TValue > | |
NDArrayBase (const NDArrayBase< TValue, Dim > &r) | |
int | NNZ (const double eps=1e-10) const |
NDArrayBase< T, Dim > & | operator saver (const T val) |
bool | operator!= (const NDArrayBase< T, Dim > &r) const |
template<typename EType > | |
NDArrayBase< T, Dim > & | operator%= (const Expr< EType, typename EType::ValueType > &src) |
NDArrayBase< T, Dim > & | operator%= (const NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | operator%= (const T val) |
Reference | operator() (const ShapeType &shape) |
ConstReference | operator() (const ShapeType &shape) const |
template<typename EType > | |
NDArrayBase< T, Dim > & | operator+= (const Expr< EType, typename EType::ValueType > &src) |
NDArrayBase< T, Dim > & | operator+= (const NDArrayBase< T, Dim > &vec) |
template<typename EType > | |
NDArrayBase< T, Dim > & | operator-= (const Expr< EType, typename EType::ValueType > &src) |
NDArrayBase< T, Dim > & | operator-= (const NDArrayBase< T, Dim > &vec) |
template<typename EType > | |
NDArrayBase< T, Dim > & | operator/= (const Expr< EType, typename EType::ValueType > &src) |
NDArrayBase< T, Dim > & | operator/= (const NDArrayBase< T, Dim > &vec) |
NDArrayBase< T, Dim > & | operator/= (const T val) |
template<typename EType > | |
NDArrayBase< T, Dim > & | operator= (const Expr< EType, typename EType::ValueType > &src) |
Dim & | operator= (const NDArrayBase< T, Dim > &r) |
NDArrayBase< T, Dim > & | operator= (NDArrayBase< T, Dim > &&r) |
template<typename TValueType > | |
NDArrayBase< T, Dim > & | operator= (const NDArrayBase< TValueType, Dim > &r) |
NDArrayBase< T, Dim > & | operator= (const std::initializer_list< T > &r) |
NDArrayBase< T, Dim > & | operator= (const std::vector< T > &r) |
NDArrayBase< T, Dim > & | operator= (const T r) |
bool | operator== (const NDArrayBase< T, Dim > &r) const |
Reference | operator[] (short index) |
ConstReference | operator[] (short index) const |
Reference | operator[] (unsigned short index) |
ConstReference | operator[] (unsigned short index) const |
Reference | operator[] (int index) |
ConstReference | operator[] (int index) const |
Reference | operator[] (unsigned int index) |
ConstReference | operator[] (unsigned int index) const |
Reference | operator[] (long index) |
ConstReference | operator[] (long index) const |
Reference | operator[] (unsigned long index) |
ConstReference | operator[] (unsigned long index) const |
Reference | operator[] (long long index) |
ConstReference | operator[] (long long index) const |
Reference | operator[] (unsigned long long index) |
ConstReference | operator[] (unsigned long long index) const |
void | Print (std::ostream &os, const char *separate=" ") const |
void | PrintInfo (std::ostream &os, const char *separate=" ") const |
void | PrintWithIndex (std::ostream &os, const char *separate=" ") const |
ReverseIterator | rBegin () |
ConstReverseIterator | rBegin () const |
ReverseIterator | rEnd () |
ConstReverseIterator | rEnd () const |
NDArrayBase< T, Dim > & | ReShape (const ShapeType &shape) |
bool | ReSize (const ShapeType &shape) |
NDArrayBase< T, Dim > & | Scale (const T a) |
void | SetData (T *const data, const ShapeType &shape) |
void | SetElement (unsigned short index, ConstReference value) |
SizeType | Size () const |
void | SoftThreshold (const double threshold) |
void | Swap (NDArrayBase< T, Dim > &vec) |
~NDArrayBase () | |
Public Member Functions inherited from utl::Expr< NDArrayBase< T, Dim >, T > | |
const NDArrayBase< T, Dim > & | ConstRef (void) const |
const ShapeType | GetShape () const |
NDArrayBase< T, Dim > & | Ref (void) |
Static Public Member Functions | |
static constexpr SizeType | GetDimension () |
Static Public Member Functions inherited from utl::Expr< NDArrayBase< T, Dim >, T > | |
static SizeType | GetDimension () |
Static Public Attributes | |
static constexpr SizeType | SubDimension = Dim>1?Dim-1:1 |
Protected Member Functions | |
void | ClearData () |
void | ClearShape () |
void | ComputeOffSetTable () |
Protected Attributes | |
T * | m_Data |
bool | m_IsShared |
SizeType | m_OffSetTable [Dimension] |
SizeType | m_Shape [Dimension] |
typedef const ValueType* utl::NDArrayBase< T, Dim >::ConstIterator |
A const iterator through the array.
Definition at line 171 of file utlNDArray.h.
typedef const ValueType* utl::NDArrayBase< T, Dim >::ConstPointer |
Definition at line 175 of file utlNDArray.h.
typedef const ValueType& utl::NDArrayBase< T, Dim >::ConstReference |
Definition at line 179 of file utlNDArray.h.
typedef ValueType* utl::NDArrayBase< T, Dim >::Iterator |
An iterator through the array.
Definition at line 168 of file utlNDArray.h.
typedef ValueType* utl::NDArrayBase< T, Dim >::Pointer |
A pointer to the ValueType.
Definition at line 174 of file utlNDArray.h.
typedef ValueType& utl::NDArrayBase< T, Dim >::Reference |
A reference to the ValueType.
Definition at line 178 of file utlNDArray.h.
typedef utl::remove_complex_t<T> utl::NDArrayBase< T, Dim >::ScalarValueType |
Definition at line 165 of file utlNDArray.h.
typedef NDArrayBase utl::NDArrayBase< T, Dim >::Self |
The element type stored at each location in the NDArrayBase.
Definition at line 146 of file utlNDArray.h.
typedef Superclass::ShapeType utl::NDArrayBase< T, Dim >::ShapeType |
Definition at line 155 of file utlNDArray.h.
typedef Superclass::SizeType utl::NDArrayBase< T, Dim >::SizeType |
Definition at line 154 of file utlNDArray.h.
typedef Expr<NDArrayBase<T, Dim>, T > utl::NDArrayBase< T, Dim >::Superclass |
Definition at line 152 of file utlNDArray.h.
typedef T utl::NDArrayBase< T, Dim >::ValueType |
Definition at line 164 of file utlNDArray.h.
anonymous enum |
Enumerator | |
---|---|
Dimension |
Definition at line 160 of file utlNDArray.h.
|
inline |
Default constructor uses compiler's default initialization of memory. For efficiency, no initialization to zero is done.
Definition at line 229 of file utlNDArray.h.
|
inlineexplicit |
Definition at line 235 of file utlNDArray.h.
|
inline |
Definition at line 240 of file utlNDArray.h.
|
inline |
Definition at line 246 of file utlNDArray.h.
|
inline |
Definition at line 255 of file utlNDArray.h.
|
inline |
Constructor assumes input points to array of correct size. Values are copied individually instead of with a binary copy. This allows the T's assignment operator to be executed.
Definition at line 267 of file utlNDArray.h.
|
inline |
Constructor to initialize entire array to one value.
Definition at line 276 of file utlNDArray.h.
|
inline |
Definition at line 283 of file utlNDArray.h.
|
inline |
This destructor is not virtual for performance reasons. However, this means that subclasses cannot allocate memory.
The destructor is PURPOSELY NOT DEFINED, in order to prevent inefficient byte alignment of arrays of this object.
For a full discussion, see http://www.itk.org/mailman/private/insight-developers/2008-June/010480.html
Definition at line 302 of file utlNDArray.h.
utl::NDArrayBase< T, Dim >::__Array_Saver_Scalar | ( | + | ) |
|
inline |
Definition at line 989 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetTwoNorm().
|
inline |
Definition at line 999 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::AbsoluteMinValue().
|
inline |
Applies function to elements
Definition at line 945 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Apply().
|
inline |
Definition at line 951 of file utlNDArray.h.
|
inline |
Definition at line 957 of file utlNDArray.h.
|
inline |
Definition at line 984 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ArgAbsoluteMin().
|
inline |
Definition at line 995 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetInfNorm().
|
inline |
Definition at line 964 of file utlNDArray.h.
|
inline |
Definition at line 974 of file utlNDArray.h.
|
inline |
Definition at line 576 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Begin().
|
inline |
Definition at line 577 of file utlNDArray.h.
|
inline |
Get an Iterator for the beginning of the NDArrayBase.
Definition at line 582 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ArgAbsoluteMax(), utl::NDArrayBase< T, 4 >::ArgMin(), utl::NDArrayBase< T, 4 >::Begin(), utl::NDArrayBase< T, 4 >::CopyIn(), utl::NDArrayBase< T, 4 >::IsEqual(), utl::NDArrayBase< T, 4 >::IsSameValues(), utl::NDArrayBase< T, 4 >::MaxValue(), utl::NDArrayBase< T, 4 >::MinValue(), itk::Functor::SHCoefficientsPower< TInput, TOutput >::operator()(), utl::NDArrayBase< T, 4 >::operator=(), utl::NDArrayBase< T, 4 >::operator==(), and utl::PrintUtlVector().
|
inline |
Get a ConstIterator for the beginning of the NDArrayBase.
Definition at line 590 of file utlNDArray.h.
|
inline |
Definition at line 594 of file utlNDArray.h.
|
inline |
Definition at line 614 of file utlNDArray.h.
|
inline |
Definition at line 305 of file utlNDArray.h.
Referenced by utl::NDArray< double, 2 >::operator=(), utl::NDArray< T, 4 >::operator=(), utl::NDArray< T, 2 >::operator=(), utl::NDArray< T, 1 >::operator=(), utl::NDArrayBase< T, 4 >::operator=(), utl::PointsContainerToUtlMatrix(), utl::NDArrayBase< T, 4 >::SetData(), and utl::NDArrayBase< T, 4 >::~NDArrayBase().
|
inlineprotected |
Definition at line 1176 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Clear().
|
inlineprotected |
Definition at line 1184 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Clear().
|
inlineprotected |
Definition at line 1190 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ComputeOffSetTable(), and utl::NDArray< T, 2 >::TransposeInplace().
|
inline |
copy m_Data from data
Definition at line 689 of file utlNDArray.h.
Referenced by utl::NDArray< T, 1 >::CopyData(), and utl::NDArray< T, 2 >::CopyData().
|
inline |
Set elements from ptr (starting with m_Data + start )
Definition at line 928 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::CopyIn().
|
inline |
Set elements to ptr (starting with m_Data + start )
Definition at line 936 of file utlNDArray.h.
|
inline |
Definition at line 634 of file utlNDArray.h.
|
inline |
Definition at line 654 of file utlNDArray.h.
|
inline |
Definition at line 841 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementInverse(), utl::NDArrayBase< T, 4 >::GetElementAbsolute(), utl::NDArrayBase< T, 4 >::GetElementInverse(), and itk::SphericalPolarFourierImageFilter< TInputImage, TOutputImage >::ThreadedGenerateData().
|
inline |
Definition at line 843 of file utlNDArray.h.
|
inline |
y = a+x, make sure vec and outVec have valid length. when outVec is null, the result is stored in *this.
Definition at line 808 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator-=().
|
inline |
m_Data[i] = alpha*vec[i] + beta*m_Data[i]
Definition at line 870 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Scale().
|
inline |
Definition at line 827 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSin(), utl::NDArrayBase< T, 4 >::GetElementCos(), and utl::NDArrayBase< T, 4 >::GetElementSin().
|
inline |
Definition at line 829 of file utlNDArray.h.
|
inline |
Definition at line 817 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator%=().
|
inline |
Definition at line 820 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementCos(), utl::NDArrayBase< T, 4 >::GetElementCos(), and utl::NDArrayBase< T, 4 >::GetElementExp().
|
inline |
Definition at line 822 of file utlNDArray.h.
|
inline |
Definition at line 848 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSqrt(), utl::NDArrayBase< T, 4 >::GetElementInverse(), and utl::NDArrayBase< T, 4 >::GetElementSqrt().
|
inline |
Definition at line 850 of file utlNDArray.h.
|
inline |
Definition at line 814 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator/=().
|
inline |
Definition at line 834 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementAbsolute(), utl::NDArrayBase< T, 4 >::GetElementAbsolute(), and utl::NDArrayBase< T, 4 >::GetElementSin().
|
inline |
Definition at line 836 of file utlNDArray.h.
|
inline |
Definition at line 855 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSquare(), utl::NDArrayBase< T, 4 >::GetElementSqrt(), and utl::NDArrayBase< T, 4 >::GetElementSquare().
|
inline |
Definition at line 857 of file utlNDArray.h.
|
inline |
Definition at line 862 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementAxpby(), utl::NDArrayBase< T, 4 >::GetElementSquare(), and utl::NDArrayBase< T, 4 >::Scale().
|
inline |
Definition at line 864 of file utlNDArray.h.
|
inline |
Definition at line 811 of file utlNDArray.h.
|
inline |
Get an Iterator for the end of the NDArrayBase.
Definition at line 602 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ArgAbsoluteMax(), utl::NDArrayBase< T, 4 >::ArgMin(), utl::NDArrayBase< T, 4 >::CopyIn(), utl::NDArrayBase< T, 4 >::IsEqual(), utl::NDArrayBase< T, 4 >::IsSameValues(), utl::NDArrayBase< T, 4 >::MaxValue(), utl::NDArrayBase< T, 4 >::MinValue(), itk::Functor::SHCoefficientsPower< TInput, TOutput >::operator()(), utl::NDArrayBase< T, 4 >::operator==(), and utl::PrintUtlVector().
|
inline |
Get a ConstIterator for the end of the NDArrayBase.
Definition at line 610 of file utlNDArray.h.
|
inline |
Definition at line 313 of file utlNDArray.h.
|
inline |
Fill all elements of the array with the given value.
Definition at line 922 of file utlNDArray.h.
Referenced by utl::Eye(), utl::NDArray< T, 1 >::GetDiagonalMatrix(), utl::MeanDirector(), utl::NDArray< T, 2 >::NDArray(), utl::NDArray< T, 4 >::NDArray(), utl::NDArray< T, 1 >::NDArray(), utl::NDArrayBase< T, 4 >::NDArrayBase(), utl::Ones(), utl::NDArrayBase< T, 4 >::operator==(), spams::SpMatrixToUtlMatrix(), and itk::GeneralizedHighOrderTensorImageFilter< TInputImage, TOutputImage >::ThreadedGenerateData().
|
inline |
Definition at line 1070 of file utlNDArray.h.
|
inline |
Return a pointer to the data.
Definition at line 666 of file utlNDArray.h.
Referenced by itk::L1RegularizedLeastSquaresFISTASolver< TPrecision >::EvaluateCostFunction(), utl::gesdd_UtlMatrix(), utl::gesvd_UtlMatrix(), utl::NDArray< T, 2 >::GetColumn(), utl::NDArrayBase< T, 4 >::GetData(), utl::NDArray< T, 2 >::GetRow(), utl::InnerProduct(), utl::InverseSymmericMatrix(), itk::L1RegularizedLeastSquaresFISTASolver< TPrecision >::Iterate(), spams::MatrixToUtlMatrix(), utl::NDArray< T, 2 >::SetColumn(), utl::NDArray< T, 2 >::SetRow(), utl::syev_UtlMatrix(), utl::syevd_UtlMatrix(), spams::UtlMatrixToMatrix(), utl::UtlMatrixToVnlMatrix(), spams::UtlVectorToVector(), utl::UtlVectorToVnlVector(), and spams::VectorToUtlVector().
|
inline |
Definition at line 671 of file utlNDArray.h.
|
inlinestatic |
Definition at line 335 of file utlNDArray.h.
|
inline |
Definition at line 662 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetData().
|
inline |
Definition at line 845 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementInverse().
|
inline |
Definition at line 831 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSin().
|
inline |
Definition at line 824 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementCos().
|
inline |
Definition at line 852 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSqrt().
|
inline |
Definition at line 838 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementAbsolute().
|
inline |
Definition at line 859 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementSquare().
|
inline |
Definition at line 866 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::ElementAxpby().
|
inline |
Definition at line 347 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::PrintWithIndex().
|
inline |
Return largest absolute element value
Definition at line 1006 of file utlNDArray.h.
Referenced by utl::NDArray< T, 2 >::GetArrayInfNorm(), and utl::NDArrayBase< T, 4 >::GetInfNorm().
|
inline |
Definition at line 363 of file utlNDArray.h.
|
inline |
get mean
Definition at line 1049 of file utlNDArray.h.
|
inline |
Definition at line 1054 of file utlNDArray.h.
|
inline |
Definition at line 338 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Back(), and utl::NDArray< T, 4 >::GetRefSubMatrix().
|
inline |
Definition at line 358 of file utlNDArray.h.
|
inline |
Return sum of absolute values of elements
Definition at line 1028 of file utlNDArray.h.
Referenced by utl::NDArray< T, 2 >::GetArrayOneNorm().
|
inline |
Definition at line 732 of file utlNDArray.h.
|
inline |
Definition at line 750 of file utlNDArray.h.
|
inline |
Definition at line 1022 of file utlNDArray.h.
|
inline |
Definition at line 330 of file utlNDArray.h.
Referenced by utl::ComplexCombine(), utl::Convert4To2Tensor(), utl::InnerProduct(), utl::NDArrayBase< T, 4 >::operator=(), and utl::OuterProduct().
|
inline |
Definition at line 325 of file utlNDArray.h.
|
inline |
Definition at line 1017 of file utlNDArray.h.
Referenced by utl::ComputeOrientationalOrderFromSHCoefficients(), and itk::SpamsWeightedLassoSolver< TPrecision >::EvaluateCostFunctionInColumn().
|
inline |
get sum
Definition at line 1040 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetSum().
|
inline |
sqrt of sum of squares of its elements
Definition at line 1013 of file utlNDArray.h.
Referenced by utl::DifferenceOfDirection(), utl::NDArray< T, 2 >::GetArrayTwoNorm(), utl::GetMeanOfRotationMatrix(), utl::NDArrayBase< T, 4 >::GetOneNorm(), utl::NDArrayBase< T, 4 >::GetRootMeanSquares(), utl::NormalizeGrad(), and utl::RotationMatrixToAxisAngle().
|
inline |
number of non-zero values
Definition at line 1034 of file utlNDArray.h.
Referenced by utl::NDArray< T, 2 >::GetArrayZeroNorm().
|
inline |
Definition at line 1114 of file utlNDArray.h.
|
inline |
Definition at line 1123 of file utlNDArray.h.
Referenced by itk::L2RegularizedLeastSquaresSolver< TPrecision >::EvaluateCostFunction().
|
inline |
Definition at line 1086 of file utlNDArray.h.
|
inline |
Definition at line 502 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::IsEqual(), itk::Functor::RotateSHCoefficients< TInput, TOutput >::operator==(), and itk::RotateSHCoefficientsImageFilter< TInputImage, TOutputImage >::SetRotationMatrix().
|
inline |
return true if src is a scalar value (dimension of src is 0) or have the same shape.
Definition at line 771 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::IsEqual(), utl::IsSameShape(), utl::NDArrayBase< T, 4 >::operator-=(), and utl::NDArrayBase< T, 4 >::operator==().
|
inline |
Definition at line 789 of file utlNDArray.h.
|
inline |
Definition at line 801 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::IsSameValues().
|
inline |
Definition at line 521 of file utlNDArray.h.
|
inline |
Definition at line 1077 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::IsZero().
|
inline |
Definition at line 969 of file utlNDArray.h.
|
inline |
Definition at line 979 of file utlNDArray.h.
|
inline |
number of non-zero values
Definition at line 1090 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetSum(), and utl::NDArrayBase< T, 4 >::NNZ().
|
inline |
Definition at line 387 of file utlNDArray.h.
|
inline |
Definition at line 499 of file utlNDArray.h.
|
inline |
use %= for elementwse *=
Definition at line 386 of file utlNDArray.h.
|
inline |
Definition at line 895 of file utlNDArray.h.
|
inline |
Definition at line 908 of file utlNDArray.h.
|
inline |
Definition at line 573 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Back().
|
inline |
Definition at line 574 of file utlNDArray.h.
|
inline |
Definition at line 385 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator+=().
|
inline |
Definition at line 880 of file utlNDArray.h.
|
inline |
Definition at line 385 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator-=().
|
inline |
Definition at line 887 of file utlNDArray.h.
|
inline |
Definition at line 386 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator/=().
|
inline |
Definition at line 901 of file utlNDArray.h.
|
inline |
Definition at line 913 of file utlNDArray.h.
|
inline |
Definition at line 385 of file utlNDArray.h.
Referenced by utl::NDArray< double, 2 >::operator=(), utl::NDArray< T, 4 >::operator=(), utl::NDArray< T, 2 >::operator=(), and utl::NDArray< T, 1 >::operator=().
|
inline |
Definition at line 401 of file utlNDArray.h.
|
inline |
Definition at line 412 of file utlNDArray.h.
|
inline |
Operator= defined for a variety of types.
Definition at line 424 of file utlNDArray.h.
|
inline |
Definition at line 434 of file utlNDArray.h.
|
inline |
Assignment operator assumes input points to array of correct size. Values are copied individually instead of with a binary copy. This allows the T's assignment operator to be executed.
If Dimension==1, then ReSize is used. If Dimension>1, the sizes of the array and the input std::vector should be the same.
Definition at line 458 of file utlNDArray.h.
|
inline |
Definition at line 474 of file utlNDArray.h.
|
inline |
Operators == and != are used to compare whether two arrays are equal. Note that arrays are equal when the number of components (size) is the same, and each component value is equal.
Definition at line 480 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::IsEqual(), and utl::NDArrayBase< T, 4 >::operator==().
|
inline |
Allow the NDArrayBase to be indexed normally. No bounds checking is done. The separate versions are a work-around for an integer conversion bug in Visual C++.
Definition at line 544 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::operator()(), and utl::NDArrayBase< T, 4 >::operator[]().
|
inline |
Definition at line 545 of file utlNDArray.h.
|
inline |
Definition at line 546 of file utlNDArray.h.
|
inline |
Definition at line 547 of file utlNDArray.h.
|
inline |
Definition at line 548 of file utlNDArray.h.
|
inline |
Definition at line 549 of file utlNDArray.h.
|
inline |
Definition at line 557 of file utlNDArray.h.
|
inline |
Definition at line 558 of file utlNDArray.h.
|
inline |
Definition at line 564 of file utlNDArray.h.
|
inline |
Definition at line 565 of file utlNDArray.h.
|
inline |
Definition at line 566 of file utlNDArray.h.
|
inline |
Definition at line 567 of file utlNDArray.h.
|
inline |
Definition at line 568 of file utlNDArray.h.
|
inline |
Definition at line 569 of file utlNDArray.h.
|
inline |
Definition at line 570 of file utlNDArray.h.
|
inline |
Definition at line 571 of file utlNDArray.h.
|
inline |
Definition at line 1135 of file utlNDArray.h.
Referenced by utl::operator<<(), utl::PrintUtlNDArray(), and itk::SphericalPolarFourierImageFilter< TInputImage, TOutputImage >::ThreadedGenerateData().
|
inline |
Definition at line 1127 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::PrintInfo(), and utl::NDArrayBase< T, 4 >::PrintWithIndex().
|
inline |
Definition at line 1142 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::PrintWithIndex().
|
inline |
Get a begin ReverseIterator.
Definition at line 622 of file utlNDArray.h.
|
inline |
Get a begin ConstReverseIterator.
Definition at line 630 of file utlNDArray.h.
|
inline |
Get an end ReverseIterator.
Definition at line 642 of file utlNDArray.h.
|
inline |
Get an end ConstReverseIterator.
Definition at line 650 of file utlNDArray.h.
|
inline |
change the shape, no data allocation (same size)
Definition at line 722 of file utlNDArray.h.
|
inline |
If the current size is different from the size in shape, then data allocation happens. Otherwise, just change the shape using ReShape.
Definition at line 697 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Apply(), utl::NDArrayBase< T, 4 >::ArgMax(), utl::NDArray< T, 1 >::NDArray(), utl::NDArrayBase< T, 4 >::operator=(), utl::PointsContainerToUtlMatrix(), utl::NDArray< T, 2 >::ReSize(), utl::NDArray< T, 4 >::ReSize(), and utl::NDArray< T, 1 >::ReSize().
|
inline |
Definition at line 873 of file utlNDArray.h.
Referenced by utl::NDArray< T, 1 >::GetRotateAxis(), utl::NDArray< T, 2 >::GetTranspose(), utl::NDArrayBase< T, 4 >::operator/=(), and utl::NDArrayBase< T, 4 >::Scale().
|
inline |
set m_Data from data, the ownership is in data.
Definition at line 677 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetRefSubArray(), utl::NDArray< T, 1 >::SetData(), utl::NDArray< T, 2 >::SetData(), and utl::NDArrayBase< T, 4 >::SetData().
|
inline |
Set/Get element methods are more convenient in wrapping languages
Definition at line 660 of file utlNDArray.h.
|
inline |
Get the size of the NDArrayBase.
Definition at line 321 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::AbsoluteMaxValue(), utl::NDArrayBase< T, 4 >::AbsoluteMinValue(), utl::NDArrayBase< T, 4 >::Apply(), utl::NDArrayBase< T, 4 >::ArgMax(), utl::NDArrayBase< T, 4 >::Begin(), utl::ComputeOrientationalOrderFromSHCoefficients(), utl::ConnectUtlVector(), utl::Convert1To2Tensor(), utl::DotProduct(), utl::NDArray< T, 4 >::EigenDecompositionWithMinorSymmetry(), utl::NDArrayBase< T, 4 >::ElementAbsolute(), utl::NDArrayBase< T, 4 >::ElementAdd(), utl::NDArrayBase< T, 4 >::ElementCos(), utl::NDArrayBase< T, 4 >::ElementDivide(), utl::NDArrayBase< T, 4 >::ElementExp(), utl::NDArrayBase< T, 4 >::ElementInverse(), utl::NDArrayBase< T, 4 >::ElementMultiply(), utl::NDArrayBase< T, 4 >::ElementSin(), utl::NDArrayBase< T, 4 >::ElementSqrt(), utl::NDArrayBase< T, 4 >::ElementSquare(), itk::L2RegularizedLeastSquaresSolver< TPrecision >::EvaluateCostFunction(), itk::L1RegularizedLeastSquaresFISTASolver< TPrecision >::EvaluateCostFunction(), itk::SpamsWeightedLassoSolver< TPrecision >::EvaluateCostFunction(), itk::SpamsWeightedLassoSolver< TPrecision >::EvaluateCostFunctionInColumn(), utl::NDArray< T, 2 >::ExpM(), utl::NDArray< T, 1 >::GetDiagonalMatrix(), utl::NDArrayBase< T, 4 >::GetElementExp(), utl::NDArrayBase< T, 4 >::GetElementSquare(), utl::GetMeanOfRotationMatrix(), utl::GetMXArrayFromUtlVector(), utl::NDArrayBase< T, 4 >::GetOneNorm(), utl::NDArray< T, 1 >::GetRotateAxis(), itk::SHCoefficientsRotation< T >::GetRotatedSHCoefficients(), utl::NDArrayBase< T, 4 >::GetSquaredTwoNorm(), utl::GetUtlVectorFromMXArray(), utl::NDArrayBase< T, 4 >::GetZeroNorm(), utl::NDArrayBase< T, 4 >::HardThreshold(), itk::SolverBase< TPrecision >::Initialize(), itk::L1RegularizedLeastSquaresFISTASolver< TPrecision >::Initialize(), utl::InnerProduct(), utl::NDArrayBase< T, 4 >::IsZero(), itk::L1RegularizedLeastSquaresFISTASolver< TPrecision >::Iterate(), utl::NDArray< T, 2 >::LogM(), utl::MeanDirector(), utl::NDArray< T, 4 >::NDArray(), utl::NDArray< T, 2 >::NDArray(), utl::NDArray< T, 1 >::NDArray(), utl::NDArrayBase< T, 4 >::NDArrayBase(), utl::NDArrayBase< T, 4 >::NNZ(), utl::NormalizeGrad(), utl::NDArrayBase< T, 4 >::operator%=(), utl::operator*(), utl::NDArrayBase< T, 4 >::operator+=(), utl::NDArrayBase< T, 4 >::operator-=(), utl::NDArrayBase< T, 4 >::operator/=(), utl::OuterProduct(), utl::PInverseMatrix(), utl::NDArrayBase< T, 4 >::PrintWithIndex(), utl::NDArrayBase< T, 4 >::Scale(), utl::NDArray< T, 2 >::SetColumn(), utl::NDArray< T, 2 >::SetDiagonal(), utl::NDArray< T, 2 >::SetRow(), utl::NDArrayBase< T, 4 >::SoftThreshold(), itk::SphericalPolarFourierImageFilter< TInputImage, TOutputImage >::ThreadedGenerateData(), utl::UtlVectorToStdVector(), utl::UtlVectorToVariableLengthVector(), spams::UtlVectorToVector(), utl::UtlVectorToVnlVector(), and spams::VectorToUtlVector().
|
inline |
Definition at line 1101 of file utlNDArray.h.
|
inline |
Definition at line 1062 of file utlNDArray.h.
Referenced by utl::NDArray< double, 2 >::operator=(), utl::NDArray< T, 4 >::operator=(), utl::NDArray< T, 2 >::operator=(), utl::NDArray< T, 1 >::operator=(), and utl::NDArrayBase< T, 4 >::operator=().
|
protected |
Internal C array representation.
Definition at line 1174 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::AbsoluteMaxValue(), utl::NDArrayBase< T, 4 >::AbsoluteMinValue(), utl::NDArrayBase< T, 4 >::Apply(), utl::NDArrayBase< T, 4 >::ArgAbsoluteMin(), utl::NDArrayBase< T, 4 >::ArgMax(), utl::NDArrayBase< T, 4 >::Back(), utl::NDArrayBase< T, 4 >::Begin(), utl::NDArrayBase< T, 4 >::Clear(), utl::NDArrayBase< T, 4 >::ClearShape(), utl::NDArray< T, 2 >::Determinant(), utl::NDArrayBase< T, 4 >::ElementAbsolute(), utl::NDArrayBase< T, 4 >::ElementAxpby(), utl::NDArrayBase< T, 4 >::ElementCos(), utl::NDArrayBase< T, 4 >::ElementDivide(), utl::NDArrayBase< T, 4 >::ElementExp(), utl::NDArrayBase< T, 4 >::ElementInverse(), utl::NDArrayBase< T, 4 >::ElementMultiply(), utl::NDArrayBase< T, 4 >::ElementSin(), utl::NDArrayBase< T, 4 >::ElementSqrt(), utl::NDArrayBase< T, 4 >::ElementSquare(), utl::NDArrayBase< T, 4 >::Eval(), utl::NDArray< T, 2 >::GetColumn(), utl::NDArrayBase< T, 4 >::GetData(), utl::NDArrayBase< T, 4 >::GetElementExp(), utl::NDArrayBase< T, 4 >::GetElementSquare(), utl::NDArray< T, 2 >::GetInfNorm(), utl::NDArrayBase< T, 4 >::GetInfNorm(), utl::NDArray< T, 2 >::GetOneNorm(), utl::NDArrayBase< T, 4 >::GetRefSubArray(), utl::NDArray< T, 4 >::GetRefSubMatrix(), utl::NDArray< T, 2 >::GetRow(), utl::NDArrayBase< T, 4 >::GetSquaredTwoNorm(), utl::NDArray< T, 1 >::GetSubVector(), utl::NDArray< T, 2 >::GetTranspose(), utl::NDArrayBase< T, 4 >::GetZeroNorm(), utl::NDArrayBase< T, 4 >::InnerProduct(), utl::NDArrayBase< T, 4 >::IsEqual(), utl::NDArrayBase< T, 4 >::IsSameValues(), utl::NDArrayBase< T, 4 >::IsZero(), utl::NDArray< T, 4 >::NDArray(), utl::NDArray< T, 2 >::NDArray(), utl::NDArray< T, 1 >::NDArray(), utl::NDArrayBase< T, 4 >::NDArrayBase(), utl::NDArrayBase< T, 4 >::operator%=(), utl::NDArray< T, 4 >::operator()(), utl::NDArray< T, 2 >::operator()(), utl::NDArray< T, 1 >::operator()(), utl::NDArrayBase< T, 4 >::operator()(), utl::NDArrayBase< T, 4 >::operator+=(), utl::NDArrayBase< T, 4 >::operator-=(), utl::NDArrayBase< T, 4 >::operator/=(), utl::NDArrayBase< T, 4 >::operator==(), utl::NDArrayBase< T, 4 >::operator[](), utl::NDArrayBase< T, 4 >::PrintWithIndex(), utl::NDArrayBase< T, 4 >::Scale(), utl::NDArray< T, 2 >::SetColumn(), utl::NDArrayBase< T, 4 >::SetData(), utl::NDArray< T, 2 >::SetRow(), utl::NDArray< T, 1 >::SetSubVector(), utl::NDArrayBase< T, 4 >::SoftThreshold(), and utl::NDArray< T, 2 >::TransposeInplace().
|
protected |
If m_IsShared is true, the memory is owned by other object
Definition at line 1171 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Clear(), utl::NDArrayBase< T, 4 >::GetIsShared(), and utl::NDArrayBase< T, 4 >::SetData().
|
protected |
Definition at line 1167 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::GetIndex(), utl::NDArrayBase< T, 4 >::GetOffset(), utl::NDArrayBase< T, 4 >::GetOffSetTable(), utl::NDArrayBase< T, 4 >::GetRefSubArray(), utl::NDArrayBase< T, 4 >::GetSize(), utl::NDArrayBase< T, 4 >::NDArrayBase(), utl::NDArray< T, 4 >::operator()(), utl::NDArrayBase< T, 4 >::PrintWithIndex(), and utl::NDArrayBase< T, 4 >::Size().
|
protected |
Definition at line 1168 of file utlNDArray.h.
Referenced by utl::NDArrayBase< T, 4 >::Apply(), utl::NDArrayBase< T, 4 >::ArgMax(), utl::NDArray< T, 2 >::Cols(), utl::NDArray< T, 2 >::Columns(), utl::NDArray< T, 2 >::Determinant(), utl::NDArray< T, 2 >::EigenDecompositionSymmetricMatrix(), utl::NDArray< T, 4 >::EigenDecompositionWithMinorSymmetry(), utl::NDArrayBase< T, 4 >::ElementAbsolute(), utl::NDArrayBase< T, 4 >::ElementAxpby(), utl::NDArrayBase< T, 4 >::ElementCos(), utl::NDArrayBase< T, 4 >::ElementInverse(), utl::NDArrayBase< T, 4 >::ElementSin(), utl::NDArrayBase< T, 4 >::ElementSqrt(), utl::NDArrayBase< T, 4 >::ElementSquare(), utl::NDArray< T, 2 >::FillDiagonal(), utl::NDArray< T, 2 >::GetColumn(), utl::NDArray< T, 2 >::GetColumns(), utl::NDArray< T, 2 >::GetCrop(), utl::NDArray< T, 2 >::GetDiagonal(), utl::NDArray< T, 2 >::GetInfNorm(), utl::NDArray< T, 2 >::GetOneNorm(), utl::NDArrayBase< T, 4 >::GetRefSubArray(), utl::NDArray< T, 4 >::GetRefSubMatrix(), utl::NDArray< T, 2 >::GetRow(), utl::NDArray< T, 2 >::GetRows(), utl::NDArrayBase< T, 4 >::GetShape(), utl::NDArray< T, 2 >::GetTranspose(), utl::NDArray< T, 4 >::IsMajorSymmetric(), utl::NDArray< T, 4 >::IsMinorSymmetric(), utl::NDArrayBase< T, 4 >::IsSameShape(), utl::NDArray< T, 2 >::IsSquareMatrix(), utl::NDArray< T, 2 >::IsSymmetric(), utl::NDArray< T, 4 >::MajorSymmetrize(), utl::NDArray< T, 4 >::MinorSymmetrize(), utl::NDArrayBase< T, 4 >::NDArrayBase(), utl::NDArray< T, 2 >::operator()(), utl::NDArrayBase< T, 4 >::PrintWithIndex(), utl::NDArray< T, 2 >::Rows(), utl::NDArray< T, 2 >::Save(), utl::NDArray< T, 2 >::SetColumn(), utl::NDArray< T, 2 >::SetCrop(), utl::NDArray< T, 2 >::SetDiagonal(), utl::NDArray< T, 2 >::SetIdentity(), utl::NDArray< T, 2 >::SetRow(), utl::NDArray< T, 2 >::Symmetrize(), and utl::NDArray< T, 2 >::TransposeInplace().
|
static |
Definition at line 162 of file utlNDArray.h.