A package for generating iterative SMARTS strings for forcefield atomtyping.
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
Table of Contents
This is an algorithm I made to dynamicly generate SMARTS molecule definitions for forcefield creation.
To get this package up and running follow these simple example steps.
This is an example of how to list things you need to use the software and how to install them.
- enviroment activation
conda env create -f enviroment.yml
conda activate SMARTREE
- package installation
git clone https://github.com/kierannp/SMARTREE.git
cd SMARTREE
pip install -e .
import networkx as nx
import mbuild as mb
import sTree
smiles = "C(CO)NCCO" # Diethanolamine
mol = mb.load(smiles, smiles=True) # converts the smiles into a mb.Compound
BG = mol.bond_graph # the bond graph of our molecule, atoms connected by bonds represented as a Set of source atom to destination atoms
depth = 2 # this parameter determines how large the smart tree should be generated, the larger the depth the more specific your SMARTS definition is, but the more expensive it is to atomtype
smarts_dict = sTree.bond_graph_to_smarts_dic(BG, depth) # returns our smarts in a dictionary with mb.Compound atoms as keys and the corresponding smarts as values
For more examples, please refer to the Documentation
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE.txt
for more information.
Kieran Nehil-Puleo - [email protected]
Project Link: https://github.com/kierannp/SMARTREE