Loading...
Searching...
No Matches
ShapeEncoder.h
Go to the documentation of this file.
//
// Copyright (C) 2005-2025 Greg Landrum and other RDKit contributors
//
// @@ All Rights Reserved @@
// This file is part of the RDKit.
// The contents are covered by the terms of the BSD license
// which is included in the file license.txt, found at the root
// of the RDKit source tree.
//
#pragma once
#include <RDGeneral/export.h>
#ifndef RD_SHAPE_ENCODER_H_20050125_0800
#define RD_SHAPE_ENCODER_H_20050125_0800
namespace RDGeom {
class UniformGrid3D;
class Transform3D;
} // namespace RDGeom
namespace RDKit {
class ROMol;
class Conformer;
namespace MolShapes {
//! Encode the shape of a molecule on to a grid
/*!
\param mol The molecule of interest
\param grid Grid onto which the molecule is encoded
\param confId Id of the conformation on the molecule to be encoded
\param trans Optional 3D transform to be applied to this conformation
\param vdwScale Scaling factor for the radius of the atoms to determine the
base radius
used in the encoding - grid points inside this sphere carry
the maximum occupancy
\param stepSize thickness of the layers outside the base radius, the
occupancy value is decreased
from layer to layer from the maximum value
\param maxLayers the maximum number of layers - defaults to the number allowed
the number of bits
use per grid point - e.g. two bits per grid point will allow
3 layers
\param ignoreHs if true, ignore the hydrogen atoms in the shape encoding
process
*/
RDKIT_SHAPEHELPERS_EXPORT void EncodeShape(
const ROMol &mol, RDGeom::UniformGrid3D &grid, int confId = -1,
const RDGeom::Transform3D *trans = nullptr, double vdwScale = 0.8,
double stepSize = 0.25, int maxLayers = -1, bool ignoreHs = true);
//! Emcode the shape of a conformer on to a grid
/*!
\param conf The conformer of interest
\param grid Grid onto which the molecule is encoded
\param trans Optional 3D transform to be applied to this conformation
\param vdwScale Scaling factor for the radius of the atoms to determine the
base radius
used in the encoding - grid points inside this sphere carry
the maximum occupancy
\param stepSize thickness of the layers outside the base radius, the
occupancy value is decreased
from layer to layer from the maximum value
\param maxLayers the maximum number of layers - defaults to the number allowed
the number of bits
use per grid point - e.g. two bits per grid point will allow
3 layers
\param ignoreHs if true, ignore the hydrogen atoms in the shape encoding
process
*/
RDKIT_SHAPEHELPERS_EXPORT void EncodeShape(
const Conformer &conf, RDGeom::UniformGrid3D &grid,
const RDGeom::Transform3D *trans = nullptr, double vdwScale = 0.8,
double stepSize = 0.25, int maxLayers = -1, bool ignoreHs = true);
} // namespace MolShapes
} // namespace RDKit
#endif
RDGeom::Transform3D
Definition Transform3D.h:23
RDGeom::UniformGrid3D
Definition UniformGrid3D.h:20
RDKit::Conformer
The class for representing 2D or 3D conformation of a molecule.
Definition Conformer.h:46
RDKit::ROMol
Definition ROMol.h:319
export.h
RDKIT_SHAPEHELPERS_EXPORT
#define RDKIT_SHAPEHELPERS_EXPORT
Definition export.h:529
RDGeom
Definition TorsionAngleContribs.h:17
RDKit::MolShapes
Definition ShapeEncoder.h:23
RDKit::MolShapes::EncodeShape
RDKIT_SHAPEHELPERS_EXPORT void EncodeShape(const ROMol &mol, RDGeom::UniformGrid3D &grid, int confId=-1, const RDGeom::Transform3D *trans=nullptr, double vdwScale=0.8, double stepSize=0.25, int maxLayers=-1, bool ignoreHs=true)
Encode the shape of a molecule on to a grid.
RDKit
Std stuff.
Definition Abbreviations.h:19