Make QSAR model with PyG and pytorch2.0 #RDKit #Chemoinfo

Recently, I updated version of pytorch on my env from 1.x to 2.0. I think it’s worth to update because, original site says…. PYTORCH 2.X: FASTER, MORE PYTHONIC AND AS DYNAMIC AS EVER Today, we announce torch.compile, a feature that pushes PyTorch performance to new heights and starts the move for parts of PyTorch from C++Continue reading “Make QSAR model with PyG and pytorch2.0 #RDKit #Chemoinfo”

Generate molecules with Link-invent #RDKit #RINVENT #chemoinformatics

General molecular generator with deep learning approach is difficult to fix substructure. But common SAR expansion by medchem is focus on specific part such as terminal part, core and linker. Linker is defined as a part which connect parts of molecules. Linker is important of drug design and is called scaffold when the linker connetsContinue reading “Generate molecules with Link-invent #RDKit #RINVENT #chemoinformatics”

Compound Generator with Graph Networks, GraphINVENT take2 #chemoinformatics #RDKit #PyTorch

I posted about graph based compound generator named ‘GraphINVENT’ some days ago. https://wordpress.com/block-editor/post/iwatobipen.wordpress.com/3450 Fortunately I could get response from author and could get useful information about their model. The hyperparameter of the model is very important and difficult to optimize but I could get suitable learning rate to train the GDB-13 small set. I changedContinue reading “Compound Generator with Graph Networks, GraphINVENT take2 #chemoinformatics #RDKit #PyTorch”

Compound Generator with Graph Networks, GraphINVENT #chemoinformatics #RDKit #PyTorch

Here is a new article from Esben et. al. about de novo compound generator with graph network which is named GraphINVENT. Graph based approach has advantage for compound generation compared to SMILES based approach. It doesn’t need to learn grammar of SMILES. Graph approach represents molecule as graph, atom is node and bond is edge.Continue reading “Compound Generator with Graph Networks, GraphINVENT #chemoinformatics #RDKit #PyTorch”

Replace core with DeLinker #RDKit #Chemoinformatics #DeepLearning

In the FBDD projects, fragment linking strategy is very easy to understand about the strategy but it is difficult to linking two fragments in the real world I think. There are many tools for linking fragments in virtually. These tools are used not only be applied to FBDD but also scaffold hopping etc. There areContinue reading “Replace core with DeLinker #RDKit #Chemoinformatics #DeepLearning”

Example code of DGL for chemoinformatics task #DGL #chemoinformatics #RDKit #memo

There are many publications about graph based approach for chemoinformatics area. I can’t cover all of them but still have interest these area. I think pytorch_geometric (PyG) and deep graph library (DGL) are very attractive and useful package for chemoinformaticians. I wrote some posts about DGL and PyG. Recent DGL is more chemoinformatics friendly soContinue reading “Example code of DGL for chemoinformatics task #DGL #chemoinformatics #RDKit #memo”

Particle Swarm Optimization for molecular design #RDKit #Chemoinformatics

I participated RDKit UGM last week. It was worth to go I think. And in the meeting I got useful information for de novo molecular design. You can find the slide deck following URL. https://github.com/rdkit/UGM_2019/blob/master/Presentations/Montanari_Winter_Utilizing_in_silico_models.pdf They used Particle Swarm Optimization(PSO) for de novo molecular design. PSO is very simple method for parameter optimization. Details areContinue reading “Particle Swarm Optimization for molecular design #RDKit #Chemoinformatics”

Transfer learning of DGMG for focused library gegneration #DGL #Chemoinformatics

Transfer learning is very useful method in deeplearning. Because it can use pre trained model and can re train with few parameters. I think it is useful for molecular generator too. If it is useful for the generator, it can use for focused library generation. I posted about DGL molecular generation. So I tried toContinue reading “Transfer learning of DGMG for focused library gegneration #DGL #Chemoinformatics”

Molecular encoder/decoder (VAE) with python3.x (not new topic) #rdkit #chemoinformatics

The first day of 10-day holiday is rainy. And I and my kid will go to dodge ball tournament. Two years ago, I tried to modify the keras-molecule which is code of molecular encoder decoder. The code is written for python 2.x. So I would like to run the code on python 3.6. I stoppedContinue reading “Molecular encoder/decoder (VAE) with python3.x (not new topic) #rdkit #chemoinformatics”

