iRoCS Toolbox
1.1.0
|
The CentralHessianFilter class implements the SeparableFilter interface and provides hessian computation using central differences. More...
#include "libArrayToolbox/CentralHessianFilter.hh"
Public Types | |
typedef blitz::TinyMatrix< DataT, Dim, Dim > | ResultT |
Public Member Functions | |
CentralHessianFilter (BoundaryTreatmentType bt=ValueBT, DataT const &boundaryValue=traits< DataT >::zero) | |
Default Constructor. More... | |
CentralHessianFilter (typename CentralGradientFilter< DataT, Dim >::Accuracy accuracy, BoundaryTreatmentType bt=ValueBT, DataT const &boundaryValue=traits< DataT >::zero) | |
Constructor. More... | |
virtual | ~CentralHessianFilter () |
Destructor. More... | |
CentralGradientFilter< DataT, Dim >::Accuracy | accuracy () const |
Get the order of accuracy of this filter. More... | |
virtual void | apply (Array< DataT, Dim > const &data, Array< blitz::TinyMatrix< DataT, Dim, Dim >, Dim > &result, iRoCS::ProgressReporter *pr=NULL) const |
Apply the filter to the given Array. More... | |
virtual void | apply (blitz::Array< DataT, Dim > const &data, blitz::TinyVector< double, Dim > const &elementSizeUm, blitz::Array< ResultT, Dim > &filtered, iRoCS::ProgressReporter *pr=NULL) const |
Apply the filter to the given Array. More... | |
virtual void | applyAlongDim (Array< DataT, Dim > const &data, Array< blitz::TinyMatrix< DataT, Dim, Dim >, Dim > &result, int dim, iRoCS::ProgressReporter *pr=NULL) const |
Apply the filter along the specified dimension. More... | |
virtual void | applyAlongDim (blitz::Array< DataT, Dim > const &data, blitz::TinyVector< double, Dim > const &elementSizeUm, blitz::Array< DataT, Dim > &filtered, int dim, iRoCS::ProgressReporter *pr=NULL) const |
Apply the filter along the specified dimension. More... | |
virtual void | applyAlongDim (blitz::Array< DataT, Dim > const &data, blitz::TinyVector< double, Dim > const &elementSizeUm, blitz::Array< ResultT, Dim > &filtered, int dim, iRoCS::ProgressReporter *pr=NULL) const |
Apply the filter along the specified dimension. More... | |
BoundaryTreatment< DataT, Dim > const & | boundaryTreatment () const |
Get a read-only reference to the boundary treatment object associated with this filter. More... | |
void | setAccuracy (typename CentralGradientFilter< DataT, Dim >::Accuracy accuracy) |
Set the order of accuracy of this filter. More... | |
void | setBoundaryTreatment (BoundaryTreatmentType bt, DataT const &boundaryValue=traits< DataT >::zero) |
Change the boundary treatment type to the type specified. More... | |
void | setBoundaryTreatment (BoundaryTreatment< DataT, Dim > const &bt) |
Change the boundary treatment type to the type specified. More... | |
Static Public Member Functions | |
static void | apply (blitz::Array< DataT, Dim > const &data, blitz::TinyVector< double, Dim > const &elementSizeUm, blitz::Array< ResultT, Dim > &filtered, typename CentralGradientFilter< DataT, Dim >::Accuracy accuracy, BoundaryTreatmentType btType=ValueBT, DataT const &boundaryValue=traits< DataT >::zero, iRoCS::ProgressReporter *pr=NULL) |
Apply the filter to the given Array. More... | |
static void | apply (Array< DataT, Dim > const &data, Array< ResultT, Dim > &filtered, typename CentralGradientFilter< DataT, Dim >::Accuracy accuracy, BoundaryTreatmentType btType=ValueBT, DataT const &boundaryValue=traits< DataT >::zero, iRoCS::ProgressReporter *pr=NULL) |
Apply the filter to the given Array. More... | |
Protected Attributes | |
BoundaryTreatment< DataT, Dim > * | p_bt |
The boundary treatment object to use for out-of-Array access. More... | |
The CentralHessianFilter class implements the SeparableFilter interface and provides hessian computation using central differences.
Definition at line 51 of file CentralHessianFilter.hh.
typedef blitz::TinyMatrix<DataT,Dim,Dim> atb::CentralHessianFilter< DataT, Dim >::ResultT |
Definition at line 57 of file CentralHessianFilter.hh.
atb::CentralHessianFilter< DataT, Dim >::CentralHessianFilter | ( | BoundaryTreatmentType | bt = ValueBT , |
DataT const & | boundaryValue = traits< DataT >::zero |
||
) |
Default Constructor.
Creates a Hessian filter with second order accurate discrete hessian approimation using central differences.
bt | The boundary treatment this filter uses |
boundaryValue | If bt is ValueBT, this value will be used for out-of-Array access |
atb::CentralHessianFilter< DataT, Dim >::CentralHessianFilter | ( | typename CentralGradientFilter< DataT, Dim >::Accuracy | accuracy, |
BoundaryTreatmentType | bt = ValueBT , |
||
DataT const & | boundaryValue = traits< DataT >::zero |
||
) |
Constructor.
accuracy | The accuracy of the filter |
bt | The boundary treatment this filter uses |
boundaryValue | If bt is ValueBT, this value will be used for out-of-Array access |
|
virtual |
Destructor.
CentralGradientFilter<DataT,Dim>::Accuracy atb::CentralHessianFilter< DataT, Dim >::accuracy | ( | ) | const |
Get the order of accuracy of this filter.
Currently only snd and 4th order are implemented.
void atb::CentralHessianFilter< DataT, Dim >::setAccuracy | ( | typename CentralGradientFilter< DataT, Dim >::Accuracy | accuracy | ) |
Set the order of accuracy of this filter.
Currently only snd and 4th order are implemented.
accuracy | The new accuracy of the discrete derivative approximation |
|
virtual |
Apply the filter along the specified dimension.
data | The data Array to filter |
elementSizeUm | The data voxel extents in micrometers |
filtered | The filter result |
dim | The component of the hessian to compute. The given linear index is converted into a (row, column) pair using the formula row = dim / Dim; col = dim % Dim. |
|
virtual |
Apply the filter along the specified dimension.
data | The data Array to filter |
elementSizeUm | The data voxel extents in micrometers |
filtered | The filter result (in the dim'th vector component) |
dim | The component of the hessian to compute. The given linear index is converted into a (row, column) pair using the formula row = dim / Dim; col = dim % Dim. |
Implements atb::SeparableFilter< DataT, Dim, blitz::TinyMatrix< DataT, Dim, Dim > >.
|
virtual |
Apply the filter to the given Array.
data | The blitz++ Array to apply the filter to |
elementSizeUm | The element size of the Array |
filtered | The filtering result |
RuntimeError | If an error occurs during the filter operation an exception of this kind is thrown |
Implements atb::Filter< DataT, Dim, blitz::TinyMatrix< DataT, Dim, Dim > >.
|
static |
Apply the filter to the given Array.
data | The blitz++ Array to apply the filter to |
elementSizeUm | The element size of the Array |
filtered | The filtering result |
accuracy | The filter accuracy order |
btType | The boundary treatment to apply |
boundaryValue | The out-of-Array value that should be used if btType == ValueBT |
RuntimeError | If an error occurs during the filter operation an exception of this kind is thrown |
|
static |
Apply the filter to the given Array.
data | The blitz++ Array to apply the filter to |
filtered | The filtering result |
accuracy | The filter accuracy order |
btType | The boundary treatment to apply |
boundaryValue | If btType is Value, this value is assumed outside the Arrays |
btType | The boundary treatment to apply |
boundaryValue | The out-of-Array value that should be used if btType == ValueBT |
RuntimeError | If an error occurs during the filter operation an exception of this kind is thrown |
|
virtualinherited |
Apply the filter along the specified dimension.
data | The data Array to filter |
result | The filter result |
dim | The dimension along which to apply the filter |
RuntimeError | If an error occurs during the filter operation an exception of this kind is thrown |
|
inherited |
Get a read-only reference to the boundary treatment object associated with this filter.
|
inherited |
Change the boundary treatment type to the type specified.
bt | The boundary treatment this filter uses |
boundaryValue | If bt is ValueBT, this value will be used for out-of-Array access |
|
inherited |
Change the boundary treatment type to the type specified.
bt | The boundary treatment this filter uses |
|
virtualinherited |
Apply the filter to the given Array.
data | The Array to apply the filter to |
result | The filtering result |
pr | If given progress will be reported to this ProgressReporter |
RuntimeError | If an error occurs during the filter operation an exception of this kind is thrown |
|
protectedinherited |
The boundary treatment object to use for out-of-Array access.
This is set during Filter object creation and can be changed by calling the setBoundaryTreatment() method. It gets destroyed, when the filter is deleted. If you delete the BoundaryTreatment object in a subclass, you must set this pointer to the NULL pointer.