No project description provided
Project description
Similarity based Molecular Generation (SiMGen)
SiMGen is a local similarity based molecular generation method. It uses a pretrained MACE model to generate local molecular descriptors and a time-dependent similarity kernel to generate new molecules.
SiMGen is available as an online web-tool at https://zndraw.icp.uni-stuttgart.de/.
Installation
The package can be installed using pip
:
pip install simgen
Note that the analysis code requires the rdkit package, which is not installed by default. To install it, run
pip install simgen[all]
Usage
There are two main ways to use the package: via a command line interface or interactively using ZnDraw.
Interactive use
We host an online gpu-powered web-tool at https://zndraw.icp.uni-stuttgart.de/. The documentation for the web-tool is available here.
However, you can also run ZnDraw locally. After installing the package, you can run the following command to start the web-tool:
zndraw --port 1234 PATH_TO_XYZ_FILE # Path is optional; Use --no-browser for remote servers
# Do the next command in a separate terminal
simgen connect --device cuda # default port is 1234
If you want to try out linker generation, add the --add-linkers
flag to the simgen connect
command.
Run simgen connect --help
for more information.
[!TIP] SiMGen uses the
mace-models
package to download data and the hydrogenation model. Downloading local copies can speed up your workflow. To do so, rungit clone https://github.com/RokasEl/MACE-Models cd MACE-Models dvc pull simgen init . # or simgen init /path/to/MACE-ModelsThis will set SiMGen's default path to the local MACE models.
CLI use
For unconstrained generation, you can use the following command:
python scripts/generate_mols_cli.py --save-path PATH_TO_SAVE_MOLS \
--num-molecules 10 \
--num-heavy-atoms 9 \
--track-trajectories \
--prior-gaussian-covariance 1. 1. 0.1 # controls the shape of the prior
To construct molecules with more complicated shapes, you will have to manually define the shape via a point cloud prior. See scripts/paper_examples/generate_macrocycles.py
for an example.
References
If you use SiMGen in your research, please cite the following paper:
License
The code is licensed under the MIT license. See LICENSE
for more information.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file simgen-0.1.tar.gz
.
File metadata
- Download URL: simgen-0.1.tar.gz
- Upload date:
- Size: 55.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cc3370380fac8c7f64a19e55f7099c36a54529dc2f6133f0bab6a93ed20d76b3 |
|
MD5 | 91027a5c640f17e922ee6b66fd7a39e7 |
|
BLAKE2b-256 | a709ed7861ab161fa804b9fc5ce1efa8ce07f8163b73b4bf4680c0fa6af09ac2 |
File details
Details for the file simgen-0.1-py3-none-any.whl
.
File metadata
- Download URL: simgen-0.1-py3-none-any.whl
- Upload date:
- Size: 52.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 72208115ca79b2975b767fbfdedd1765ca6cb71f7aaf081afb01433f292adbae |
|
MD5 | 8684794f6c30dd38c39d4869351aad49 |
|
BLAKE2b-256 | 1993aad2af958bec702e8049cb6f01adfb2ca02f249ea653f405361b46fe2069 |