On 07/11/2016 12:37, Axel Pahl wrote:
>
> amongst other options, I can generate an RDKit mol object by one of
> these two ways:
>
> mol1 = Chem.MolFromSmiles(<valid Smiles>)
> mol2 = Chem.MolFromSmarts(<valid Smarts>)
>
> Is there a possibility to detect for a given mol object whether it was
> generated from Smiles or Smarts?
Not obviously to me.
Perhaps you can do something like this at creation time:
mol2.SetProp('origin', 'SMARTS')
then use mol.GetProp('origin') when you need to do the test (inside a
try/except KeyError).
Paul.
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Rdkit-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss