.. oe:namespace:: OEShape

.. meta::
   :keywords: OEBestOverlayScore, BestOverlayScore


.. _OEShape_OEBestOverlayScore:

.. oe:class:: OEBestOverlayScore

   .. oe:api::


      class OEBestOverlayScore : public OEOverlapResults

   This class extends the :ref:`OEOverlapResults <OEShape_OEOverlapResults>` to represent the results of
   a single overlay optimization between a reference and a fit object.

   The following methods are publicly inherited from :ref:`OEOverlapResults <OEShape_OEOverlapResults>`:
    * :oe:meth:`GetColorScore<OEShape::OEOverlapResults::GetColorScore>`
    * :oe:meth:`GetColorTanimoto<OEShape::OEOverlapResults::GetColorTanimoto>` 
    * :oe:meth:`GetColorTversky<OEShape::OEOverlapResults::GetColorTversky>`
    * :oe:meth:`GetFitColorTversky<OEShape::OEOverlapResults::GetFitColorTversky>` 
    * :oe:meth:`GetFitSelfColor<OEShape::OEOverlapResults::GetFitSelfColor>`
    * :oe:meth:`GetFitSelfOverlap<OEShape::OEOverlapResults::GetFitSelfOverlap>`
    * :oe:meth:`GetFitTversky<OEShape::OEOverlapResults::GetFitTversky>` 
    * :oe:meth:`GetFitTverskyCombo<OEShape::OEOverlapResults::GetFitTverskyCombo>`
    * :oe:meth:`GetOverlap<OEShape::OEOverlapResults::GetOverlap>`
    * :oe:meth:`GetRefColorTversky<OEShape::OEOverlapResults::GetRefColorTversky>` 
    * :oe:meth:`GetRefSelfColor<OEShape::OEOverlapResults::GetRefSelfColor>`
    * :oe:meth:`GetRefSelfOverlap<OEShape::OEOverlapResults::GetRefSelfOverlap>`
    * :oe:meth:`GetRefTversky<OEShape::OEOverlapResults::GetRefTversky>` 
    * :oe:meth:`GetRefTverskyCombo<OEShape::OEOverlapResults::GetRefTverskyCombo>`
    * :oe:meth:`GetTanimoto<OEShape::OEOverlapResults::GetTanimoto>`
    * :oe:meth:`GetTanimotoCombo<OEShape::OEOverlapResults::GetTanimotoCombo>` 
    * :oe:meth:`GetTversky<OEShape::OEOverlapResults::GetTversky>`

   The :ref:`OEBestOverlayScore <OEShape_OEBestOverlayScore>` class defines the following public methods:
    * :oe:meth:`GetFitConfIdx<OEShape::OEBestOverlayScore::GetFitConfIdx>`
    * :oe:meth:`GetRefConfIdx<OEShape::OEBestOverlayScore::GetRefConfIdx>` 
    * :oe:meth:`GetRotMatrix<OEShape::OEBestOverlayScore::GetRotMatrix>`
    * :oe:meth:`GetTranslation<OEShape::OEBestOverlayScore::GetTranslation>` 
    * :oe:meth:`Transform<OEShape::OEBestOverlayScore::Transform>`
    
   .. oe:method:: Constructors

      .. oe:language:: c++ java csharp

         .. oe:api::

            OEBestOverlayScore()
            OEBestOverlayScore(const OEBestOverlayScore&)

      .. oe:language:: python

         .. oe:api:: python

            OEBestOverlayScore() -> OEBestOverlayScore
            OEBestOverlayScore(rhs: OEBestOverlayScore) -> OEBestOverlayScore

      Default and copy constructors.

   .. oe:method:: operator=
      :language: c++

      .. oe:api::

         OEBestOverlayScore &operator=(const OEBestOverlayScore&)

      Assignment operator.


   .. oe:method:: GetFitConfIdx

      .. oe:language:: c++ java csharp

         .. oe:api::

            unsigned int GetFitConfIdx() const

      .. oe:language:: python

         .. oe:api:: python

            GetFitConfIdx() -> int

      Returns the conformer index of the fit conformer.

   .. oe:method:: GetRefConfIdx

      .. oe:language:: c++ java csharp

         .. oe:api::

            unsigned int GetRefConfIdx() const

      .. oe:language:: python

         .. oe:api:: python

            GetRefConfIdx() -> int

      Returns the conformer index of the reference conformer.

   .. oe:method:: GetRotMatrix

      .. oe:language:: c++ java csharp

         .. oe:api::

            void GetRotMatrix(float*) const

      .. oe:language:: python

         .. oe:api:: python

            GetRotMatrix(rmat: OEFloatArray) -> None

      Returns the rotation matrix to be applied on the fit conformer to obtain the optimized overlay.
      Using the OpenEye convention, rotation should be applied before the translation.

   .. oe:method:: GetTranslation

      .. oe:language:: c++ java csharp

         .. oe:api::

            void GetTranslation(float*) const

      .. oe:language:: python

         .. oe:api:: python

            GetTranslation(trans: OEFloatArray) -> None

      Returns the translation vector to be applied on the fit conformer to obtain the optimized overlay.
      Using the OpenEye convention, rotation should be applied before the translation.

   .. _OEShape_OEBestOverlayScore_Transform:

   .. oe:method:: Transform

      .. oe:language:: c++ java csharp

         .. oe:api::

            bool Transform(OEChem::OEMolBase& mol) const
            bool Transform(OEChem::OEConfBase& conf) const
            bool Transform(OESystem::OEScalarGrid& grid) const

      .. oe:language:: python

         .. oe:api:: python

            Transform(mol: Union[OEGraphMol,OEMol,OEQMol]) -> bool
            Transform(mol: OEConfBase) -> bool
            Transform(grid: OEScalarGrid) -> bool

      Transforms the molecule to the optimized overlay position.
