Given a statistical model (prior) and a set of point constraints (likelihood), generate a new PCA model (posterior). More...
#include <PosteriorModelBuilder.h>
Public Types | |
typedef Representer< T > | RepresenterType |
typedef ModelBuilder< T > | Superclass |
typedef Superclass::DataManagerType | DataManagerType |
typedef Superclass::StatisticalModelType | StatisticalModelType |
typedef RepresenterType::ValueType | ValueType |
typedef RepresenterType::PointType | PointType |
typedef StatisticalModelType::PointValueListType | PointValueListType |
typedef DataManagerType::DataItemListType | DataItemListType |
typedef MatrixType | PointCovarianceMatrixType |
typedef StatisticalModelType::PointValuePairType | PointValuePairType |
typedef std::pair < PointValuePairType, PointCovarianceMatrixType > | PointValueWithCovariancePairType |
typedef std::list < PointValueWithCovariancePairType > | PointValueWithCovarianceListType |
![]() | |
typedef Representer< T > | RepresenterType |
typedef StatisticalModel< T > | StatisticalModelType |
typedef DataManager< T > | DataManagerType |
typedef DataManagerType::DataItemListType | DataItemListType |
Public Member Functions | |
void | Delete () |
virtual | ~PosteriorModelBuilder () |
StatisticalModelType * | BuildNewModel (const DataItemListType &dataItemList, const PointValueListType &pointValues, double pointValueNoiseVariance, double noiseVariance) const |
StatisticalModelType * | BuildNewModel (const DataItemListType &DataItemList, const PointValueWithCovarianceListType &pointValuesWithCovariance, double noiseVariance) const |
StatisticalModelType * | BuildNewModelFromModel (const StatisticalModelType *model, const PointValueListType &pointValues, double pointValueNoiseVariance, bool computeScores=true) const |
StatisticalModelType * | BuildNewModelFromModel (const StatisticalModelType *model, const PointValueWithCovarianceListType &pointValuesWithCovariance, bool computeScores=true) const |
PointValueWithCovarianceListType | TrivialPointValueWithCovarianceListWithUniformNoise (const PointValueListType &pointValues, double pointValueNoiseVariance) const |
Static Public Member Functions | |
static PosteriorModelBuilder * | Create () |
Additional Inherited Members | |
![]() | |
static const double | TOLERANCE = 1e-5 |
![]() | |
MatrixType | ComputeScores (const MatrixType &X, const StatisticalModelType *model) const |
ModelInfo | CollectModelInfo () const |
Given a statistical model (prior) and a set of point constraints (likelihood), generate a new PCA model (posterior).
This class builds a StatisticalModel, just as PCAModelBuilder. However, in addition to the data, this model builder also takes as input a set of point constraints, i.e. known values for points. The resulting model will satisfy these constraints, and thus has a much lower variability than an unconstrained model would have.
For mathematical detailes see the paper Posterior Shape Models Thomas Albrecht, Marcel L ̈thi, Thomas Gerig, Thomas Vetter Medical Image Analysis 2013
Add method that allows for the use of the pointId in the constraint.
|
inlinevirtual |
destructor
PosteriorModelBuilder< T >::StatisticalModelType * statismo::PosteriorModelBuilder< T >::BuildNewModel | ( | const DataItemListType & | dataItemList, |
const PointValueListType & | pointValues, | ||
double | pointValueNoiseVariance, | ||
double | noiseVariance | ||
) | const |
Builds a new model from the data provided in the dataManager, and the given constraints. This version of the function assumes a noise with a uniform uncorrelated variance of the form pointValueNoiseVariance * identityMatrix at every given point.
DataItemList | The list holding the data the model is built from |
pointValues | A list of (point, value) pairs with the known values. |
pointValueNoiseVariance | The variance of the estimated error at the known points (the pointValues) |
noiseVariance | The variance of the noise assumed on our data |
PosteriorModelBuilder< T >::StatisticalModelType * statismo::PosteriorModelBuilder< T >::BuildNewModel | ( | const DataItemListType & | DataItemList, |
const PointValueWithCovarianceListType & | pointValuesWithCovariance, | ||
double | noiseVariance | ||
) | const |
Builds a new model from the data provided in the dataManager, and the given constraints. For this version of the function, the covariance matrix of the noise needs to be specified for every point. These covariance matrices are passed in the pointValuesWithCovariance list.
DataItemList | The list holding the data the model is built from |
pointValuesWithCovariance | A list of ((point,value), covarianceMatrix) for each known value. |
noiseVariance | The variance of the noise assumed on our data |
PosteriorModelBuilder< T >::StatisticalModelType * statismo::PosteriorModelBuilder< T >::BuildNewModelFromModel | ( | const StatisticalModelType * | model, |
const PointValueListType & | pointValues, | ||
double | pointValueNoiseVariance, | ||
bool | computeScores = true |
||
) | const |
Builds a new StatisticalModel given a StatisticalModel and the given constraints. If we interpret the given model as a prior distribution over the modeled objects, the resulting model can (loosely) be interpreted as the posterior distribution, after having observed the data given in the PointValues. This version of the function assumes a noise with a uniform uncorrelated variance of the form pointValueNoiseVariance * identityMatrix at every given point.
model | A statistical model. |
pointValues | A list of (point, value) pairs with the known values. |
pointValueNoiseVariance | The variance of the estimated error at the known points (the pointValues) |
computeScores | Determines whether the scores are computed and stored in the model. |
PosteriorModelBuilder< T >::StatisticalModelType * statismo::PosteriorModelBuilder< T >::BuildNewModelFromModel | ( | const StatisticalModelType * | model, |
const PointValueWithCovarianceListType & | pointValuesWithCovariance, | ||
bool | computeScores = true |
||
) | const |
Builds a new StatisticalModel given a StatisticalModel and the given constraints. If we interpret the given model as a prior distribution over the modeled objects, the resulting model can (loosely) be interpreted as the posterior distribution, after having observed the data given in the PointValues. For this version of the function, the covariance matrix of the noise needs to be specified for every point. These covariance matrices are passed in the pointValuesWithCovariance list.
model | A statistical model. |
pointValuesWithCovariance | A list of ((point,value), covarianceMatrix) for each known value. |
computeScores | Determines whether the scores are computed and stored in the model. |
|
inlinestatic |
Factory method to create a new PosteriorModelBuilder
representer | The representer |
|
inline |
Destroy the object. The same effect can be achieved by deleting the object in the usual way using the c++ delete keyword.
PosteriorModelBuilder< T >::PointValueWithCovarianceListType statismo::PosteriorModelBuilder< T >::TrivialPointValueWithCovarianceListWithUniformNoise | ( | const PointValueListType & | pointValues, |
double | pointValueNoiseVariance | ||
) | const |
A convenience function to create a PointValueWithCovarianceList with uniform variance
pointValues | A list of (point, value) pairs with the known values. |
pointValueNoiseVariance | The variance of the estimated error at the known points (the pointValues) |