Try GCN QSPR with pytorch based graph library #RDKit #Pytorch #dgl

Recently many machine learning articles use pytorch for their implementation. And I found very attractive package for graph based deep learning, named ‘DGL;Deep Graph Library’. The package supports pytorch and mxnet for backend. The author provides not only package but also very nice documentation. I read the document and try GCN for QSPR with DGL.Continue reading “Try GCN QSPR with pytorch based graph library #RDKit #Pytorch #dgl”

mol encoder with Pytorch

Variable Auto Encoder (VAE) is unique method that is used for learning latent representations. VAE encodes discriminative vector to continuous vector in latent space. There are lots of examples in github. In 2016, Alán Aspuru-Guzik reported new de novo design method by using VAE. The approach represents molecules as SMLIES and SMILES strings are convertedContinue reading “mol encoder with Pytorch”

Build QSAR model with pytorch and rdkit #RDKit

There are many frameworks in python deeplearning. For example chainer, Keras, Theano, Tensorflow and pytorch. I have tried Keras, Chainer and Tensorflow for QSAR modeling. And I tried to build QSAR model by using pytorch and RDKit. You know, pytorch has Dynamic Neural Networks “Define-by-Run” like chainer. I used solubility data that is provided fromContinue reading “Build QSAR model with pytorch and rdkit #RDKit”

Can machine learn important feature from SMILES?

Today I found challenging article in arxiv. It describes about SMILES2Vec. https://arxiv.org/pdf/1712.02034.pdf You know word2vec is very attractive and major application for ML area and SMILES2Vec has same concept. It converts smiles to vector and learn which character is important. The author use “black box” models for building model. I am not sure about “blackContinue reading “Can machine learn important feature from SMILES?”

molecule encoder/decoder in deepchem #rdkit #deepchem

Today I updated deepchem in my mac. It was easy to install new version of deepchem on Mac. That’s all. ;-) New version of deepchem is implemented MoleculeVAE. MoeculeVAE generates new molecules by using pre defined model. Deepchem can use pre defined model that was trained with Zinc Dataset. OK let’s run the code. IContinue reading “molecule encoder/decoder in deepchem #rdkit #deepchem”

Graph convolution classification with deepchem

I posted about graph convolution regression using deepchem. And today, I tried graph convolution classification using deepchem. Code is almost same as regression model. The only a difference point is use dc.models.MultitaskGraphClassifier instead of dc.models.MultitaskGraphRegressor. I got sample ( JAK3 inhibitor ) data from chembl and tried to make model. At first I used pandasContinue reading “Graph convolution classification with deepchem”

Build regression model in Keras

I introduced Keras in mishimasyk#9. And my presentation was how to build classification model in Keras. A participant asked me that how to build regression model in Keras. I could not answer his question. After syk#9, I searched Keras API and found good method. Keras has Scikit-learn API. The API can build regression model. ;-)Continue reading “Build regression model in Keras”

RemoteMonitor in keras

There are several packages to perform deep learning in python. And my favorite one is keras. https://keras.io/ Today, I found new function in keras.callbacks named RemoteMonitor. The function provide real time visualization of learning. So, I wrote very simple example using IRIS dataset. At first to use RemoteMonitor, I need clone api from following URL.Continue reading “RemoteMonitor in keras”

Use convolution2D in QSAR.

Recently there are lots of report about deep learning to predict biological activity(QSAR). I think almost of these predictors use MLP. I wonder if I could use another method like 2DCNN, I could get good predictor. So, I tried to build 2DCNN QSAR model. Fortunately, 1024 bit fingerprint is easily convert to 2D 32 xContinue reading “Use convolution2D in QSAR.”

Callback function of keras.

I’m still building QSAR models using deep learning. And I thought I got problem of over fitting. :-) Training error was decreasing but, validation error was increasing depend on number of epochs. :-/ It seems over fitting and I could not avoid the event even if I used drop out function. Tried lots of learningContinue reading “Callback function of keras.”

New library for deep learning

Deep learning is old but new technology of machine learning. I have been interested in this technology however it was difficult to optimise lots of parameters. I posted on my blog about python library named ‘chainer’ before. Chainer is one of flexible frame work for NN. And somedays ago, I found new library named ‘keras’Continue reading “New library for deep learning”