Skip to main content

Post-processing tools for particle simulations

Project description

Python post processing tools to compute static and dynamic correlation functions from particle simulations: - Real space: radial distribution function, mean square displacement, time-dependent overlap, … - Fourier space: structure factor, intermediate scattering function, dynamic susceptibility, …

This package relies on atooms to read trajectory files.

Quick start

Installation is easy (see Installation for more details)

pip install atooms-pp

We can now compute correlation functions from trajectories produced by particle simulation codes. Any trajectory format recognized by atooms can be processed, for instance most “xyz” files should work fine.

As an example, we compute the structure factor S(k) for the trajectory file trajectory.xyz contained in the data/ directory.

terminal

terminal

In the example above, we used 20% of the available time frames via the flag --norigins. Without it, atooms-pp applies an heuristics to determine the number of time frames required to achieve a reasonable data quality.

The results of the calculation are stored in data/trajectory.xyz.pp.sk. If the system is a mixture of different types of particles, say A and B, the program will create additional files for partial correlations, named trajectory.xyz.pp.sk.A-A, trajectory.xyz.pp.sk.B-B and trajectory.xyz.pp.sk.A-B.

The same calculation can be done from python:

from atooms.trajectory import Trajectory
import atooms.postprocessing as pp

with Trajectory('data/trajectory.xyz') as t:
     p = pp.StructureFactor(t)
     p.do()

Checkout the tutorial and notebook for more details.

Requirements

  • numpy

  • atooms

  • [optional] argh (only needed when using pp.py)

  • [optional] tqdm (enable progress bars)

  • [optional] argcomplete (enable tab-completion for pp.py)

Installation

If you cannot install the package system-wide, you can still install it in the user space. Either from pypi

pip install --user atooms-pp

or cloning the project repo

git clone https://gitlab.info-ufr.univ-montp2.fr/atooms/postprocessing.git
cd postprocessing
make user

The commands above will install pp.py under ~/.local/bin. Make sure this folder is in your $PATH. To install system-wide, sudo make install.

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

atooms-pp-1.0.0.tar.gz (29.3 kB view details)

Uploaded Source

File details

Details for the file atooms-pp-1.0.0.tar.gz.

File metadata

  • Download URL: atooms-pp-1.0.0.tar.gz
  • Upload date:
  • Size: 29.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/20.7.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/2.7.12

File hashes

Hashes for atooms-pp-1.0.0.tar.gz
Algorithm Hash digest
SHA256 32c4d2d3b1df3a752076ef846b4563d1d954ed1e9b75d81d74cc83f46d18dced
MD5 feda13d90a8d1afaf181028157a2b07b
BLAKE2b-256 1e6b0ade2e53375f11f68139ebea10a2df1109cce62b8dc5605df5c33ddb77d8

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