Skip to main content
Yanked

This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Consider using release 0.0.10 instead.

pyvasptools

Provides Python scripts for analyzing the:

  • Radial distribution function (RDF) — calculated directly from VASP structure files (POSCAR)
  • Density of states (DOS) — calculated directly from VASP output files (vaspout.h5)
  • Crystal orbital Hamilton population analysis — analyzed beforehand with LOBSTER
  • Electron localization function partitioning — analyzed beforehand with critic2

Installation

Requires Python ≥ 3.10.14.

  1. Create a Python environment to isolate the package dependencies:

    python3 -m venv ~/envs/pyvasp_tools
    
  2. Activate the Python environment:

    source ~/envs/pyvasp_tools/bin/activate
    
  3. Install the package from PyPI:

    pip install pyvasptools
    

    Or install from a local clone (for development):

    cd /path/to/pyvasptools/
    pip install .
    

Sample data

The example VASP outputs used by the tests and demos are too large for git and are hosted on Zenodo: https://doi.org/10.5281/zenodo.22182966

Download the archive and unzip its contents into the repository root so that a sample_data/ folder sits next to this README:

cd /path/to/pyvasptools/
# download sample_data.zip from the Zenodo record above, then:
unzip sample_data.zip

Example - Density of States calculated from ab initio molecular dynamics (AIMD) simulation VASP output files

from pyvasptools.dataset import *
from pyvasptools.dos.dos import *  
from pyvasptools.compound import * 

current_dir = Path(__file__).parent
root_dir = current_dir.parents[1]

# 1. Sample data set 1: Compare the density of states of two (100)-NbTaMoW and (100)-NbTaMoWV slabs 
NbTaMoW = Dataset(path=root_dir / 'sample_data/NbTaMoW/10ps/DOS', lc='black', label='NbTaMoW')
NbTaMoWV = Dataset(path=root_dir / 'sample_data/NbTaMoWV/10ps/DOS', lc='purple', label='NbTaMoWV')

# 1. Plot the total density of states of a single (100)-NbTaMoW alloy
NbTaMoW.plot_total_DOS(output_dir=current_dir, output_name='DOS_NbTaMoW')
# 2. Zoom in near the Fermi level (zoom_in=True)
NbTaMoW.plot_total_DOS(output_dir=current_dir, zoom_in=True, output_name='DOS_NbTaMoW_Fermi')

# 3. Compare the density of states of two (100)-NbTaMoW and (100)-NbTaMoWV slabs. zoom_in=True zooms in close to the Fermi level. 
plot_multi_overlaid_dos(NbTaMoW, NbTaMoWV, zoom_in=True, output_dir=current_dir, output_name='DOS_NbTaMoW_vs_NbTaMoWV')



# 3. Now compare the partial density of states of a NbTaMoW-H2O-FLiBe and NbTaMoWV-H2O-FLiBe interface. 
elements = ['Nb', 'Ta', 'Mo', 'W', 'F']

NbTaMoW = Dataset(path=root_dir / 'sample_data/NbTaMoW-FLiBe/10ps/DOS', lc="blue", ls="solid", label=f'')
NbTaMoWV = Dataset(path=root_dir / 'sample_data/NbTaMoWV-FLiBe/10ps/DOS', lc="purple", ls="solid", label=f'V')

plot_pdos_modified(elements, {'d': 'solid', 'p': 'dashed', 's': 'dotted'}, NbTaMoW, NbTaMoWV, x_lim=(-10, 10), y_lim=(((-5, 100),) + ((-1, 20),) * 4 + ((-5, 50),)), labels=("", "V"), path_to_fig=current_dir / 'pDOS_NbTaMoW_vs_NbTaMoWV')

The script above produces the following plots (see tests/dos/):

1. Total DOS of a single NbTaMoW alloy

Total DOS of NbTaMoW

2. Same DOS, zoomed in near the Fermi level

DOS of NbTaMoW near the Fermi level

3. Total DOS of NbTaMoW vs. NbTaMoWV

DOS of NbTaMoW vs NbTaMoWV

4. Partial DOS of the NbTaMoW-FLiBe vs. NbTaMoWV-FLiBe interfaces

Partial DOS of NbTaMoW vs NbTaMoWV

Metadata

Release files for pyvasptools 0.0.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyvasptools 0.0.7
File Size Uploaded
pyvasptools-0.0.7.tar.gz 18.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyvasptools 0.0.7
File Interpreter ABI Platform
pyvasptools-0.0.7-py3-none-any.whl Python 3 none any Details

Total release size: 39.0 kB

Release files / pyvasptools-0.0.7.tar.gz

Download URL pyvasptools-0.0.7.tar.gz
Size 18.0 kB
Tags Source
SHA-256 checksum
How to use checksums
891848bf41c8bb2930a7b3501e264b4f3e51b8bcf62d5dd576e39491f156a00e
BLAKE2b-256 checksum
How to use checksums
44245d0dcb6e2ca5c286d184e1f7817224ca217d9a33eac7dc06481fe3c11f95
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.14

Release files / pyvasptools-0.0.7-py3-none-any.whl

Download URL pyvasptools-0.0.7-py3-none-any.whl
Size 20.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7361f0c7e87128e63d046ae0ac3f52c6ce1e7cbc76e477684ef17023fbcc7b91
BLAKE2b-256 checksum
How to use checksums
7ad8d94df0f71516026858eb60596cd4e884475aab7444fc327c3c85426d1c12
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.10.14

Release history Release notifications | RSS feed

0.0.9

2 release files

This release

0.0.7 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page