interface between rdkit and ASE
Project description
rdkit2ase - Interface between the rdkit and ASE package.
Installation via pip install rdkit2ase
.
from rdkit2ase import rdkit2ase, ase2rdkit
atoms: ase.Atoms = rdkit2ase(mol)
mol = ase2rdkit(atoms)
from rdkit2ase import smiles2atoms
atoms: ase.Atoms = smiles2atoms("O")
print(atoms)
>>> Atoms(symbols='OH2', pbc=False)
Packmol Interface
If you have packmol (at least v20.15.0
) you
can use the rdkit2ase interface.
from rdkit2ase import pack, smiles2conformers
water = smiles2conformers("O", 2)
ethanol = smiles2conformers("CCO", 5)
density = 1000 # kg/m^3
box = pack([water, ethanol], [7, 5], density)
print(box)
>>> Atoms(symbols='C10H44O12', pbc=True, cell=[8.4, 8.4, 8.4])
Limitations
rdkit2ase.ase2rdkit
won't be able to detect higher order bonds.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
rdkit2ase-0.1.4.tar.gz
(7.9 kB
view hashes)
Built Distribution
Close
Hashes for rdkit2ase-0.1.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 79e7a8f920cf956886d3aef508b5afd549de7db3d2ac791ea237d40d2faefada |
|
MD5 | bdac2ae23024fef69df8acb5dfd11053 |
|
BLAKE2b-256 | a1119ec9e63dcd6d347c812fe3f0930c6e120133fe02d3ba668dc00704a903b3 |