Skip to content

Commit

Permalink
Merge branch 'refs/heads/develop' into dopey_fermi
Browse files Browse the repository at this point in the history
# Conflicts:
#	examples/CompetingPhases/MgO/MgO_EaH_0.0/vasp_std/vasprun.xml
#	examples/CompetingPhases/MgO/MgO_EaH_0.0/vasp_std/vasprun.xml.gz
#	examples/CompetingPhases/MgO/Mg_EaH_0.0/vasp_std/vasprun.xml
#	examples/CompetingPhases/MgO/Mg_EaH_0.0/vasp_std/vasprun.xml.gz
#	examples/CompetingPhases/MgO/Mg_EaH_0.0061/vasp_std/vasprun.xml
#	examples/CompetingPhases/MgO/Mg_EaH_0.0061/vasp_std/vasprun.xml.gz
#	examples/CompetingPhases/MgO/Mg_EaH_0.0099/vasp_std/vasprun.xml
#	examples/CompetingPhases/MgO/Mg_EaH_0.0099/vasp_std/vasprun.xml.gz
#	examples/CompetingPhases/MgO/O2_EaH_0.0/vasp_std/vasprun.xml
#	examples/CompetingPhases/MgO/O2_EaH_0.0/vasp_std/vasprun.xml.gz
#	pyproject.toml
  • Loading branch information
