Basic Image AlgorithmS Library
2.8.0
|
#include <Base/Math/Tensor3D.hh>
Public Member Functions | |
void | Destroy () |
frees internal data More... | |
T * | GetData () |
const T * | GetData () const |
T *** | GetDataArray () |
int | GetDim1 () const |
int | GetDim2 () const |
int | GetDim3 () const |
T | GetLength () const |
void | NewSize (const int i, const int j, const int k, const T &def=(T) 0.0) |
allocates internal data More... | |
T & | operator() (unsigned int i, unsigned int j, unsigned int k) |
direct data access through () operator: T_i^{jk} More... | |
Tensor3D< T > & | operator= (const Tensor3D< T > &t) |
bool | operator== (const Tensor3D< T > &t) |
checks if all tensor entries are equal (up-to-scale-equality is not checked) More... | |
void | Scale (T factor) |
void | SetFromVector (const BIAS::Vector< T > &v) |
set the tensor by the rows of the vector. More... | |
void | SetZero () |
set all elements to zero More... | |
Tensor3D () | |
Tensor3D (const int i, const int j, const int k, const T &def=(T) 0.0) | |
Tensor3D (const Tensor3D< T > &t) | |
BIAS::Vector< T > | ToVector () |
~Tensor3D () | |
Protected Attributes | |
T * | _Data |
T *** | _DataArray |
int | _Dim1 |
int | _Dim2 |
int | _Dim3 |
int | _Size |
Definition at line 40 of file Tensor3D.hh.
Tensor3D::Tensor3D | ( | ) |
Definition at line 33 of file Tensor3D.cpp.
Tensor3D::Tensor3D | ( | const int | i, |
const int | j, | ||
const int | k, | ||
const T & | def = (T)0.0 |
||
) |
Definition at line 38 of file Tensor3D.cpp.
References BIAS::Tensor3D< T >::NewSize().
Tensor3D::Tensor3D | ( | const Tensor3D< T > & | t | ) |
Definition at line 46 of file Tensor3D.cpp.
Tensor3D::~Tensor3D | ( | ) |
Definition at line 52 of file Tensor3D.cpp.
void Tensor3D::Destroy | ( | ) |
frees internal data
Definition at line 90 of file Tensor3D.cpp.
|
inline |
Definition at line 72 of file Tensor3D.hh.
Referenced by BIAS::Tensor3D< T >::operator=(), and BIAS::Tensor3D< T >::operator==().
|
inline |
Definition at line 78 of file Tensor3D.hh.
|
inline |
Definition at line 75 of file Tensor3D.hh.
int Tensor3D::GetDim1 | ( | ) | const |
Definition at line 106 of file Tensor3D.cpp.
Referenced by BIAS::Tensor3D< T >::operator=(), and BIAS::Tensor3D< T >::operator==().
int Tensor3D::GetDim2 | ( | ) | const |
Definition at line 112 of file Tensor3D.cpp.
Referenced by BIAS::Tensor3D< T >::operator=(), and BIAS::Tensor3D< T >::operator==().
int Tensor3D::GetDim3 | ( | ) | const |
Definition at line 118 of file Tensor3D.cpp.
Referenced by BIAS::Tensor3D< T >::operator=(), and BIAS::Tensor3D< T >::operator==().
T Tensor3D::GetLength | ( | ) | const |
Definition at line 185 of file Tensor3D.cpp.
void Tensor3D::NewSize | ( | const int | i, |
const int | j, | ||
const int | k, | ||
const T & | def = (T)0.0 |
||
) |
allocates internal data
Definition at line 58 of file Tensor3D.cpp.
Referenced by BIAS::Tensor3D< T >::Tensor3D().
|
inline |
direct data access through () operator: T_i^{jk}
Definition at line 96 of file Tensor3D.hh.
Definition at line 130 of file Tensor3D.cpp.
References BIAS::Tensor3D< T >::GetData(), BIAS::Tensor3D< T >::GetDim1(), BIAS::Tensor3D< T >::GetDim2(), and BIAS::Tensor3D< T >::GetDim3().
Referenced by BIAS::Tensor3D3x3x3< TRIFOCALTENSOR_TYPE >::operator=().
bool Tensor3D::operator== | ( | const Tensor3D< T > & | t | ) |
checks if all tensor entries are equal (up-to-scale-equality is not checked)
Definition at line 138 of file Tensor3D.cpp.
References BIAS::Tensor3D< T >::GetData(), BIAS::Tensor3D< T >::GetDim1(), BIAS::Tensor3D< T >::GetDim2(), and BIAS::Tensor3D< T >::GetDim3().
void Tensor3D::Scale | ( | T | factor | ) |
Definition at line 177 of file Tensor3D.cpp.
void Tensor3D::SetFromVector | ( | const BIAS::Vector< T > & | v | ) |
set the tensor by the rows of the vector.
Vector size must be at least Dim1*Dim2*Dim3!
Definition at line 165 of file Tensor3D.cpp.
References BIAS::Vector< T >::Size().
Referenced by BIAS::TFTensorEstimation::Compute().
void Tensor3D::SetZero | ( | ) |
set all elements to zero
Definition at line 124 of file Tensor3D.cpp.
Vector< T > Tensor3D::ToVector | ( | ) |
Definition at line 150 of file Tensor3D.cpp.
|
protected |
Definition at line 107 of file Tensor3D.hh.
|
protected |
Definition at line 111 of file Tensor3D.hh.
|
protected |
Definition at line 112 of file Tensor3D.hh.
|
protected |
Definition at line 112 of file Tensor3D.hh.
|
protected |
Definition at line 112 of file Tensor3D.hh.
|
protected |
Definition at line 112 of file Tensor3D.hh.