Re: [Rdkit-discuss] RDKit_minimal.js running out of memory
Hi David, Thank you for the advice! That solved the problem. Best, Adam David Cosgrove ezt írta (időpont: 2022. jan. 25., K, 22:05): > Hi Adam, > You need to delete the molecule once you’re done with it. It is beyond the > reach of the JS garbage collector. Add ‘mol.delete()’ at the end of the > loop to free the memory for the next round. > HTH, > Dave > > > On Tue, 25 Jan 2022 at 20:46, Ádám Baróthi wrote: > >> Hello everyone, >> >> I'm currently experimenting with the Javascript wrapper for RDKit, >> thinking that I could offload image generation and descriptor calculations >> to the client. >> I have a list of 1555 SMILES right now that I'm trying to convert to mol >> objects with RDKit.get_mol(), but after successfully processing about >> 700-800 molecules I get an "abort(OOM)" exception. Any further calls to >> get_mol() throw the same exception. The code is fairly basic: >> >> molecules = [] >> for (smi,idx of smiles_list.entries()) { >> mol = RDKit.get_mol(smi); >> //image = mol.get_svg(); >> //descriptors = JSON.parse(mol.get_descriptors()); >> //molecules[idx] = {'image': image, 'desc': descriptors}; >> } >> >> With this, I could process about 830 molecules. >> If I uncomment the lines, I could process about 700. >> >> I'm fairly new to JS development, so I'm not really sure what I'm doing >> wrong. >> >> Best, >> Adam >> ___ >> Rdkit-discuss mailing list >> Rdkit-discuss@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss >> > -- > David Cosgrove > Freelance computational chemistry and chemoinformatics developer > http://cozchemix.co.uk > > ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] Dask + Rdkit Use Cases
On 25/01/2022 01:57, Oren Herschander wrote: Hi Everyone, I'm working on a research project about how Dask and other python tools for distributed/parallel computing are used in Life Sciences. I'm on the lookout for use cases, stories, and overall thoughts that combine rdkit or other similar software with Dask. Emails are great, but if you have the time for a quick conversation those are a lot of fun too! :) In case you don't already know, Patrick Walters gave a try at dask to parallelize some python chemoinformatics and tells all about it here: https://patwalters.github.io/practicalcheminformatics/jupyter/dask/parallel/2021/03/28/dask-cheminformatics.html Thank you so much! I really appreciate the help! Cheers, Oren [1] Oren Herschander _Information__ Forager @ _https://coiled.io/ Links: -- [1] https://coiled.io ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
Re: [Rdkit-discuss] RDKit_minimal.js running out of memory
Hi Adam, You need to delete the molecule once you’re done with it. It is beyond the reach of the JS garbage collector. Add ‘mol.delete()’ at the end of the loop to free the memory for the next round. HTH, Dave On Tue, 25 Jan 2022 at 20:46, Ádám Baróthi wrote: > Hello everyone, > > I'm currently experimenting with the Javascript wrapper for RDKit, > thinking that I could offload image generation and descriptor calculations > to the client. > I have a list of 1555 SMILES right now that I'm trying to convert to mol > objects with RDKit.get_mol(), but after successfully processing about > 700-800 molecules I get an "abort(OOM)" exception. Any further calls to > get_mol() throw the same exception. The code is fairly basic: > > molecules = [] > for (smi,idx of smiles_list.entries()) { > mol = RDKit.get_mol(smi); > //image = mol.get_svg(); > //descriptors = JSON.parse(mol.get_descriptors()); > //molecules[idx] = {'image': image, 'desc': descriptors}; > } > > With this, I could process about 830 molecules. > If I uncomment the lines, I could process about 700. > > I'm fairly new to JS development, so I'm not really sure what I'm doing > wrong. > > Best, > Adam > ___ > Rdkit-discuss mailing list > Rdkit-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rdkit-discuss > -- David Cosgrove Freelance computational chemistry and chemoinformatics developer http://cozchemix.co.uk ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
[Rdkit-discuss] RDKit_minimal.js running out of memory
Hello everyone, I'm currently experimenting with the Javascript wrapper for RDKit, thinking that I could offload image generation and descriptor calculations to the client. I have a list of 1555 SMILES right now that I'm trying to convert to mol objects with RDKit.get_mol(), but after successfully processing about 700-800 molecules I get an "abort(OOM)" exception. Any further calls to get_mol() throw the same exception. The code is fairly basic: molecules = [] for (smi,idx of smiles_list.entries()) { mol = RDKit.get_mol(smi); //image = mol.get_svg(); //descriptors = JSON.parse(mol.get_descriptors()); //molecules[idx] = {'image': image, 'desc': descriptors}; } With this, I could process about 830 molecules. If I uncomment the lines, I could process about 700. I'm fairly new to JS development, so I'm not really sure what I'm doing wrong. Best, Adam ___ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss