te::rp::MixtureModelStrategy Class Referenceabstract

Raster mixture model strategy base class. More...

#include <MixtureModelStrategy.h>

Inheritance diagram for te::rp::MixtureModelStrategy:
te::rp::MixtureModelLinearStrategy te::rp::MixtureModelPCAStrategy

Public Member Functions

virtual bool execute (const te::rst::Raster &inputRaster, const std::vector< unsigned int > &inputRasterBands, const std::vector< std::string > &inputSensorBands, const std::map< std::string, std::vector< double > > &components, std::vector< te::rst::Raster * > &outputRaster, const bool normalize, const bool enableProgressInterface)=0 throw (te::rp::Exception)
 Executes the segmentation strategy. More...
 
virtual bool generateTransformMatrix (const std::vector< unsigned int > &inputRasterBands, const std::vector< std::string > &inputSensorBands, const std::map< std::string, std::vector< double > > &components)=0
 Generates the used transformation matrix (when applicable). More...
 
const std::string & getErrorMessage () const
 Return the current error message if there is any. More...
 
virtual bool getMinMax (std::vector< double > &, std::vector< double > &) const =0
 
virtual bool getMinMaxError (std::vector< double > &, std::vector< double > &) const =0
 
virtual bool getTransformMatrix (boost::numeric::ublas::matrix< double > &matrix) const =0
 Returns the used transformation matrix (when applicable). More...
 
virtual bool initialize (StrategyParameters const *const strategyParams)=0 throw (te::rp::Exception)
 Initialize the segmentation strategy. More...
 
virtual bool setTransformMatrix (boost::numeric::ublas::matrix< double > &matrix)=0
 Sets the used transformation matrix. More...
 
virtual ~MixtureModelStrategy ()
 Virtual destructor. More...
 

Protected Member Functions

 MixtureModelStrategy ()
 Default constructor. More...
 
virtual void reset ()
 Reset to an initial state. More...
 
void setErrorMessage (const std::string &newErrorMessage)
 Set the current error message. More...
 

Private Member Functions

 MixtureModelStrategy (const MixtureModelStrategy &rhs)
 Copy constructor. More...
 
MixtureModelStrategyoperator= (const MixtureModelStrategy &rhs)
 Assignment operator. More...
 

Private Attributes

std::string m_errorMessage
 Current error message. More...
 

Detailed Description

Raster mixture model strategy base class.

Definition at line 49 of file MixtureModelStrategy.h.

Constructor & Destructor Documentation

te::rp::MixtureModelStrategy::~MixtureModelStrategy ( )
virtualdefault

Virtual destructor.

te::rp::MixtureModelStrategy::MixtureModelStrategy ( )
protecteddefault

Default constructor.

te::rp::MixtureModelStrategy::MixtureModelStrategy ( const MixtureModelStrategy rhs)
privatedefault

Copy constructor.

Parameters
rhsThe right-hand side Raster.

Member Function Documentation

virtual bool te::rp::MixtureModelStrategy::execute ( const te::rst::Raster inputRaster,
const std::vector< unsigned int > &  inputRasterBands,
const std::vector< std::string > &  inputSensorBands,
const std::map< std::string, std::vector< double > > &  components,
std::vector< te::rst::Raster * > &  outputRaster,
const bool  normalize,
const bool  enableProgressInterface 
)
throw (te::rp::Exception
)
pure virtual

Executes the segmentation strategy.

Parameters
inputRasterInput raster.
inputRasterBandsInput raster bands.
componentsThe set of endmembers and its radiances.
outputRasterOutput raster vector, contains output raster and error raster if requested.
enableProgressInterfaceEnable the internal strategy to update the progress interface.
Returns
true if OK, false on errors.

Implemented in te::rp::MixtureModelLinearStrategy, and te::rp::MixtureModelPCAStrategy.

virtual bool te::rp::MixtureModelStrategy::generateTransformMatrix ( const std::vector< unsigned int > &  inputRasterBands,
const std::vector< std::string > &  inputSensorBands,
const std::map< std::string, std::vector< double > > &  components 
)
pure virtual

Generates the used transformation matrix (when applicable).

Parameters
inputRasterBandsInput raster bands.
inputSensorBandsInput names of the sensor/bands.
componentsA set of endmembers and its radiances.
Returns
true if OK, false on errors or not applicable cases.

Implemented in te::rp::MixtureModelLinearStrategy, and te::rp::MixtureModelPCAStrategy.

const std::string & te::rp::MixtureModelStrategy::getErrorMessage ( ) const

Return the current error message if there is any.

Returns
Return the current error message if there is any.

Definition at line 38 of file MixtureModelStrategy.cpp.

References m_errorMessage.

virtual bool te::rp::MixtureModelStrategy::getMinMax ( std::vector< double > &  ,
std::vector< double > &   
) const
pure virtual
virtual bool te::rp::MixtureModelStrategy::getMinMaxError ( std::vector< double > &  ,
std::vector< double > &   
) const
pure virtual
virtual bool te::rp::MixtureModelStrategy::getTransformMatrix ( boost::numeric::ublas::matrix< double > &  matrix) const
pure virtual

Returns the used transformation matrix (when applicable).

Parameters
matrixThe transformation matrix.
Returns
true if OK, false on errors or not applicable cases.

Implemented in te::rp::MixtureModelLinearStrategy, and te::rp::MixtureModelPCAStrategy.

virtual bool te::rp::MixtureModelStrategy::initialize ( StrategyParameters const *const  strategyParams)
throw (te::rp::Exception
)
pure virtual

Initialize the segmentation strategy.

Parameters
strategyParamsA pointer to the user given specific segmentation strategy parameters ou NULL if no parameters are present.
Returns
true if OK, false on errors.

Implemented in te::rp::MixtureModelLinearStrategy, and te::rp::MixtureModelPCAStrategy.

te::rp::MixtureModelStrategy & te::rp::MixtureModelStrategy::operator= ( const MixtureModelStrategy rhs)
privatedefault

Assignment operator.

Parameters
rhsThe right-hand-side copy that would be used to copy from.
Returns
A reference to this object.
void te::rp::MixtureModelStrategy::reset ( )
protectedvirtual

Reset to an initial state.

Definition at line 48 of file MixtureModelStrategy.cpp.

References m_errorMessage.

void te::rp::MixtureModelStrategy::setErrorMessage ( const std::string &  newErrorMessage)
protected

Set the current error message.

Parameters
newErrorMessageNew error message;

Definition at line 43 of file MixtureModelStrategy.cpp.

References m_errorMessage.

virtual bool te::rp::MixtureModelStrategy::setTransformMatrix ( boost::numeric::ublas::matrix< double > &  matrix)
pure virtual

Sets the used transformation matrix.

Parameters
matrixThe transformation matrix.
Returns
true if OK, false on errors or not applicable cases.

Implemented in te::rp::MixtureModelLinearStrategy, and te::rp::MixtureModelPCAStrategy.

Member Data Documentation

std::string te::rp::MixtureModelStrategy::m_errorMessage
private

Current error message.

Definition at line 134 of file MixtureModelStrategy.h.

Referenced by getErrorMessage(), reset(), and setErrorMessage().


The documentation for this class was generated from the following files: