7 #ifndef IMPEM2D_SCORES_2D_H
8 #define IMPEM2D_SCORES_2D_H
10 #include "IMP/em2d/em2d_config.h"
19 IMPEM2D_BEGIN_NAMESPACE
24 const RegistrationResult &rr2);
29 const RegistrationResult &rr2);
31 IMPEM2DEXPORT
double get_average_rotation_error(
35 IMPEM2DEXPORT
double get_average_shift_error(
65 return get_private_score(image, projection);
68 void set_variance_image(
Image *var) {
69 set_variance_image_private(var);
76 unsigned int n_members_;
79 virtual double get_private_score(
Image *image,
Image *projection)
const = 0;
80 virtual void set_variance_image_private(
Image *image) {
IMP_UNUSED(image);};
93 double get_private_score(
Image *,
Image *)
const;
94 void set_variance_imag_private(
Image *var) {variance_ = var;}
105 double get_private_score(
Image *image,
Image *projection)
const {
117 double get_private_score(
Image *image,
Image *projection)
const;
127 public std::binary_function< T , T ,bool>
131 bool operator()(
const T &a,
const T &b)
const {
132 return a.get_ccc() >= b.get_ccc();
134 void show(std::ostream &)
const {}
143 public std::binary_function< T, T, bool>
147 bool operator()(
const T &a,
const T &b)
const {
148 return a.second < b.second;
150 void show(std::ostream &)
const {}
160 public std::binary_function< T , T ,bool>
164 bool operator()(
const T &a,
const T &b)
const {
165 return a.get_score() < b.get_score();
167 void show(std::ostream &)
const {}
170 IMPEM2D_END_NAMESPACE
double get_shift_error(const RegistrationResult &rr1, const RegistrationResult &rr2)
Distance between the two in-plane translations.
Score based on the mean of the absolute difference.
#define IMP_UNUSED(variable)
A smart pointer to a reference counted object.
inteface with OpenCV Copyright 2007-2013 IMP Inventors. All rights reserved.
double get_rotation_error(const RegistrationResult &rr1, const RegistrationResult &rr2)
double get_score(Image *image, Image *projection) const
Given an image and a projection, returns the appropiate score.
IMP images for Electron Microscopy using openCV matrices Copyright 2007-2013 IMP Inventors. All rights reserved.
Compare two classes that return a score.
IMP::base::Vector< RegistrationResult > RegistrationResults
Various general useful macros for IMP.
Base class for all scoring functions related to em2d.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Score based on Chi^2 = ((pixels_iamge - pixels_projection)/stddev_image)^2.
Comparison by value of the ccc.
double get_cross_correlation_coefficient(Image *im1, Image *im2)
Cross correlation between two images.
Common base class for heavy weight IMP objects.
#define IMP_OBJECTS(Name, PluralName)
Define the types for storing sets of objects.
void show(Hierarchy h, std::ostream &out=std::cout)
Print out a molecular hierarchy.
double get_global_score(const RegistrationResults &RRs)
A shared base class to help in debugging and things.
Import IMP/kernel/VersionInfo.h in the namespace.
Registration results class Copyright 2007-2013 IMP Inventors. All rights reserved.
Comparison of pairs by checking the second element.
2D Electron Microscopy images in IMP