.. include:: ../substitutions

.. oe:namespace:: OEGraphSim

.. meta::
   :keywords: OEGetFPOverlap

.. oe:function:: OEGetFPOverlap

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

      .. oe:api::

         OESystem::OEIterBase<OEChem::OEMatchBase>* OEGetFPOverlap(const OEChem::OEMolBase& qmol,
                                                                   const OEChem::OEMolBase& tmol,
                                                                   const OEFPTypeBase* fptype)

   .. oe:language:: python

      .. oe:api:: python

         OEGetFPOverlap(qmol: Union[OEGraphMol,OEMol,OEQMol],
                        tmol: Union[OEGraphMol,OEMol,OEQMol],
                        fptype: OEFPTypeBase) -> Iterable[OEMatchBase]

   Returns an iterator over all **unique** matches (common fragments) found
   between two molecules based on the given fingerprint type.
   This means that these common molecular fragments are mapped into
   the same bit when fingerprints are generated with the given type.

   *qmol, tmol*
      The two :ref:`OEMolBase <OEChem_OEMolBase>` objects from which the fingerprint
      overlap is generated.

   *fptype*
      The type of the fingerprint that also stores the parameters that
      are used when the fingerprint is generated.

   .. note::

      The :oe:func:`OEGraphSim::OEGetFPOverlap` function is not
      available for the :oe:const:`OEGraphSim::OEFPType::Lingo`
      fingerprint type.

   .. note::

      Two matches are considered to be equivalent only if they store the same
      sets of target and pattern atoms and bonds. The correspondence
      between the pattern and target atoms and bonds are not considered.

   .. seealso::

      * :ref:`chapter_overlap` chapter
      * :oe:func:`OEGraphSim::OEGetFPCoverage` function
      * :oe:func:`OEGraphSim::OEGetFPPatterns` function
