#include <OpenMS/ANALYSIS/MAPMATCHING/PoseClusteringShiftSuperimposer.h>
It works on two element maps (FeatureMap is the default map type, but you can also use a pointer map like DPeakConstReferenceArray) and computes a translation, that maps the elements of one map (scene map) as near as possible to the elements in the other map (model map). A element can be a DPeak, a DFeature, a ConsensusPeak or ConsensusFeature (wheras DFeature is the default element type).
This superimposer hashs all possible shifts and defines the translation with the most votes as the best one.
PoseClusteringShiftSuperimposer Parameters are explained on a separate page.
Public Types | |
enum | Maps { MODEL = 0, SCENE = 1 } |
typedef BaseSuperimposer< MapT > | Base |
typedef Base::QualityType | QualityType |
Quality type. | |
typedef Base::PositionType | PositionType |
Position type. | |
typedef Base::IntensityType | IntensityType |
typedef Base::PointType | PointType |
Type of elements considered here. | |
typedef Base::PointMapType | PointMapType |
Container for input elements. | |
typedef PositionType::CoordinateType | CoordinateType |
typedef DBoundingBox< 2 > | PositionBoundingBoxType |
typedef DBoundingBox< 1 > | IntensityBoundingBoxType |
typedef std::vector< UInt > | ElementBucketType |
typedef Matrix< ElementBucketType > | ElementBucketMatrixType |
typedef Shift | ShiftType |
typedef Matrix< typename ShiftType::QualityType > | ShiftQualityMatrixType |
typedef Matrix< ShiftType > | ShiftMatrixType |
typedef LinearMapping | FinalShiftType |
Public Member Functions | |
PoseClusteringShiftSuperimposer () | |
Constructor. | |
virtual | ~PoseClusteringShiftSuperimposer () |
Destructor. | |
virtual void | run () |
Estimates the transformation for each grid cell. | |
void | setShiftBucketSize (UInt dim, double shift_bucket_size) |
Set size of shift buckets (in dimension dim). | |
double | getShiftBucketSize (UInt dim) const |
Get size of shift buckets (in dimension dim). | |
void | setElementBucketWindow (UInt dim, UInt element_bucket_window) |
Set number of neighbouring element buckets to be considered for the calculation of the final transformation (in dimension dim). | |
UInt | getElementBucketWindow (UInt dim) const |
Get number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim). | |
void | setShiftBucketWindow (UInt dim, UInt shift_bucket_window) |
Set number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim). | |
UInt | getShiftBucketWindow (UInt dim) const |
Get number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim). | |
Static Public Member Functions | |
static BaseSuperimposer < PointMapType > * | create () |
Returns an instance of this class. | |
static const String | getProductName () |
Returns the name of this module. | |
Protected Member Functions | |
virtual void | updateMembers_ () |
This method is used to update extra member variables at the end of the setParam() method. | |
void | computeElementBuckets_ () |
Fill the buckets with the indices of the corresponding elements. | |
void | computeShiftBuckets_ () |
Fill the buckets of shifts. | |
void | computeShift_ () |
Compute the shift. | |
ShiftType | shift_ (PointType const &left, PointType const &right) const |
Compute the shift and similarity for a pair of elements; larger quality values are better. | |
Protected Attributes | |
PositionBoundingBoxType | element_map_position_bounding_box_ [2] |
Holds the bounding box of all input elements. | |
PositionBoundingBoxType | element_map_position_bounding_box_enlarged_ [2] |
IntensityBoundingBoxType | element_map_intensity_bounding_box_ [2] |
Holds a bounding box for the input element intensities. | |
ElementBucketMatrixType | element_bucket_ [2] |
Element indices are stored in theses buckets. | |
PositionType | element_bucket_size_ |
Diagonal size of each bucket. | |
ShiftQualityMatrixType | shift_bucket_ |
Shifts are stored (summed up) in these buckets. | |
PositionBoundingBoxType | shift_bounding_box_ |
Holds a bounding box for all possible shift vectors. | |
PositionBoundingBoxType | shift_bounding_box_enlarged_ |
PositionType | shift_bucket_size_ |
Diagonal size of each bucket in shift_bucket_. | |
UInt | element_bucket_window_ [2] |
UInt | shift_bucket_window_ [2] |
Classes | |
class | Shift |
Intensity bounding box. More... |
typedef BaseSuperimposer< MapT > Base |
typedef Base::QualityType QualityType |
typedef Base::PositionType PositionType |
typedef Base::IntensityType IntensityType |
Reimplemented from BaseSuperimposer.
typedef Base::PointType PointType |
typedef Base::PointMapType PointMapType |
typedef DBoundingBox<2> PositionBoundingBoxType |
typedef DBoundingBox<1> IntensityBoundingBoxType |
typedef std::vector<UInt> ElementBucketType |
typedef Matrix< ElementBucketType > ElementBucketMatrixType |
typedef Matrix< typename ShiftType::QualityType > ShiftQualityMatrixType |
typedef Matrix< ShiftType > ShiftMatrixType |
typedef LinearMapping FinalShiftType |
enum Maps |
Symbolic names for indices of element maps etc. This should make things more understandable and maintainable.
Reimplemented from BaseSuperimposer.
PoseClusteringShiftSuperimposer | ( | ) | [inline] |
Constructor.
virtual ~PoseClusteringShiftSuperimposer | ( | ) | [inline, virtual] |
Destructor.
virtual void run | ( | ) | [inline, virtual] |
static BaseSuperimposer<PointMapType>* create | ( | ) | [inline, static] |
Returns an instance of this class.
static const String getProductName | ( | ) | [inline, static] |
Returns the name of this module.
void setShiftBucketSize | ( | UInt | dim, | |
double | shift_bucket_size | |||
) | [inline] |
Set size of shift buckets (in dimension dim).
double getShiftBucketSize | ( | UInt | dim | ) | const [inline] |
Get size of shift buckets (in dimension dim).
Set number of neighbouring element buckets to be considered for the calculation of the final transformation (in dimension dim).
Get number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim).
Set number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim).
Get number of neighbouring shift buckets to be considered for the calculation of the final transformation (in dimension dim).
virtual void updateMembers_ | ( | ) | [inline, protected, virtual] |
This method is used to update extra member variables at the end of the setParam() method.
Also call it at the end of the derived classes' copy constructor and assignment operator.
The default implementation is empty.
Reimplemented from DefaultParamHandler.
void computeElementBuckets_ | ( | ) | [inline, protected] |
Fill the buckets with the indices of the corresponding elements.
void computeShiftBuckets_ | ( | ) | [inline, protected] |
Fill the buckets of shifts.
Note that computeElementBuckets_() must have been called before to make this work properly.
void computeShift_ | ( | ) | [inline, protected] |
Compute the shift.
Note that shift_buckets_ must have been calculated before.
Compute the shift and similarity for a pair of elements; larger quality values are better.
The returned value should express our confidence that one element might possibly be matched to the other.
Currently this will just calculate the ratio of intensities, either "left/right" or "right/left", such that a value between 0 and 1 is returned.
PositionBoundingBoxType element_map_position_bounding_box_[2] [protected] |
Holds the bounding box of all input elements.
Holds the enlarged bounding box for all input elements. It is larger by about half of a bucket in all directions.
IntensityBoundingBoxType element_map_intensity_bounding_box_[2] [protected] |
Holds a bounding box for the input element intensities.
ElementBucketMatrixType element_bucket_[2] [protected] |
Element indices are stored in theses buckets.
PositionType element_bucket_size_ [protected] |
Diagonal size of each bucket.
ShiftQualityMatrixType shift_bucket_ [protected] |
Shifts are stored (summed up) in these buckets.
PositionBoundingBoxType shift_bounding_box_ [protected] |
Holds a bounding box for all possible shift vectors.
PositionBoundingBoxType shift_bounding_box_enlarged_ [protected] |
Holds an enlarged bounding box for all shift vectors. It is larger by about half of a bucket in all directions.
PositionType shift_bucket_size_ [protected] |
Diagonal size of each bucket in shift_bucket_.
UInt element_bucket_window_[2] [protected] |
Number of surrounding buckets of element indices to be considered when computing shifts.
UInt shift_bucket_window_[2] [protected] |
Number of surrounding buckets of shift indices to be considered when computing shifts.
Generated Tue Apr 1 15:36:42 2008 -- using doxygen 1.5.4 | OpenMS / TOPP 1.1 |