Chemical Data Processing Library Python API - Version 1.1.1
Public Member Functions | Static Public Attributes | Properties | List of all members
CDPL.MolProp.LogSCalculator Class Reference

LogSCalculator. More...

+ Inheritance diagram for CDPL.MolProp.LogSCalculator:

Public Member Functions

None __init__ ()
 Constructs the LogSCalculator instance.
 
None __init__ (LogSCalculator calc)
 Initializes a copy of the LogSCalculator instance calc. More...
 
None __init__ (Chem.MolecularGraph molgraph)
 Constructs the LogSCalculator instance and calculates the \( \log S \) of the molecular graph molgraph. More...
 
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
LogSCalculator assign (LogSCalculator calc)
 Replaces the current state of self with a copy of the state of the LogSCalculator instance calc. More...
 
float calculate (Chem.MolecularGraph molgraph)
 Calculates the \( \log S \) of the molecular graph molgraph. More...
 
float getResult ()
 Returns the result of the last \( \log S \) calculation. More...
 
Math.DVector getFeatureVector ()
 Returns the feature count vector of the last \( \log S \) calculation. More...
 

Static Public Attributes

int FEATURE_VECTOR_SIZE = 79
 Specifies the number of different features used by the \( \log S \) model.
 

Properties

 objectID = property(getObjectID)
 
 result = property(getResult)
 

Detailed Description

LogSCalculator.

See also
[LOGS]

Constructor & Destructor Documentation

◆ __init__() [1/2]

None CDPL.MolProp.LogSCalculator.__init__ ( LogSCalculator  calc)

Initializes a copy of the LogSCalculator instance calc.

Parameters
calcThe LogSCalculator instance to copy.

◆ __init__() [2/2]

None CDPL.MolProp.LogSCalculator.__init__ ( Chem.MolecularGraph  molgraph)

Constructs the LogSCalculator instance and calculates the \( \log S \) of the molecular graph molgraph.

The calculated \( \log S \) can be retrieved by a call to getResult().

Parameters
molgraphThe molecular graph for which to calculate the \( \log S \).

Member Function Documentation

◆ getObjectID()

int CDPL.MolProp.LogSCalculator.getObjectID ( )

Returns the numeric identifier (ID) of the wrapped C++ class instance.

Different Python LogSCalculator instances may reference the same underlying C++ class instance. The commonly used Python expression a is not b thus cannot tell reliably whether the two LogSCalculator instances a and b reference different C++ objects. The numeric identifier returned by this method allows to correctly implement such an identity test via the simple expression a.getObjectID() != b.getObjectID().

Returns
The numeric ID of the internally referenced C++ class instance.

◆ assign()

LogSCalculator CDPL.MolProp.LogSCalculator.assign ( LogSCalculator  calc)

Replaces the current state of self with a copy of the state of the LogSCalculator instance calc.

Parameters
calcThe LogSCalculator instance to copy.
Returns
self

◆ calculate()

float CDPL.MolProp.LogSCalculator.calculate ( Chem.MolecularGraph  molgraph)

Calculates the \( \log S \) of the molecular graph molgraph.

Parameters
molgraphThe molecular graph for which to calculate the \( \log S \).
Returns
The calculated \( \log S \) of the molecular graph molgraph.

◆ getResult()

float CDPL.MolProp.LogSCalculator.getResult ( )

Returns the result of the last \( \log S \) calculation.

Returns
The result of the last \( \log S \) calculation, or zero if a calculation has not yet been performed.

◆ getFeatureVector()

Math.DVector CDPL.MolProp.LogSCalculator.getFeatureVector ( )

Returns the feature count vector of the last \( \log S \) calculation.

The occurrence count of a particular structural feature can be retrieved from the returned vector via its feature index. The feature index correspond to the numerical identifier of the feature's definition in the original publication [LOGS].

Returns
The feature count vector of the last \( \log S \) calculation.
Note
The returned feature vector is of size LogSCalculator.FEATURE_VECTOR_SIZE.