AiiDA CIF2J
An AiiDA plugin for calculating magnetic exchange interactions.
Installation
This plugin is available through PyPI and should be installed using pip python package manager.
pip install aiida-cif2j
Optional: Wannier90 Workflows
This project exposes a WorkChain which will carry out the full process of calculating
Wannier functions for a structure which are then directly fed into TB2J. This requires
two third party packages, aiida-wannier90 and aiida-wannier90-workflows. Neither is
currently released on PyPI, so they must be installed from their git repositories. This
plugin ships a CLI command to do this for you:
cif2j wannier90 install
Requirements
To use this plugin a configured AiiDA profile and computer are required, as well as a compiled
wann2J.py executable (from TB2J). For more information on how to set
up AiiDA refer to the
AiiDA documentation.
Setup
To configure the TB2J plugin you will need to create a new AiiDA code object. The following is an example of a basic YAML configuration file for a TB2J code:
label: tb2j
description: Wannier90 -> TB2J
computer: localhost
filepath_executable: wann2J.py
default_calc_job_plugin: cif2j.wannier_tb2j
use_double_quotes: false
with_mpi: false
prepend_text: ""
append_text: ""
Write this to a file named tb2j.yml ensuring the value for computer matches the label of your computer
configured in the previous step. The code can then be configured by running:
verdi code create core.code.installed --config tb2j.yml -n
If successful, this will create a new AiiDA code with the label tb2j which can then be used to run TB2J
calculations within the AiiDA framework.
NOTE: The full Wannier90 -> TB2J workflow requires a
pw2wannier90.xcode and awannier90.xcode to be configured on the same AiiDA computer. AiiDA cannot copy the intermediate files thatwannier90.xreads directly between two different remote machines, so running these two codes on different computers will cause the workflow to fail.
See the documentation for the full list of calculation inputs, parameters and outputs, the higher level WorkChains, and complete runnable examples.
Examples
The following submits the full Wannier90 -> TB2J workflow starting from an MCIF structure file: Quantum
ESPRESSO SCF and Wannierisation (via aiida-wannier90-workflows), followed directly by TB2J. This can be
run either from the command line:
cif2j wannier90 submit structure.mcif \
--pw-code qe-pw@localhost \
--pw2wannier90-code qe-pw2wannier90@localhost \
--wannier90-code wannier90@localhost \
--tb2j-code tb2j@localhost \
--pseudo-family SSSP/1.3/PBE/efficiency
or from a Python script / verdi shell:
from aiida.engine import run
from aiida.orm import SinglefileData
from aiida.plugins import WorkflowFactory
WannierTB2J = WorkflowFactory("cif2j.wannier_tb2j")
builder = WannierTB2J.get_builder_from_protocol(
codes={
"pw": "qe-pw@localhost",
"pw2wannier90": "qe-pw2wannier90@localhost",
"wannier90": "wannier90@localhost",
"tb2j": "tb2j@localhost",
},
structure=SinglefileData(file="/absolute/path/to/structure.mcif"),
pseudo_family="SSSP/1.3/PBE/efficiency",
)
results, node = run.get_node(builder)
Magnetic elements and the Fermi energy are auto-detected in both cases, so neither needs to be supplied explicitly. See the examples documentation for more, including running TB2J directly from existing Wannier90 outputs and fixing magnetic elements/TB2J parameters explicitly.
License
Funding
Contributors to this project were funded by;
Metadata
Release files for aiida-cif2j 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| aiida_cif2j-0.2.0.tar.gz | 40.7 kB | Without provenance | Details for aiida_cif2j-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| aiida_cif2j-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for aiida_cif2j-0.2.0-py3-none-any.whl |
Total release size: 69.1 kB
Release files / aiida_cif2j-0.2.0.tar.gz
| Download URL | aiida_cif2j-0.2.0.tar.gz |
|---|---|
| Size | 40.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
120b77b96fc31c2aace19c5ee4a42c4c403dec1895cd9e8cb0b5778748239196
|
|
BLAKE2b-256 checksum How to use checksums |
8f7470a99e92946811fdab7c6ac617f4a6f1a493cf09bb0a463e4fd322f774d7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.12.16
|
Release files / aiida_cif2j-0.2.0-py3-none-any.whl
| Download URL | aiida_cif2j-0.2.0-py3-none-any.whl |
|---|---|
| Size | 28.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b38ccd38a6a9c46114ea00ffef7016ecceb5bdbc65ccc8c29871977601caa17e
|
|
BLAKE2b-256 checksum How to use checksums |
4945723dcddc0afce539e82e8ff6a8d301ce5d0d6489e47147e35954ed47f5c7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.12.16
|
Security for aiida-cif2j 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.