Skip to main content

Useful tools for use with MBN Explorer simulations, files, and their analysis

Project description

MBN Tools

MBN Tools provides a set of utilities for running, processing, and analysing simulations with MBN Explorer.

Features

  • Run MBN Explorer simulations
    Run MBN Explorer simulation tasks directly from Python.

  • File handling utilities
    Create, read, modify, and convert simulation input/output files including .task, .xyz, .dcd, and.pdb.

  • Trajectory analysis
    Analyze simulation outputs, including radial distribution functions (RDF), mean squared displacement (MSD), RMSD, and more.

  • Crystallography utilities
    Group atoms by crystallographic planes, translate coordinates to planes, and remove atoms near simulation boundaries.

  • 3D visualisation
    Render atoms, planes, and simulation boxes in 3D using VisPy with customisable colours, sizes, and markers.

Installation

pip install MBN-tools

Usage

import MBN_tools as MBN
from MBN_tools import analysis, crystallography, visualise

# Run an MBN Explorer simulation
stdout, stderr = MBN.run_task("example.task", "/path/to/MBN_Explorer")

# Read an XYZ file
xyz_data = MBN.read_xyz("simulation.xyz")

# Compute RMSD
rmsd_values = analysis.calculate_rmsd(xyz_data, box_size=[50, 50, 100])

# Group atoms by a crystalline plane
planes = crystallography.group_atoms_by_plane(xyz_data, hkl=(1,1,0), tolerance=0.5)

# Visualize atoms in 3D
canvas = visualise.create_canvas()
visualise.draw_atoms(xyz_data['coordinates'], parent=canvas.central_widget.add_view())

Dependencies

  • numpy >= 1.26
  • scipy >= 1.12
  • mdtraj
  • vispy

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

mbn_tools-1.0.0.tar.gz (12.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mbn_tools-1.0.0-py3-none-any.whl (14.4 kB view details)

Uploaded Python 3

File details

Details for the file mbn_tools-1.0.0.tar.gz.

File metadata

  • Download URL: mbn_tools-1.0.0.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.0

File hashes

Hashes for mbn_tools-1.0.0.tar.gz
Algorithm Hash digest
SHA256 9ad6e2a46ebfc163b934856711d56a0719aaccf4461e7c675f1ef1b854910dd5
MD5 ff4ef4588b95e376510c4c66fecc75cd
BLAKE2b-256 02cffe7a6fdd934e0c8452b36c4f2b267d9a59be1a63a091388c5a7851330ff2

See more details on using hashes here.

File details

Details for the file mbn_tools-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: mbn_tools-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 14.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.0

File hashes

Hashes for mbn_tools-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1b763513ed8a6dab76e3fe8580bba406320042bec6735d5c1b01635297afa435
MD5 f73b34a7908c3d819e477664b3003a11
BLAKE2b-256 6c5130c67d2c24d1bb8a7a361770437ccfea08d7ec55dad3d74563f6e9e05e8b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page