Skip to main content

AiiDA plugin for CASTEP

Project description

AiiDA plugin for working with CASTEP

Docs status

pipeline status

A plugin for AiiDA to work with plane-wave pseudopotential DFT code CASTEP. CASTEP has a single binary executable and calculation is primarily controlled by the task keyword. The generic CastepCalculation should work with all tasks, at least in terms of generating input files. Likewise a generic CastepParser class is implemented and can handle parsing most information we are interested in singlepoint, geometryoptimisation, bandstructure/spectral tasks. Most output files are retrieved if present, and it is possible to explicitly request retrieval from the remote computer. The goal of this plugin is not to provide a comprehensive parser of the CASTEP results, but to build a graph of calculations performed for provenance preservation and workflow automation. Input and output of a simple calculation:

Asingle calculation

or a series of operations and automated calculations:

A series of calculations

The raw files can always be extracted from the database and analysed by the post-processing tools of choice. Even better, such tools may be integrated with the AiiDA framework and have the analysis appended to the provenance graph.

Highlights of available features:

  • Storing usp/recpot as UspData (sub-class of SingleFileData) in AiiDA database and create/use of pseudo family groups.
  • Store OTFG generating strings as OTFGData in AiiDA. Create of family/group are also supported. OTFG library (such as "C19") are represented as a OTFG string works for all elements.
  • Preparation of CASTEP input files. Writing cell and parameters files are both supported. Tags in positions_abs block file should also work, e.g LABEL, SPIN, MIXTURE.
  • Parsing energy, force, stress from output .castep file and .geom file
  • Parsing trajectory from .geom, .ts, .md files.
  • Checking errors in .param and .cell files before submitting, using dictionaries shipped from built from CASTEP executable.
  • Extra KpointData input node for BS, SEPCTRAL and PHONON tasks.
  • Preparing transition state search calculations
  • A create_restart function for easy creation of continuation/restart calculations. Input can be altered using param_update and param_delete keyword arguments. Automatic copying/linking of remote check files by AiiDA.
  • A get_castep_inputs_summary function to print a summary of inputs of a calculations.
  • A compare_with method to compare the inputs of two calculations.

Documentation

Quick glimpse into how to use the plugin for running calculations:

Documentation is hosted at Read the Docs:
dev version
master version

Dependencies

The primary dependency is the aiida_core package. The dependencies are:

  • The plugin version 1.0 and above support only aiida_core>=1.0.0b6.
  • The plugin version 0.3 support only aiida_core 0.12.x versions.

Due to major design and API changes in the aiida_core, scripts written are incompatible between and new versions.

Todos and nice-to-haves

  • Methods for importing existing calculations
  • Support for submitting file based CASTEP calculations.
  • At the moment there is no enforcement on the type in Dict input node. For example, setting smearing_width to 0.1 and "0.1" is equivalent, but they will store differently in the database.

How to test

The tests uses the pytest framework. First, install with the dependencies

pip install aiida_core[testing]
pip install aiida-castep[testing]

Then you can run the command pytest from the project directory.

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

aiida-castep-1.3.0.tar.gz (141.7 kB view details)

Uploaded Source

Built Distribution

aiida_castep-1.3.0-py3-none-any.whl (161.1 kB view details)

Uploaded Python 3

File details

Details for the file aiida-castep-1.3.0.tar.gz.

File metadata

  • Download URL: aiida-castep-1.3.0.tar.gz
  • Upload date:
  • Size: 141.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.12

File hashes

Hashes for aiida-castep-1.3.0.tar.gz
Algorithm Hash digest
SHA256 8a1f565036e3d52f2e138dd9ef877bdf39aa49c68cf47ec84d61b5b87068df77
MD5 a28fecccf401e8b5fa3479077172b032
BLAKE2b-256 77b2516719301a532d0713eccfc30a9dce0c28610019116815eb0526d787e2f0

See more details on using hashes here.

File details

Details for the file aiida_castep-1.3.0-py3-none-any.whl.

File metadata

  • Download URL: aiida_castep-1.3.0-py3-none-any.whl
  • Upload date:
  • Size: 161.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.1 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.12

File hashes

Hashes for aiida_castep-1.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8cc6ff1c2abd7a90c7a4df95bfd77bd157a96fa97ad2db787fad8c3f12f96f4b
MD5 3a566ca918153cbd89a609bc5aa8892e
BLAKE2b-256 cd2a4382ab967516b22a7d26cac5cb1051c7e6ead6b61ecb90189e103b8d431f

See more details on using hashes here.

Supported by

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