Re: [Rdkit-discuss] Q2 2010 Release
On Wed, Jun 30, 2010 at 10:27 PM, Thomas Heller wrote: > > If it isn't too much work for you I would very much appreciate a python 2.5 > windows binary. I'll do a python 2.5 build next week. I have to remember how to set the environment up to use an alternate python compiler. :-) -greg -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Interacting with molecules in PyMOL
Dear James, Thanks for sending along the information about how you did the pymol steps; I'm sure it will be useful to others. Tighter RDKit-PyMol integration is definitely a good thing. Best Regards, -greg On Fri, Jul 2, 2010 at 8:09 PM, James Davidson wrote: > I just wanted to quickly update the List on how I've got on with this, in > case it is of use / interest to others. I followed Greg's advice and did > the following: > > 1. Exported molfile from PyMOL > 2. Read into RDKit > 3. Read in an SDF of already-constructed molecules based on the core (could > have built the products in RDKit, but the SDF was already available!) > 4. Iterated over the objects in the supplier to do the > AllChem.ConstrainedEmbed as discussed, then load the results into PyMOL > > NOTE - Because the molecules weren't built in RDKit, I couldn't rely on the > atom numbering when read into PyMOL (maybe this can't be relied on > anyway?). So I ran mol.GetSubstructMatch(core) for each molecule to get the > aligned product atom IDs that matched the core. I then flagged these in > PyMOL with flag 3 [Fixed Atoms (no movement allowed)] (flag 2 - harmonically > constrained may be better..?) so that I could subsequently run the mengine > 'clean' command in PyMOL to tidy-up the UFF output without allowing the > template to move: > > from rdkit import Chem > core = Chem.MolFromMolFile(mol_filepath) > supplier = Chem.SDMolSupplier(sdf_filepath) > for n,mol in enumerate(supplier): > mol = Chem.AddHs(mol) > newMol = AllChem.ConstrainedEmbed(mol, core, True) > name = "mol"+str(n) > fix = ','.join([str(n) for n in mol.GetSubstructMatch(core)]) > v.ShowMol(newMol, name=name, showOnly=False) > selection = '('+name+' and (id '+fix+'))' > v.server.do('flag 3, '+selection+', set') > > > Kind regards > > James > -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Interacting with molecules in PyMOL
I just wanted to quickly update the List on how I've got on with this, in case it is of use / interest to others. I followed Greg's advice and did the following: 1. Exported molfile from PyMOL 2. Read into RDKit 3. Read in an SDF of already-constructed molecules based on the core (could have built the products in RDKit, but the SDF was already available!) 4. Iterated over the objects in the supplier to do the AllChem.ConstrainedEmbed as discussed, then load the results into PyMOL NOTE - Because the molecules weren't built in RDKit, I couldn't rely on the atom numbering when read into PyMOL (maybe this can't be relied on anyway?). So I ran mol.GetSubstructMatch(core) for each molecule to get the aligned product atom IDs that matched the core. I then flagged these in PyMOL with flag 3 [Fixed Atoms (no movement allowed)] (flag 2 - harmonically constrained may be better..?) so that I could subsequently run the mengine 'clean' command in PyMOL to tidy-up the UFF output without allowing the template to move: from rdkit import Chem core = Chem.MolFromMolFile(mol_filepath) supplier = Chem.SDMolSupplier(sdf_filepath) for n,mol in enumerate(supplier): mol = Chem.AddHs(mol) newMol = AllChem.ConstrainedEmbed(mol, core, True) name = "mol"+str(n) fix = ','.join([str(n) for n in mol.GetSubstructMatch(core)]) v.ShowMol(newMol, name=name, showOnly=False) selection = '('+name+' and (id '+fix+'))' v.server.do('flag 3, '+selection+', set') Kind regards James __ PLEASE READ: This email is confidential and may be privileged. It is intended for the named addressee(s) only and access to it by anyone else is unauthorised. If you are not an addressee, any disclosure or copying of the contents of this email or any action taken (or not taken) in reliance on it is unauthorised and may be unlawful. If you have received this email in error, please notify the sender or postmas...@vernalis.com. Email is not a secure method of communication and the Company cannot accept responsibility for the accuracy or completeness of this message or any attachment(s). Please check this email for virus infection for which the Company accepts no responsibility. If verification of this email is sought then please request a hard copy. Unless otherwise stated, any views or opinions presented are solely those of the author and do not represent those of the Company. The Vernalis Group of Companies Oakdene Court 613 Reading Road Winnersh, Berkshire RG41 5UA. Tel: +44 118 977 3133 To access trading company registration and address details, please go to the Vernalis website at www.vernalis.com and click on the "Company address and registration details" link at the bottom of the page.. __-- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Interacting with molecules in PyMOL
Dear Greg, Thanks for your very rapid response - 'AllChem.ConstrainedEmbed' was just what I was looking for! Kind regards James __ PLEASE READ: This email is confidential and may be privileged. It is intended for the named addressee(s) only and access to it by anyone else is unauthorised. If you are not an addressee, any disclosure or copying of the contents of this email or any action taken (or not taken) in reliance on it is unauthorised and may be unlawful. If you have received this email in error, please notify the sender or postmas...@vernalis.com. Email is not a secure method of communication and the Company cannot accept responsibility for the accuracy or completeness of this message or any attachment(s). Please check this email for virus infection for which the Company accepts no responsibility. If verification of this email is sought then please request a hard copy. Unless otherwise stated, any views or opinions presented are solely those of the author and do not represent those of the Company. The Vernalis Group of Companies Oakdene Court 613 Reading Road Winnersh, Berkshire RG41 5UA. Tel: +44 118 977 3133 To access trading company registration and address details, please go to the Vernalis website at www.vernalis.com and click on the "Company address and registration details" link at the bottom of the page.. __ -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Interacting with molecules in PyMOL
Dear James, On Fri, Jul 2, 2010 at 3:05 PM, James Davidson wrote: > Dear All, > > I am trying to work out the best way to accomplish some tasks involving > RDKit, using PyMOL as an interface, and would appreciate some help. I would > like to be able to start from a PDB file of a ligand-bound crystal structure > loaded in PyMOL and be able to 'virtually' build some analogues - initially > just simple substitutions - and visually inspect the results. > > (1) So my first question is - having started PyMOL with the -R option, is > there an easy or recommended way of transferring molecules from PyMOL to > RDKit? I can accomplish this by writing molfiles to a temporary file, but > wondered if I am creating work, if eg RDKit could automatically create Mol > objects from non-biopolymer atoms in PyMol(?). ie it would be nice if: > > from rdkit import Chem > from rdkit.Chem import PyMol > v = PyMol.MolViewer() > > # Invented function to create an RDKit mol object > mol = v.GetAtomsAsMol(selection) The only way I currently know of to get molecule data out of pymol is to use the save command and a temporary file; one could create the function above on the basis of the fact that this command works without problems: v.server.do('save /tmp/blah.mol,(sele)') If there were sufficient demand for it, I'd guess that Jason would add (or arrange to have added) an option to the save command to make the results available as text instead of sending them to a file. It might be worth asking him. > (2) Once the ligand is converted to an RDKit mol object (by whatever means) > I want to enumrate some libraries of virtual products - eg choosing an atom > in PyMol as the attachment point, then running a set of reactions to get > products with a set of substituents added. In principle I think this is > quite straightforward; however, what I am struggling with is a mechanism to > 'freeze' the 3D coordintes of the original ligand atoms, but still be able > to use RDKit to generate sensible 3D positions for the newly added atoms so > that the products can be passed back to PyMOL and minimised in situ (if > required) using 'mengine.exe'. Am I looking at this the wrong way, and > should I actually try aligning the virtual products back on the starting > ligand conformation? Well, you may be looking at it the wrong way, but I've looked at it that way too, so we're at least wrong together. ;-) There is an underdocumented (where, in this case under == un) function that does part of what I believe you want in AllChem: #--- # start by getting a geometry for our core, for the purposes of the demo: [28]>>> core = Chem.MolFromSmiles('c1cc(C)cc2c1[nH]cc2') [29]>>> core = Chem.AddHs(core) [30]>>> AllChem.EmbedMolecule(core) Out[30] 0 [31]>>> AllChem.UFFOptimizeMolecule(core) Out[31] 0 # remove the Hs, otherwise we won't get a substruct match: [32]>>> core = Chem.RemoveHs(core) #--- # now generate the query molecule, with Hs : [34]>>> mol = Chem.MolFromSmiles('CCc1cc(C)cc2c1[n](C(=O)OC)cc2') [35]>>> mol = Chem.AddHs(mol) # do the constrained embedding: [37]>>> newMol=AllChem.ConstrainedEmbed(mol,core,True) # the molecule has a property with the RMS for the final alignment: [38]>>> mol.GetProp('EmbedRMS') Out[38] '0.0278532402393' # but we can also demonstrate that the geometries are similar by inspection: [39]>>> print Chem.MolToMolBlock(core) --> print(Chem.MolToMolBlock(core)) RDKit 3D 10 11 0 0 0 0 0 0 0 0999 V2000 -0.20381.6188 -0.4456 C 0 0 0 0 0 0 0 0 0 0 0 0 1.15381.2875 -0.3158 C 0 0 0 0 0 0 0 0 0 0 0 0 1.5492 -0.02450.0270 C 0 0 0 0 0 0 0 0 0 0 0 0 3.0012 -0.35020.2035 C 0 0 0 0 0 0 0 0 0 0 0 0 0.5703 -1.00780.2731 C 0 0 0 0 0 0 0 0 0 0 0 0 -0.7746 -0.65930.1391 C 0 0 0 0 0 0 0 0 0 0 0 0 -1.15070.6210 -0.2130 C 0 0 0 0 0 0 0 0 0 0 0 0 -2.50180.7120 -0.2748 N 0 0 0 0 0 0 0 0 0 0 0 0 -2.9792 -0.52290.0418 C 0 0 0 0 0 0 0 0 0 0 0 0 -1.9314 -1.39260.3038 C 0 0 0 0 0 0 0 0 0 0 0 0 1 2 2 0 2 3 1 0 3 4 1 0 3 5 2 0 5 6 1 0 6 7 2 0 7 8 1 0 8 9 1 0 9 10 2 0 7 1 1 0 10 6 1 0 M END [40]>>> print Chem.MolToMolBlock(Chem.RemoveHs(newMol)) --> print(Chem.MolToMolBlock(Chem.RemoveHs(newMol))) RDKit 3D 16 17 0 0 0 0 0 0 0 0999 V2000 0.04603.98870.5472 C 0 0 0 0 0 0 0 0 0 0 0 0 -0.48153.1257 -0.5989 C 0 0 0 0 0 0 0 0 0 0 0 0 -0.18791.6533 -0.4169 C 0 0 0 0 0 0 0 0 0 0 0 0 1.16681.2744 -0.3174 C 0 0 0 0 0 0 0 0 0 0 0 0 1.5491 -0.03640.0192 C 0 0 0 0 0 0 0 0 0 0 0 0 3.0001 -0.36510.2010 C 0 0 0 0 0 0 0 0 0 0 0 0 0.5630 -1.00
[Rdkit-discuss] Interacting with molecules in PyMOL
Dear All, I am trying to work out the best way to accomplish some tasks involving RDKit, using PyMOL as an interface, and would appreciate some help. I would like to be able to start from a PDB file of a ligand-bound crystal structure loaded in PyMOL and be able to 'virtually' build some analogues - initially just simple substitutions - and visually inspect the results. (1) So my first question is - having started PyMOL with the -R option, is there an easy or recommended way of transferring molecules from PyMOL to RDKit? I can accomplish this by writing molfiles to a temporary file, but wondered if I am creating work, if eg RDKit could automatically create Mol objects from non-biopolymer atoms in PyMol(?). ie it would be nice if: from rdkit import Chem from rdkit.Chem import PyMol v = PyMol.MolViewer() # Invented function to create an RDKit mol object mol = v.GetAtomsAsMol(selection) (2) Once the ligand is converted to an RDKit mol object (by whatever means) I want to enumrate some libraries of virtual products - eg choosing an atom in PyMol as the attachment point, then running a set of reactions to get products with a set of substituents added. In principle I think this is quite straightforward; however, what I am struggling with is a mechanism to 'freeze' the 3D coordintes of the original ligand atoms, but still be able to use RDKit to generate sensible 3D positions for the newly added atoms so that the products can be passed back to PyMOL and minimised in situ (if required) using 'mengine.exe'. Am I looking at this the wrong way, and should I actually try aligning the virtual products back on the starting ligand conformation? (3) Apologies that this last point is maybe a bit off-topic, but I wondered if anyone has an opinion as to whether MMTK is the way to go for 'simple' minimisations of modified ligands bound to proteins? (I don't have any real experience with MMTK... Kind regards James __ PLEASE READ: This email is confidential and may be privileged. It is intended for the named addressee(s) only and access to it by anyone else is unauthorised. If you are not an addressee, any disclosure or copying of the contents of this email or any action taken (or not taken) in reliance on it is unauthorised and may be unlawful. If you have received this email in error, please notify the sender or postmas...@vernalis.com. Email is not a secure method of communication and the Company cannot accept responsibility for the accuracy or completeness of this message or any attachment(s). Please check this email for virus infection for which the Company accepts no responsibility. If verification of this email is sought then please request a hard copy. Unless otherwise stated, any views or opinions presented are solely those of the author and do not represent those of the Company. The Vernalis Group of Companies Oakdene Court 613 Reading Road Winnersh, Berkshire RG41 5UA. Tel: +44 118 977 3133 To access trading company registration and address details, please go to the Vernalis website at www.vernalis.com and click on the "Company address and registration details" link at the bottom of the page.. __-- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] something new
Hi Adrian, On Fri, Jul 2, 2010 at 11:24 AM, Adrian Schreyer wrote: > That's great news indeed Greg! Thanks. > I want to migrate from MySQL to PostgreSQL once version 9.0 is > released and the rdkit cartridge will be very useful for my future > work. yeah, I'm looking forward to v9.0. I'm not sure how long it's going to take to get support for that into the cartridge, but it will clearly be a priority once v9.0 is out. > SMARTS support would be great as well. Do you intend on adding > things like MACCS keys and SMIRKS for transformations/reactions in the > future? MACCS keys would be pretty simple once the python code is ported to C++. That shouldn't be too much work; it's certainly worth a feature request (hint hint). SMIRKS is more difficult since the RDKit doesn't currently support true SMIRKS at all (instead it supports the Reaction SMARTS, which is something unique to the RDKit). I have SMIRKS support on the todo list already, but it may be a while before that happens. The general thought of adding reaction support to the cartridge is one we've talked about. It's do-able, but first we'd need to come up with a good idea of what types of searches should be supported and what the results should be. -greg -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] something new
That's great news indeed Greg! I want to migrate from MySQL to PostgreSQL once version 9.0 is released and the rdkit cartridge will be very useful for my future work. SMARTS support would be great as well. Do you intend on adding things like MACCS keys and SMIRKS for transformations/reactions in the future? Adrian On Fri, Jul 2, 2010 at 09:00, Riccardo Vianello wrote: > That's wonderful news. Congratulations and thank you and your > colleagues for all this work. > > Regards, > Riccardo > > -- > This SF.net email is sponsored by Sprint > What will you do first with EVO, the first 4G phone? > Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first > ___ > Rdkit-discuss mailing list > Rdkit-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rdkit-discuss > -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Help wanted: packaging the RDKit
On Fri, Jul 2, 2010 at 10:47 AM, Gianluca Sforna wrote: > On Fri, Jul 2, 2010 at 10:31 AM, Greg Landrum wrote: >> Do any of you have experience of this? > > I'm a Fedora package maintainer so I guess I can have a look at it. Thanks! That would be very cool. Let me know if there's any information you need or some way I can help. Best Regards, -greg -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Help wanted: packaging the RDKit
On Fri, Jul 2, 2010 at 10:31 AM, Greg Landrum wrote: > Do any of you have experience of this? I'm a Fedora package maintainer so I guess I can have a look at it. -- Gianluca Sforna http://morefedora.blogspot.com http://www.linkedin.com/in/gianlucasforna -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
[Rdkit-discuss] Help wanted: packaging the RDKit
Dear all, I think the RDKit is now in a reasonable state to consider creating packages for linux distributions (at least for ubuntu/debian and fedora). Unfortunately this isn't a process I know anything about. Do any of you have experience of this? Would you be willing to either do the packaging or at least help explain how it should be done? Thanks in advance for volunteers, -greg -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] something new
That's wonderful news. Congratulations and thank you and your colleagues for all this work. Regards, Riccardo -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
[Rdkit-discuss] something new
Dear all, I'm really excited to announce the most recent contribution from Novartis to the RDKit: a cartridge for similarity searching in PostgeSQL. The cartridge supports Tanimoto and Dice similarity for both bitmap and count-vector fingerprints and currently supports RDKit, layered, morgan (ECFP-like), atom-pair, and topological torsion fingerprinters. Adding a new fingerprinter (either using the RDKit or some other C/C++ library) is very straightforward. We make use of the PostgreSQL index system, so searches are fast. Our benchmarking work was done with a database of about 4 million drug-like compounds. Searching this database using drug-like molecules as queries and binary fingerprints typically takes around 4 seconds on a single CPU (these queries are returning 10s-1000s of results). I have no doubt that this can be made faster by tuning database parameters (the results here are for the standard PostgreSQL settings), but we're pretty happy with things already. The cartridge also allows substructure searching (using SMILES), but that's not as highly optimized as the similarity searching. We'll continue to work on this and will add SMARTS support in the future. The cartridge builds on linux and the mac. I don't plan to support it on Windows, but if someone else can get it working, I'd be happy to have someone else do so. As of this morning, the code is in svn: http://rdkit.svn.sourceforge.net/viewvc/rdkit/trunk/Code/PgSQL/rdkit/ There's a README that gives some build/install instructions (it's pretty easy), but I'll be adding additional information on the wiki on pages linked from here: http://code.google.com/p/rdkit/wiki/PostgresCartridge Nik Stiefl will be presenting a poster at the upcoming Sheffield conference that describes some of our work with and on open-source projects and that includes some details about the cartridge. If you happen to be in Sheffield, please swing by Nik's poster and check it out. This wouldn't have happened without the ideas and support provided by my colleague Andy Palmer. There are a lot of other people to acknowledge -- this isn't a project I could have done myself -- but rather than forgetting anyone I will hold off on trying to get the names down until the real release announcement is done. I will be writing more about this in the near future, and we'll probably be writing a paper about the whole story, but I wanted to give the community an initial heads up that the code is there. Best Regards, -greg -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Q2 2010 Release
Thank you very much Regards, Evgueni On 2 July 2010 07:11, Greg Landrum wrote: > Hi Evgueni, > > On Fri, Jul 2, 2010 at 8:06 AM, Evgueni Kolossov > wrote: > > > > Thank you very much. I understood I need to rebuild again to have all > > libraries in one place or copy them manually? > > If you get the new version of $RDBASE/Code/cmake/Modules/RDKitUtils.cmake > from here: > > http://rdkit.svn.sourceforge.net/viewvc/rdkit/trunk/Code/cmake/Modules/RDKitUtils.cmake?revision=1444 > then rerun cmake and re-open the rdkit solution, you should have an > INSTALL target. Building that target will copy the libraries to > $RDBASE/lib for you. > > Alternatively you can copy them manually, whichever you find easier. > > -greg > -- This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss