Socket
Book a DemoInstallSign in
Socket

moleculekit

Package Overview
Dependencies
Maintainers
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

moleculekit

A molecule reading/writing and manipulation package.

1.9.18
pipPyPI
Maintainers
2

MoleculeKit

Conda

A molecule manipulation library

Getting started

Installing moleculekit

With pip

pip install moleculekit

With conda

Installation Instructions

Using moleculekit in ipython

Install ipython in the correct conda enviroment using the following command.

pip install ipython

Now you can start an ipython console with

ipython

In the ipython console you can now import any of the modules of moleculekit and use it as normal.

from moleculekit.molecule import Molecule

mol = Molecule('3ptb')
mol.view()

API

For the official documentation of the moleculekit API head over to https://software.acellera.com/moleculekit/index.html

Issues

For any bugs or questions on usage feel free to use the issue tracker of this github repo.

Dev

If you are using moleculekit without installing it by using the PYTHONPATH env var you will need to compile the C++ extensions in-place with the following command:

python setup.py build_ext --inplace

Building for WebAssembly

Install emscripten https://emscripten.org/docs/getting_started/downloads.html

conda create -n pyodide-build
conda activate pyodide-build
conda install python=3.11
pip install pyodide-build==0.25.1

# Activate the emscripten environment
cd ../emsdk
./emsdk install 3.1.46
./emsdk activate 3.1.46
source emsdk_env.sh
cd -

# Build the package
export PYO3_CROSS_INCLUDE_DIR="HACK"
export PYO3_CROSS_LIB_DIR="HACK"
rm -rf .pyodide-xbuildenv
pyodide build -o dist_pyodide
cp dist_pyodide/*.whl test_wasm/wheels/
cd test_wasm
python3 -m http.server

If you get an error at building about numpy missing, check this issue https://github.com/pyodide/pyodide/issues/4347

Debugging segmentation faults in Cython part

  • Put a reproducible script in a file like segfault.py
  • Modify setup.py to have -g as compile flag instead of -O3
  • Recompile extensions with python setup.py build_ext --inplace
  • Execute script with gdb like gdb --args python segfault.py
  • Execute run and then bt 10 to show the backtrace
  • Have fun

Citing MoleculeKit

If you use this software in your publication please cite:

Stefan Doerr, Matthew J. Harvey, Frank Noé, and Gianni De Fabritiis. HTMD: High-throughput molecular dynamics for molecular discovery. Journal of Chemical Theory and Computation, 2016, 12 (4), pp 1845–1852. doi:10.1021/acs.jctc.6b00049

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.