IMP
2.2.0
The Integrative Modeling Platform
IMP Mainpage
All IMP Modules
Related Pages
Modules
Namespaces
Classes
Files
Examples
Indexes
File List
File Members
CollisionCrossSection.h
Go to the documentation of this file.
1
/**
2
* \file IMP/em2d/CollisionCrossSection.h
3
* \brief
4
*
5
* Copyright 2007-2014 IMP Inventors. All rights reserved.
6
*
7
*/
8
9
#ifndef IMPEM2D_COLLISION_CROSS_SECTION_H
10
#define IMPEM2D_COLLISION_CROSS_SECTION_H
11
12
#include "
IMP/em2d/ProjectionMask.h
"
13
#include "
IMP/em2d/RegistrationResult.h
"
14
#include "
IMP/em2d/project.h
"
15
#include "
IMP/macros.h
"
16
#include "
IMP/Particle.h
"
17
18
IMPEM2D_BEGIN_NAMESPACE
19
20
//! Determine the collision cross section for some projections of particles
21
class
IMPEM2DEXPORT
CollisionCrossSection
:
public
IMP::base::Object
{
22
public
:
23
/*!
24
\param[in] n_projections Number of projections to use for obtaining the CCS
25
\param[in] resolution "Resolution" to use to generate the projections.
26
\param[in] pixel_size size in A/pix to use when generating the projections
27
\param[in] projection_image_size The size of the projections to generate;
28
for this value you should request a size so that
29
pixel_size * projection_image_size >= Max distance between two
30
particles.
31
*/
32
CollisionCrossSection
(
unsigned
int
n_projections,
double
resolution,
33
double
pixel_size,
double
projection_image_size);
34
35
/**
36
* kernel::Particles used to calculate their collision cross section
37
* @param ps The particles
38
*/
39
void
set_model_particles(
const
kernel::ParticlesTemp
&ps);
40
41
/**
42
* Returns the collision cross section. Before using this function you need
43
* to set the particles with set_model_particles()
44
* @return The value of the collision cross section
45
*/
46
double
get_ccs()
const
;
47
48
/**
49
* Shows information about the class
50
* @param out Stream used to show the information
51
*/
52
void
show
(std::ostream &out)
const
{
53
out <<
"Collision Cross section."
<< std::endl;
54
}
55
IMP_OBJECT_METHODS
(
CollisionCrossSection
);
56
57
protected
:
58
/*! Gets the sum of the values in the pixels with value > 0
59
\param[in] m The projected area is computed for this matrix
60
\return Values of the area
61
*/
62
double
get_projected_area(
const
cv::Mat &m)
const
;
63
64
unsigned
int
n_projections_;
65
double
resolution_;
66
double
pixel_size_;
67
unsigned
int
img_size_;
68
bool
particles_set_;
69
em2d::RegistrationResults
regs_;
70
cv::Mat average_projection_;
71
em2d::MasksManagerPtr masks_manager_;
72
double
collision_cross_section_;
73
};
74
IMP_OBJECTS
(
CollisionCrossSection
,
CollisionCrossSections
);
75
76
IMPEM2D_END_NAMESPACE
77
78
#endif
/* IMPEM2D_COLLISION_CROSS_SECTION_H */
project.h
Generation of projections from models or density maps Copyright 2007-2014 IMP Inventors. All rights reserved.
ProjectionMask.h
projection masks Copyright 2007-2014 IMP Inventors. All rights reserved.
IMP::em2d::CollisionCrossSection::show
void show(std::ostream &out) const
Definition:
CollisionCrossSection.h:52
macros.h
Import IMP/kernel/macros.h in the namespace.
IMP::base::Vector< base::WeakPointer< Particle > >
IMP_OBJECT_METHODS
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
Definition:
base/object_macros.h:25
IMP::base::Object
Common base class for heavy weight IMP objects.
Definition:
base/Object.h:106
IMP_OBJECTS
#define IMP_OBJECTS(Name, PluralName)
Define the types for storing sets of objects.
Definition:
base/object_macros.h:52
Particle.h
Import IMP/kernel/Particle.h in the namespace.
IMP::em2d::CollisionCrossSection
Determine the collision cross section for some projections of particles.
Definition:
CollisionCrossSection.h:21
RegistrationResult.h
Registration results class Copyright 2007-2014 IMP Inventors. All rights reserved.