kavanase committed Aug 16, 2024
2 parents 9d3a7cc + b3c674d commit da06266
Show file tree
Hide file tree
Showing 129 changed files with 1,078 additions and 569 deletions.
9 changes: 2 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,8 @@ displacements from DFT supercell calculations. See the [JOSS paper](https://doi.
## Installation
```bash
pip install doped # install doped and dependencies
conda install -c conda-forge spglib # bundle C libraries with spglib
```

Note that either `conda install -c conda-forge spglib` or
`pip install git+https://github.com/spglib/spglib --config-settings=cmake.define.SPGLIB_SHARED_LIBS=OFF`
should be used after `pip install doped`, which ensures that the correct C libraries are bundled with
`spglib`, to prevent unnecessary warnings.

Alternatively if desired, `doped` can also be installed from `conda` with:

```bash
Expand All @@ -64,9 +58,10 @@ As shown in the `doped` tutorials, it is highly recommended to use the [`ShakeNB
Not currently cited but should be for chempot plot:
- Quadir et al. **_Low-Temperature Synthesis of Stable CaZn<sub>2</sub>P<sub>2</sub> Zintl Phosphide Thin Films as Candidate Top Absorbers_** [_arXiv_](https://arxiv.org/abs/2406.15637) 2024
-->
- M. Elgaml et al. **_Controlling the Superconductivity of Nb<sub>2</sub>Pd<sub>x</sub>S<sub>5</sub> via Reversible Li Intercalation_** [_Inorganic Chemistry_](https://pubs.acs.org/doi/full/10.1021/acs.inorgchem.3c03524) 2024
- Z. Yuan & G. Hautier **_First-principles study of defects and doping limits in CaO_** [_Applied Physics Letters_](https://doi.org/10.1063/5.0211707) 2024
- B. E. Murdock et al. **_Li-Site Defects Induce Formation of Li-Rich Impurity Phases: Implications for Charge Distribution and Performance of LiNi<sub>0.5-x</sub>M<sub>x</sub>Mn<sub>1.5</sub>O<sub>4</sub> Cathodes (M = Fe and Mg; x = 0.05–0.2)_** [_Advanced Materials_](https://doi.org/10.1002/adma.202400343) 2024
- A. G. Squires et al. **_Oxygen dimerization as a defect-driven process in bulk LiNiO2<sub>2</sub>_** [_ChemRxiv_](https://doi.org/10.26434/chemrxiv-2024-lcmkj) 2024
- A. G. Squires et al. **_Oxygen dimerization as a defect-driven process in bulk LiNiO2<sub>2</sub>_** [_ACS Energy Letters_](https://pubs.acs.org/doi/10.1021/acsenergylett.4c01307) 2024
- Y. Fu & H. Lohan et al. **_Factors Enabling Delocalized Charge-Carriers in Pnictogen-Based
Solar Absorbers: In-depth Investigation into CuSbSe<sub>2</sub>_** [_arXiv_](https://doi.org/10.48550/arXiv.2401.02257) 2024
- S. Hachmioune et al. **_Exploring the Thermoelectric Potential of MgB4: Electronic Band Structure, Transport Properties, and Defect Chemistry_** [_Chemistry of Materials_](https://doi.org/10.1021/acs.chemmater.4c00584) 2024
Expand Down
4 changes: 3 additions & 1 deletion docs/Dev_ToDo.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# `doped` Development To-Do List
## Chemical potential
- Check through chemical potential TO-DOs. Need to recheck validity of approximations used for extrinsic competing phases (and code for this). Proper `vasp_std` setup (with `NKRED` folders like for defect calcs) and `vasp_ncl` generation.
- Need to recheck validity of approximations used for extrinsic competing phases (and code for this). Proper `vasp_std` setup (with `NKRED` folders like for defect calcs) and `vasp_ncl` generation.
- Efficient generation of competing phases for which there are many polymorphs? See SK notes from CdTe competing phases.
- Publication ready chemical potential diagram plotting tool as in Adam Jackson's `plot-cplap-ternary` (3D) and Sungyhun's `cplapy` (4D) (see `doped_chempot_plotting_example.ipynb`; code there, just needs to be implemented in module functions). `ChemicalPotentialGrid` in `py-sc-fermi` interface could be quite useful for this? (Worth moving that part of code out of `interface` subpackage?) Also can see https://github.com/materialsproject/pymatgen-analysis-defects/blob/main/pymatgen/analysis/defects/plotting/phases.py for 2D chempot plotting.
- Also see `Cs2SnTiI6` notebooks for template code for this.
Expand All @@ -15,6 +15,8 @@
- Could also add an optional right-hand-side y-axis for defect concentration (for a chosen anneal temp) to our TLD plotting (e.g. `concentration_T = None`) as done for thesis, noting in docstring that this obvs doesn't account for degeneracy!
- Separate `dist_tol` for interstitials vs (inequivalent) vacancies/substitutions? (See Xinwei chat) Any other options on this front?
- Also see Fig. 6a of the `AiiDA-defects` preprint, want plotting tools like this
- Kumagai GKFO and CC diagram corrections. Implemented in `pydefect` and relatively easy to port?
- 2D corrections; like `pydefect_2d`, or recommended to use SCPC in VASP?
- Can we add an option to give the `pydefect` defect-structure-info output (shown here https://kumagai-group.github.io/pydefect/tutorial.html#check-defect-structures) – seems quite useful tbf

## Housekeeping
Expand Down
2 changes: 1 addition & 1 deletion docs/Future_ToDo.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,9 @@
- In these cases, will also want to be able to plot these in a smart manner on the defect TLD.
Separate lines to the stoichiometrically-equivalent (unperturbed) point defect, but with the same
colour just different linestyles? (or something similar)
- `doped` functions should be equally applicable to the base `pymatgen` `Defect`/`DefectEntry` objects (as well as the corresponding `doped` subclasses) as much as possible. Can we add some quick tests for this?
- Implement shallow donor/acceptor binding estimation functions (via effective mass theory)
- Kasamatsu formula for defect concentrations at high concentrations (accounts for lattice site competition), as shown in DefAP paper
- Eigenvalue corrections for the eigenvalue plots, like shown in 10.1103/PhysRevB.109.054106?

## Docs
- Add LDOS plotting, big selling point for defects and disorder!
Expand Down
16 changes: 0 additions & 16 deletions docs/Installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,6 @@ Installation
.. code-block:: bash
pip install doped # install doped and dependencies
conda install -c conda-forge spglib # bundle C libraries with spglib
Note that either ``conda install -c conda-forge spglib`` or
``pip install git+https://github.com/spglib/spglib --config-settings=cmake.define.SPGLIB_SHARED_LIBS=OFF``
should be used after ``pip install doped``, which ensures that the correct C libraries are bundled with
``spglib``, to prevent unnecessary warnings. You can check that the correct C libraries have been bundled
by running the following in Python, and confirming that the same version numbers are printed:

.. code-block:: python
import spglib
print(spglib.__version__)
print(spglib.spg_get_version_full())
In some cases, you might need to first uninstall ``spglib`` with both ``conda uninstall spglib`` and
``pip uninstall spglib`` (to ensure no duplicate installations), before reinstalling.
Alternatively if desired, ``doped`` can also be installed from ``conda`` with:

Expand Down
6 changes: 1 addition & 5 deletions docs/Troubleshooting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,7 @@ A known issue with ``spglib`` is that it can give unnecessary errors or warnings
spglib: get_bravais_exact_positions_and_lattice failed
spglib: ref_get_exact_structure_and_symmetry failed.
This can be fixed by reinstalling ``spglib`` with ``conda install -c conda-forge spglib`` or
``pip install git+https://github.com/spglib/spglib --config-settings=cmake.define.SPGLIB_SHARED_LIBS=OFF``
as detailed in the `Installation <https://doped.readthedocs.io/en/latest/Installation.html>`__ instructions.
This ensures the correct C libraries are bundled with ``spglib``.

Typically this can be fixed by updating to ``spglib>=2.5`` with `pip install --upgrade spglib``.
.. see doped_spglib_warnings.ipynb
``ShakeNBreak``
Expand Down
5 changes: 3 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,10 @@ Studies using ``doped``, so far
.. Not currently cited but should be for chempot plot:
Quadir et al. **_Low-Temperature Synthesis of Stable CaZn<sub>2</sub>P<sub>2</sub> Zintl Phosphide Thin Films as Candidate Top Absorbers_** [_arXiv_](https://arxiv.org/abs/2406.15637) 2024
- Z\. Yuan & G. Hautier **First-principles study of defects and doping limits in CaO** `Applied Physics Letters <https://doi.org/10.1063/5.0211707>`_ 2024
- M\. Elgaml et al. **Controlling the Superconductivity of Nb** :sub:`2` **Pd** :sub:`x` **S** :sub:`5` **via Reversible Li Intercalation** `Inorganic Chemistry <https://pubs.acs.org/doi/full/10.1021/acs.inorgchem.3c03524>`__ 2024
- Z\. Yuan & G. Hautier **First-principles study of defects and doping limits in CaO** `Applied Physics Letters <https://doi.org/10.1063/5.0211707>`__ 2024
- B\. E. Murdock et al. **Li-Site Defects Induce Formation of Li-Rich Impurity Phases: Implications for Charge Distribution and Performance of LiNi** :sub:`0.5-x` **M** :sub:`x` **Mn** :sub:`1.5` **O** :sub:`4` **Cathodes (M = Fe and Mg; x = 0.05–0.2)** `Advanced Materials <https://doi.org/10.1002/adma.202400343>`_ 2024
- A\. G. Squires et al. **Oxygen dimerization as a defect-driven process in bulk LiNiO₂** `ChemRxiv <https://doi.org/10.26434/chemrxiv-2024-lcmkj>`__ 2024
- A\. G. Squires et al. **Oxygen dimerization as a defect-driven process in bulk LiNiO₂** `ACS Energy Letters <https://pubs.acs.org/doi/10.1021/acsenergylett.4c01307>`__ 2024
- Y\. Fu & H. Lohan et al. **Factors Enabling Delocalized Charge-Carriers in Pnictogen-Based Solar Absorbers: In-depth Investigation into CuSbSe<sub>2</sub>** `arXiv <https://doi.org/10.48550/arXiv.2401.02257>`_ 2024
- S\. Hachmioune et al. **Exploring the Thermoelectric Potential of MgB4: Electronic Band Structure, Transport Properties, and Defect Chemistry** `Chemistry of Materials <https://doi.org/10.1021/acs.chemmater.4c00584>`__ 2024
- J\. Hu et al. **Enabling ionic transport in Li3AlP2 the roles of defects and disorder** `ChemRxiv <https://doi.org/10.26434/chemrxiv-2024-3s0kh>`__ 2024
Expand Down
3 changes: 0 additions & 3 deletions doped/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,6 @@ def _ignore_pmg_warnings():
# ignore warning about structure charge that appears when getting Vasprun.as_dict():
warnings.filterwarnings("ignore", message="Structure charge")

# SpglibDataset warning introduced in v2.4.1
warnings.filterwarnings("ignore", message="dict interface")


_ignore_pmg_warnings()

Expand Down
1 change: 0 additions & 1 deletion doped/analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,6 @@ def defect_from_structures(
Dictionary of bulk supercell Voronoi node information, for
further expedited site-matching.
"""
warnings.filterwarnings("ignore", "dict interface") # ignore spglib warning from v2.4.1
try:
def_type, comp_diff = get_defect_type_and_composition_diff(bulk_supercell, defect_supercell)
except RuntimeError as exc:
Expand Down
Loading

0 comments on commit da06266

Please sign in to comment.