GPU Accelerated Molecular Dynamics in Python
Project description
gamdpy [gam-dee-pai]
GPU Accelerated Molecular Dynamics in Python
Gamdpy implements molecular dynamics on GPU's in Python, relying heavily on the numba package (numba.org) which does JIT (Just-In-Time) compilation both to CPU and GPU (cuda). The gamdpy package being pure Python (letting numba do the heavy lifting of generating fast code) results in an extremely extendable package: simply by interjecting Python functions in the right places, the (experienced) user can extend most aspect of the code, including new integrators, new pair-potentials, new properties to be calculated during simulation, new particle properties, ...
Project is hosted here The Users Guide (gamdpy.readthedocs.io)
Overall structure of the package
1. Configuration
A class containing all relevant information about a configuration, including the simulation box (class sim_box).
- Vectors (r, v, f, etc): (N,D) float array storing D-dimensional vector for each particle
- Scalars (mass, kinetic energy, etc.): (N,) float array storing scalar for each particle
- sim_box (data describing box + functions implementing how to calculate distances and how to implement BC). For now:orthorombic (default) and lees_edwards
2. Integrators
Classes implementing a simulation algorithm. Currently implemented:
- class NVE
- class NVT : Nose-Hoover thermostat
- class NVT_Langevin
- class NPT_Atomic
- class NPT_Langevin
- class NVU_RT (Experimental)
Temperature/Pressure can be controlled by a user-supplied function, see examples/kablj.py
3. Interactions
Classes implementing interactions that can be applied to particles in the system:
- class PairPotential (stores potential parameters and the neighbour list to use (class NbList)
- fixed interactions (interactions known beforehand):
- bonds, angles, and dihedrals
- planar interactions: smooth walls, gravity, electric fields, ...
- point interactions, e.g., tethering
An interaction is responsible for keeping any internal datastructures up to date (in particular: class PairPotential is responsible for keeping its neighbor-list (class NbList up to date).
4. Runtime actions
Classes implementing actions on the configuration which are not related to the interactions or the integration of the equation of motion. These classes include momentum reset and savers.
- class TrajectorySaver
- class ScalarSaver
- class MomentumReset
5. Simulation
This class takes a Configuration, an Integrator, a (list of) Interaction(s) and a list of Runtime actions and sets up a simulation. Performing simulation is done by a method of this class.
6. Evaluator
Takes a Configuration and a (list of) Interaction(s), and evaluates properties and assign them to the appropiate fields in the configuration.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gamdpy-0.8.3.tar.gz.
File metadata
- Download URL: gamdpy-0.8.3.tar.gz
- Upload date:
- Size: 14.6 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9f9b344c8dc696066a9e10021efe9c9c5a8ba317860761588d6945903cf6b27f
|
|
| MD5 |
9e2520a9c5830c44633d8c38c9b9ce4d
|
|
| BLAKE2b-256 |
c61ddf244fa013d931d591f3721fdbcbfd4dec8c300e21f4961b0c80a8f3e39e
|
File details
Details for the file gamdpy-0.8.3-py3-none-any.whl.
File metadata
- Download URL: gamdpy-0.8.3-py3-none-any.whl
- Upload date:
- Size: 251.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
78ad78b9779b7c605d3ce83bc80ed771d497d4984ef8fe26fc222d7d7fa13515
|
|
| MD5 |
0823c98185498965c8462cbbbcddcf42
|
|
| BLAKE2b-256 |
9b75dedfb8b63e065cf3668fe900c1767735a1ec5383027f5978d81e19e86726
|