Skip to main content

A suite of scripts that perform menial, tedious and repetitive tasks and operations on VASP files that were hurriedly and haphazardly put together by some intern.

Project description

Build Status Documentation Status

VASP Tools is a set of modules and scripts that automate routine tasks involving VASP files using a very intuitive CLI. The /scripts directory contains the scripts that implement the /vasp module to perform routine tasks on VASP files. This project is still a WIP and new scripts/modules will be added regularly over the next few weeks.

Requirements

As of now, this package is only supported on Python>=3.5. Since support for Python 2.7 is set to be pulled by 2020, updates in the near future extending support to Python<=3.0 seems unlikely.

The following libraries are required to run all the scripts and modules. - numpy - argparse - sympy - ujson - jsonschema - tabulate

For a full list of requirements, read requirements.txt. If not already present within the environment, they’ll be installed as dependencies during setup.

Installation

The installation process is quite simple, ensure you have a working version of Python>=3.5 installed and type the following into the console,

pip install vasp-tools

Any required libraries that aren’t installed in the current environment will be automatically installed. This will also automatically install the scripts and add them to $PATH for easy access.

Compatibility

The package, so far, was only tested within a Linux environment and isn’t officially compatible with Windows yet. The scripts can be compiled into executables using PyInstaller to work independently of python on any system, though it should be run in an environment with an identical OS. Use of VMs/Containers is suggested, though not tested as of yet.

Usage

The code present in /vasp can be imported in the form of standard modules. However, the primary purpose of this project was the creation of scripts (present in /scripts) to automate daily tasks faced by the Computational Chemist/Material Scientist. With this in mind, the scripts were designed to be extremely modular and user-friendly by implementing a `dplyr <https://style.tidyverse.org/pipes.html>`__-esque piping paradigm. For example, the process of:

  1. Importing a molecule from a POSCAR file.

  2. Rotating it into a certain configuration (90 degrees wrt the x-axis)

  3. Positioning it at a specified point above a crystal taken from another POSCAR file

  4. Fixing atomic positions within the crystal below a certain cutoff height

  5. Converting the coordinates to Direct from Cartesian or vice versa

  6. Save to a new POSCAR file.

can be implemented in a single line like so.

cat POSCAR1 | ./rotate.py -x 90 -y 10 | ./place-at.py "POSCAR2" 0.5 0.5 2.0 | ./fix-upto.py 10.0 | ./cart-direct > POSCARnew

Alternatively, you can also call each script individually or pass “POSCAR1” as one of the positional arguments. For example,

./place-at.py "POSCAR2" "POSCAR1" 0.5 0.5 2.0

is perfectly equivalent to

cat POSCAR1 | ./place-at.py "POSCAR2" 0.5 0.5 2.0

Detailed instructions on how to use the scripts are available in docs.


Written with `StackEdit <https://stackedit.io/>`__

History

0.1.0 (2019-07-19)

  • First release on PyPI.

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

vasp_tools-0.1.0.tar.gz (24.3 kB view details)

Uploaded Source

Built Distribution

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

vasp_tools-0.1.0-py2.py3-none-any.whl (18.6 kB view details)

Uploaded Python 2Python 3

File details

Details for the file vasp_tools-0.1.0.tar.gz.

File metadata

  • Download URL: vasp_tools-0.1.0.tar.gz
  • Upload date:
  • Size: 24.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for vasp_tools-0.1.0.tar.gz
Algorithm Hash digest
SHA256 b936a7d0962d70b386bd8828ed16f074e260d67ffa8748d462218820fd9a34d8
MD5 08f0fc700de59d8a99ce65c78bf43d48
BLAKE2b-256 20105aca5c5ca4890005d4a9d18ad71820945e966fa1c62b4a3110922d6e1f19

See more details on using hashes here.

File details

Details for the file vasp_tools-0.1.0-py2.py3-none-any.whl.

File metadata

  • Download URL: vasp_tools-0.1.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 18.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.28.1 CPython/3.7.1

File hashes

Hashes for vasp_tools-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 5a77b85e57e2d987d4e56abc92af4289a2f6f518216b45ab34234083c53f7581
MD5 89f3d8908201b73bf71030b10b2ed32d
BLAKE2b-256 413cf6eb794baae7ccf1b12a21309597cb652117485c60e529ca49f0e514b67a

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