Giter Club home page Giter Club logo

Comments (3)

tbereau avatar tbereau commented on August 31, 2024

Are you sure you only get this problem for this particular molecule? The problem looks similar to issue
#3.

from auto_martini.

shushanhe3 avatar shushanhe3 commented on August 31, 2024

Are you sure you only get this problem for this particular molecule? The problem looks similar to issue
#3.

Hi Tristan,

Yes I'm sure this problem only appears when the genMoleculesSMI fails to general any mol object for some particular SMI sequences. I tried a little debugging my self and have the script print out the sequence and the corresponding mol object. It turns out that for this particular molecule with smi "CC(Cn1cnc2c1ncnc2N)OCP(=O)(O)O", when it gets to the double ring part of the structure the genMoleculesSMI fails to generate a mol object. The printed message from one call of:

auto_martini --smi "CC(Cn1cnc2c1ncnc2N)OCP(=O)(O)O" --mol TFV

is shown as follows:

smi is: CC(Cn1cnc2c1ncnc2N)OCP(=O)(O)O
mol is: <rdkit.Chem.rdchem.Mol object at 0x7f7d6a1b02f0>
smi is: CC
mol is: <rdkit.Chem.rdchem.Mol object at 0x7f7d6a1b0600>
smi is: Cn1ccnc1
mol is: <rdkit.Chem.rdchem.Mol object at 0x7f7d6a1b0520>
[14:26:08] Can't kekulize mol. Unkekulized atoms: 0 1 2 3 4

smi is: c1cncn1
mol is: None
Traceback (most recent call last):
File "/home/shushan/opt/auto_martini-master/auto_martini", line 1229, in
ringAtomsFlat, True)
File "/home/shushan/opt/auto_martini-master/auto_martini", line 851, in printAtoms
molFrag = genMoleculeSMI(smiFrag)
File "/home/shushan/opt/auto_martini-master/auto_martini", line 96, in genMoleculeSMI
mol = Chem.AddHs(mol)
Boost.Python.ArgumentError: Python argument types in
rdkit.Chem.rdmolops.AddHs(NoneType)
did not match C++ signature:
AddHs(RDKit::ROMol mol, bool explicitOnly=False, bool addCoords=False, boost::python::api::object onlyOnAtoms=None, bool addResidueInfo=False)

Please let me know what you think might be causing the problem. Thank you so much for your help!

from auto_martini.

tbereau avatar tbereau commented on August 31, 2024

I see, yes that can happen sometimes where rdkit fails to analyze certain chemical groups. I would recommend you break it down to the (double)ring part that is problematic, and try first to parametrize a molecule that is very close but has few atom substitutions to bypass the problem. I suppose that replacing some of these n by c might do the trick.

from auto_martini.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.