RDKit
Open-source cheminformatics and machine learning.
|
#include <UniformRealValueGrid3D.h>
Public Member Functions | |
UniformRealValueGrid3D () | |
UniformRealValueGrid3D (double dimX, double dimY, double dimZ, double spacing=0.5, const RDGeom::Point3D *offset=nullptr, const RDKit::RealValueVect *data=nullptr) | |
ctor | |
UniformRealValueGrid3D (const UniformRealValueGrid3D &other) | |
UniformRealValueGrid3D & | operator= (const UniformRealValueGrid3D &other) |
UniformRealValueGrid3D (const std::string &pkl) | |
construct from a string pickle | |
UniformRealValueGrid3D (const char *pkl, unsigned int) | |
construct from a text pickle | |
int | getGridPointIndex (const RDGeom::Point3D &point) const override |
Get the index of the grid point closest to point. | |
double | getVal (const RDGeom::Point3D &point) const override |
Get the value at the grid point closest to the specified point. | |
double | getVal (unsigned int pointId) const override |
Get the value at a specified grid point. | |
void | setVal (const RDGeom::Point3D &point, double val) override |
Set the value at the grid point closest to the specified point. | |
RDGeom::Point3D | getGridPointLoc (unsigned int pointId) const override |
get the location of the specified grid point | |
void | setVal (unsigned int pointId, double val) override |
Set the value at the specified grid point. | |
unsigned int | getSize () const override |
get the size of the grid (number of grid points) | |
int | getGridIndex (unsigned int xi, unsigned int yi, unsigned int zi) const |
get the index of the grid point given the x, y, z indices | |
void | getGridIndices (unsigned int idx, unsigned int &xi, unsigned int &yi, unsigned int &zi) const |
get the x, y, and z indices of a grid-point index | |
unsigned int | getNumX () const |
get the number of grid points along x-axis | |
unsigned int | getNumY () const |
get the number of grid points along y-axis | |
unsigned int | getNumZ () const |
get the number of grid points along z-axis | |
const RDGeom::Point3D & | getOffset () const |
get the grid's offset | |
double | getSpacing () const |
get the grid's spacing | |
const RDKit::RealValueVect * | getOccupancyVect () const override |
return a const pointer to our occupancy vector | |
const std::vector< double > & | getData () const |
brief returns raw vector | |
std::vector< double > & | getData () |
bool | compareParams (const UniformRealValueGrid3D &other) const |
returns true if the grid other has parameters compatible with ours. | |
bool | compareVectors (const UniformRealValueGrid3D &other) const |
returns true if the grid other has the same values as ours. | |
bool | compareGrids (const UniformRealValueGrid3D &other) const |
returns true if the grid other has the same parameters and values as ours. | |
UniformRealValueGrid3D & | operator|= (const UniformRealValueGrid3D &other) |
calculates the union between the data on this grid and that on other . This grid is modified. NOTE that the grids must have the same parameters. | |
UniformRealValueGrid3D & | operator&= (const UniformRealValueGrid3D &other) |
calculates the intersection between the data on this grid and that on other . This grid is modified. NOTE that the grids must have the same parameters. | |
UniformRealValueGrid3D & | operator+= (const UniformRealValueGrid3D &other) |
calculates the sum of the data on this grid and that on other . This grid is modified. NOTE that the grids must have the same parameters. | |
UniformRealValueGrid3D & | operator-= (const UniformRealValueGrid3D &other) |
calculates the difference between the data on this grid and that on other . This grid is modified. NOTE that the grids must have the same parameters. | |
std::string | toString () const |
create and return a pickle | |
Public Member Functions inherited from RDGeom::Grid3D< RDKit::RealValueVect, double, double > | |
virtual | ~Grid3D () |
Definition at line 20 of file UniformRealValueGrid3D.h.
|
inline |
Definition at line 23 of file UniformRealValueGrid3D.h.
|
inline |
ctor
Definition at line 38 of file UniformRealValueGrid3D.h.
RDGeom::UniformRealValueGrid3D::UniformRealValueGrid3D | ( | const UniformRealValueGrid3D & | other | ) |
RDGeom::UniformRealValueGrid3D::UniformRealValueGrid3D | ( | const std::string & | pkl | ) |
construct from a string pickle
RDGeom::UniformRealValueGrid3D::UniformRealValueGrid3D | ( | const char * | pkl, |
unsigned int | |||
) |
construct from a text pickle
bool RDGeom::UniformRealValueGrid3D::compareGrids | ( | const UniformRealValueGrid3D & | other | ) | const |
returns true if the grid other
has the same parameters and values as ours.
bool RDGeom::UniformRealValueGrid3D::compareParams | ( | const UniformRealValueGrid3D & | other | ) | const |
returns true if the grid other
has parameters compatible with ours.
bool RDGeom::UniformRealValueGrid3D::compareVectors | ( | const UniformRealValueGrid3D & | other | ) | const |
returns true if the grid other
has the same values as ours.
|
inline |
Definition at line 118 of file UniformRealValueGrid3D.h.
|
inline |
brief returns raw vector
Definition at line 117 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
int RDGeom::UniformRealValueGrid3D::getGridIndex | ( | unsigned int | xi, |
unsigned int | yi, | ||
unsigned int | zi | ||
) | const |
get the index of the grid point given the x, y, z indices
void RDGeom::UniformRealValueGrid3D::getGridIndices | ( | unsigned int | idx, |
unsigned int & | xi, | ||
unsigned int & | yi, | ||
unsigned int & | zi | ||
) | const |
get the x, y, and z indices of a grid-point index
|
overridevirtual |
Get the index of the grid point closest to point.
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
|
overridevirtual |
get the location of the specified grid point
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
|
inline |
get the number of grid points along x-axis
Definition at line 97 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
inline |
get the number of grid points along y-axis
Definition at line 100 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
inline |
get the number of grid points along z-axis
Definition at line 103 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
inlineoverridevirtual |
return a const pointer to our occupancy vector
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
Definition at line 112 of file UniformRealValueGrid3D.h.
|
inline |
get the grid's offset
Definition at line 106 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
inlineoverridevirtual |
get the size of the grid (number of grid points)
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
Definition at line 84 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
inline |
get the grid's spacing
Definition at line 109 of file UniformRealValueGrid3D.h.
Referenced by RDMIF::calculateDescriptors().
|
overridevirtual |
Get the value at the grid point closest to the specified point.
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
|
overridevirtual |
Get the value at a specified grid point.
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
UniformRealValueGrid3D & RDGeom::UniformRealValueGrid3D::operator&= | ( | const UniformRealValueGrid3D & | other | ) |
calculates the intersection between the data on this grid and that on other
. This grid is modified. NOTE that the grids must have the same parameters.
UniformRealValueGrid3D & RDGeom::UniformRealValueGrid3D::operator+= | ( | const UniformRealValueGrid3D & | other | ) |
calculates the sum of the data on this grid and that on other
. This grid is modified. NOTE that the grids must have the same parameters.
UniformRealValueGrid3D & RDGeom::UniformRealValueGrid3D::operator-= | ( | const UniformRealValueGrid3D & | other | ) |
calculates the difference between the data on this grid and that on other
. This grid is modified. NOTE that the grids must have the same parameters.
UniformRealValueGrid3D & RDGeom::UniformRealValueGrid3D::operator= | ( | const UniformRealValueGrid3D & | other | ) |
UniformRealValueGrid3D & RDGeom::UniformRealValueGrid3D::operator|= | ( | const UniformRealValueGrid3D & | other | ) |
calculates the union between the data on this grid and that on other
. This grid is modified. NOTE that the grids must have the same parameters.
|
overridevirtual |
Set the value at the grid point closest to the specified point.
doesn't do anything if the point is outside the grid
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
|
overridevirtual |
Set the value at the specified grid point.
Implements RDGeom::Grid3D< RDKit::RealValueVect, double, double >.
std::string RDGeom::UniformRealValueGrid3D::toString | ( | ) | const |
create and return a pickle