Skip to content

Commit

Permalink
Merge Paper branch (#43)
Browse files Browse the repository at this point in the history
Merge content from the paper branch into the main branch. Minor updates of the documentation, the actual code is unchanged.


Co-authored-by: Seán Kavanagh <[email protected]>
Co-authored-by: Sean Kavanagh <[email protected]>
Co-authored-by: Mojtaba Barzegari <[email protected]>
  • Loading branch information
4 people authored Dec 17, 2023
1 parent dc682ea commit 23bab9f
Show file tree
Hide file tree
Showing 27 changed files with 1,936 additions and 3 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/draft-PDF.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
on: [push]

jobs:
paper:
runs-on: ubuntu-latest
name: Paper Draft
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Build draft PDF
uses: openjournals/openjournals-draft-action@master
with:
journal: joss
# This should be the path to the paper within your repo.
paper-path: paper/paper.md
- name: Upload
uses: actions/upload-artifact@v1
with:
name: paper
# This is the output path where Pandoc will write the compiled
# PDF. Note, this should be the same directory as the input
# paper.md
path: paper/paper.pdf
33 changes: 31 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ In principle, support for other plane wave DFT code can be added by:
The Atomic Simulation Environment ([ASE](https://wiki.fysik.dtu.dk/ase/)) is used by `easyunfold` for
reading in structures, so structure file IO is natively supported for essentially all public DFT codes.

In fact, ASE can already run band structure calculations using many plane-wave DFT codes.
However, reading the plane wave coefficients from calculation outputs is not widely supported yet, which are needed here for band unfolding.
Nevertheless, using ASE's existing IO framework to widen the code support can be a fruitful direction for further development.

### Code Compatibility Notes
- Atom-projected band structures are currently only supported for `VASP` calculation outputs.
- Gamma-only and non-collinear spin calculations are not supported for `CASTEP`.
Expand All @@ -88,13 +92,19 @@ And those who helped in the development:
- [Joe Willis](https://github.com/joebesity)
- [David O. Scanlon](http://davidscanlon.com/?page_id=5)

## Contributing

## Bugs reports and feature requests
Bug reports and feature requests are well come.
If you found any bug or missing features please report it on the
[Issue Tracker](https://github.com/SMTG-Bham/easyunfold/issues).

## Code contributions
## Seeking support

If you need support about using the software, please open a ticket with the *help wanted* label on the [Issue Tracker](https://github.com/SMTG-Bham/easyunfold/issues).

## Contributing

### Code contributions
We welcome your help in improving and extending the package with your
own contributions. This is managed through GitHub pull requests;
for external contributions, we prefer the
Expand All @@ -110,6 +120,25 @@ workflow while core developers use branches in the main repository:
project. A more detailed discussion can take place there before
the changes are accepted.

### Development

To develope the package, please clone it on GitHub and install it with the `doc` and `test` extras so all dependencies needed for development are installed:

```bash
git clone https://github.com/SMTG-Bham/easyunfold
pip install -e "./easyunfold[doc,test]"
```

To run the tests, simply run the `pytest` command while in the top-level code repository.

To build the documentation, run the `make html` command while in the `docs` directory.

If you want to add new features, please also include a test case to check that they work as expected.
For more information please consult [pytest's documentation](https://docs.pytest.org).

Please note that we use pre-commit hooks for code formatting and linting.
Please install them using `pre-commit install` so these hooks can run before committing code updates.


```{toctree}
:hidden:
Expand Down
3 changes: 2 additions & 1 deletion easyunfold/unfold.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ def find_K_from_k(k: np.ndarray, M: np.ndarray):
\\vec{k} = \\vec{K} + \\vec{G}
$$
where G is a reciprocal space vector of supercell
where G is a reciprocal space vector of supercell.
NOTE: M is the transformation matrix for the cell matrix consistent of row vectors!
"""

M = np.array(M)
Expand Down
1 change: 1 addition & 0 deletions examples/MgO/conv_222/.gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
easyunfold.json filter=lfs diff=lfs merge=lfs -text
278 changes: 278 additions & 0 deletions examples/MgO/conv_222/KPOINTS_band
Original file line number Diff line number Diff line change
@@ -0,0 +1,278 @@
\Gamma -> L -> W -> X -> \Gamma
275
Reciprocal
0.0 0.0 0.0 1 \Gamma
0.006493506493506495 0.006493506493506495 0.006493506493506495 1
0.01298701298701299 0.01298701298701299 0.01298701298701299 1
0.01948051948051948 0.01948051948051948 0.01948051948051948 1
0.02597402597402598 0.02597402597402598 0.02597402597402598 1
0.032467532467532464 0.032467532467532464 0.032467532467532464 1
0.03896103896103896 0.03896103896103896 0.03896103896103896 1
0.04545454545454546 0.04545454545454546 0.04545454545454546 1
0.05194805194805196 0.05194805194805196 0.05194805194805196 1
0.05844155844155844 0.05844155844155844 0.05844155844155844 1
0.06493506493506493 0.06493506493506493 0.06493506493506493 1
0.07142857142857142 0.07142857142857142 0.07142857142857142 1
0.07792207792207792 0.07792207792207792 0.07792207792207792 1
0.08441558441558442 0.08441558441558442 0.08441558441558442 1
0.09090909090909093 0.09090909090909093 0.09090909090909093 1
0.09740259740259741 0.09740259740259741 0.09740259740259741 1
0.10389610389610392 0.10389610389610392 0.10389610389610392 1
0.11038961038961038 0.11038961038961038 0.11038961038961038 1
0.11688311688311688 0.11688311688311688 0.11688311688311688 1
0.12337662337662338 0.12337662337662338 0.12337662337662338 1
0.12987012987012986 0.12987012987012986 0.12987012987012986 1
0.13636363636363635 0.13636363636363635 0.13636363636363635 1
0.14285714285714285 0.14285714285714285 0.14285714285714285 1
0.14935064935064934 0.14935064935064934 0.14935064935064934 1
0.15584415584415584 0.15584415584415584 0.15584415584415584 1
0.16233766233766234 0.16233766233766234 0.16233766233766234 1
0.16883116883116883 0.16883116883116883 0.16883116883116883 1
0.17532467532467533 0.17532467532467533 0.17532467532467533 1
0.18181818181818185 0.18181818181818185 0.18181818181818185 1
0.18831168831168832 0.18831168831168832 0.18831168831168832 1
0.19480519480519481 0.19480519480519481 0.19480519480519481 1
0.2012987012987013 0.2012987012987013 0.2012987012987013 1
0.20779220779220783 0.20779220779220783 0.20779220779220783 1
0.21428571428571427 0.21428571428571427 0.21428571428571427 1
0.22077922077922077 0.22077922077922077 0.22077922077922077 1
0.2272727272727273 0.2272727272727273 0.2272727272727273 1
0.23376623376623376 0.23376623376623376 0.23376623376623376 1
0.24025974025974026 0.24025974025974026 0.24025974025974026 1
0.24675324675324675 0.24675324675324675 0.24675324675324675 1
0.2532467532467532 0.2532467532467532 0.2532467532467532 1
0.2597402597402597 0.2597402597402597 0.2597402597402597 1
0.2662337662337662 0.2662337662337662 0.2662337662337662 1
0.2727272727272727 0.2727272727272727 0.2727272727272727 1
0.2792207792207792 0.2792207792207792 0.2792207792207792 1
0.2857142857142857 0.2857142857142857 0.2857142857142857 1
0.2922077922077922 0.2922077922077922 0.2922077922077922 1
0.2987012987012987 0.2987012987012987 0.2987012987012987 1
0.3051948051948052 0.3051948051948052 0.3051948051948052 1
0.3116883116883117 0.3116883116883117 0.3116883116883117 1
0.3181818181818182 0.3181818181818182 0.3181818181818182 1
0.3246753246753247 0.3246753246753247 0.3246753246753247 1
0.33116883116883117 0.33116883116883117 0.33116883116883117 1
0.33766233766233766 0.33766233766233766 0.33766233766233766 1
0.34415584415584416 0.34415584415584416 0.34415584415584416 1
0.35064935064935066 0.35064935064935066 0.35064935064935066 1
0.35714285714285715 0.35714285714285715 0.35714285714285715 1
0.3636363636363637 0.3636363636363637 0.3636363636363637 1
0.37012987012987014 0.37012987012987014 0.37012987012987014 1
0.37662337662337664 0.37662337662337664 0.37662337662337664 1
0.3831168831168831 0.3831168831168831 0.3831168831168831 1
0.38961038961038963 0.38961038961038963 0.38961038961038963 1
0.3961038961038961 0.3961038961038961 0.3961038961038961 1
0.4025974025974026 0.4025974025974026 0.4025974025974026 1
0.4090909090909091 0.4090909090909091 0.4090909090909091 1
0.41558441558441567 0.41558441558441567 0.41558441558441567 1
0.422077922077922 0.422077922077922 0.422077922077922 1
0.42857142857142855 0.42857142857142855 0.42857142857142855 1
0.43506493506493504 0.43506493506493504 0.43506493506493504 1
0.44155844155844154 0.44155844155844154 0.44155844155844154 1
0.44805194805194803 0.44805194805194803 0.44805194805194803 1
0.4545454545454546 0.4545454545454546 0.4545454545454546 1
0.461038961038961 0.461038961038961 0.461038961038961 1
0.4675324675324675 0.4675324675324675 0.4675324675324675 1
0.47402597402597396 0.47402597402597396 0.47402597402597396 1
0.4805194805194805 0.4805194805194805 0.4805194805194805 1
0.487012987012987 0.487012987012987 0.487012987012987 1
0.4935064935064935 0.4935064935064935 0.4935064935064935 1
0.5 0.5 0.5 1 L
0.5 0.49603174603174605 0.503968253968254 1
0.5 0.4920634920634921 0.5079365079365079 1
0.5 0.4880952380952381 0.5119047619047619 1
0.5 0.4841269841269841 0.5158730158730158 1
0.5 0.4801587301587302 0.5198412698412698 1
0.5 0.47619047619047616 0.5238095238095238 1
0.5 0.4722222222222222 0.5277777777777778 1
0.5 0.46825396825396826 0.5317460317460317 1
0.5 0.4642857142857143 0.5357142857142857 1
0.5 0.46031746031746035 0.5396825396825397 1
0.5 0.45634920634920634 0.5436507936507937 1
0.5 0.45238095238095244 0.5476190476190477 1
0.5 0.44841269841269843 0.5515873015873016 1
0.5 0.4444444444444444 0.5555555555555556 1
0.5 0.44047619047619047 0.5595238095238095 1
0.5 0.4365079365079365 0.5634920634920635 1
0.5 0.43253968253968256 0.5674603174603174 1
0.5 0.4285714285714286 0.5714285714285714 1
0.5 0.4246031746031746 0.5753968253968254 1
0.5 0.4206349206349206 0.5793650793650793 1
0.5 0.41666666666666663 0.5833333333333333 1
0.49999999999999994 0.4126984126984127 0.5873015873015872 1
0.49999999999999994 0.4087301587301587 0.5912698412698412 1
0.5 0.40476190476190477 0.5952380952380952 1
0.5 0.4007936507936508 0.5992063492063492 1
0.5 0.3968253968253968 0.6031746031746033 1
0.5 0.39285714285714285 0.6071428571428572 1
0.5 0.3888888888888889 0.6111111111111112 1
0.5 0.3849206349206349 0.6150793650793651 1
0.5 0.38095238095238093 0.6190476190476191 1
0.5 0.376984126984127 0.623015873015873 1
0.5 0.373015873015873 0.626984126984127 1
0.5 0.369047619047619 0.6309523809523809 1
0.5 0.36507936507936506 0.6349206349206349 1
0.5 0.36111111111111105 0.6388888888888888 1
0.49999999999999994 0.35714285714285715 0.6428571428571428 1
0.5 0.35317460317460314 0.6468253968253969 1
0.49999999999999994 0.3492063492063492 0.6507936507936507 1
0.5 0.34523809523809523 0.6547619047619049 1
0.5 0.3412698412698413 0.6587301587301587 1
0.49999999999999994 0.33730158730158727 0.6626984126984127 1
0.49999999999999994 0.3333333333333333 0.6666666666666666 1
0.5 0.32936507936507936 0.6706349206349207 1
0.49999999999999994 0.32539682539682535 0.6746031746031746 1
0.5 0.3214285714285714 0.6785714285714286 1
0.5 0.31746031746031744 0.6825396825396826 1
0.5 0.3134920634920635 0.6865079365079365 1
0.5 0.30952380952380953 0.6904761904761905 1
0.49999999999999994 0.3055555555555555 0.6944444444444444 1
0.5 0.30158730158730157 0.6984126984126984 1
0.5 0.2976190476190476 0.7023809523809524 1
0.5 0.2936507936507936 0.7063492063492064 1
0.5 0.28968253968253965 0.7103174603174603 1
0.5 0.2857142857142857 0.7142857142857143 1
0.4999999999999999 0.2817460317460317 0.7182539682539681 1
0.49999999999999994 0.2777777777777778 0.7222222222222221 1
0.49999999999999994 0.2738095238095238 0.7261904761904762 1
0.5000000000000001 0.2698412698412698 0.7301587301587302 1
0.5 0.26587301587301587 0.7341269841269842 1
0.49999999999999994 0.26190476190476186 0.7380952380952381 1
0.49999999999999994 0.2579365079365079 0.7420634920634921 1
0.49999999999999994 0.25396825396825395 0.746031746031746 1
0.5 0.24999999999999997 0.75 1 W
0.5 0.2444444444444444 0.7444444444444445 1
0.5 0.23888888888888887 0.7388888888888889 1
0.5 0.2333333333333333 0.7333333333333334 1
0.5 0.22777777777777775 0.7277777777777777 1
0.5 0.2222222222222222 0.7222222222222222 1
0.5 0.21666666666666665 0.7166666666666667 1
0.5 0.21111111111111108 0.7111111111111111 1
0.5 0.20555555555555555 0.7055555555555556 1
0.5 0.19999999999999998 0.7 1
0.5 0.19444444444444442 0.6944444444444444 1
0.5 0.18888888888888888 0.6888888888888889 1
0.5 0.18333333333333335 0.6833333333333333 1
0.5 0.1777777777777778 0.6777777777777778 1
0.5 0.17222222222222225 0.6722222222222223 1
0.5 0.16666666666666666 0.6666666666666666 1
0.5 0.1611111111111111 0.6611111111111111 1
0.5 0.15555555555555556 0.6555555555555556 1
0.5 0.15 0.65 1
0.5 0.14444444444444446 0.6444444444444445 1
0.5 0.1388888888888889 0.6388888888888888 1
0.5 0.13333333333333333 0.6333333333333333 1
0.5 0.1277777777777778 0.6277777777777778 1
0.5 0.12222222222222222 0.6222222222222222 1
0.5 0.11666666666666665 0.6166666666666667 1
0.5 0.11111111111111109 0.6111111111111112 1
0.5 0.10555555555555556 0.6055555555555556 1
0.5 0.09999999999999999 0.6 1
0.5 0.09444444444444444 0.5944444444444444 1
0.5 0.08888888888888888 0.5888888888888889 1
0.5 0.08333333333333333 0.5833333333333334 1
0.5 0.07777777777777777 0.5777777777777777 1
0.5 0.0722222222222222 0.5722222222222222 1
0.5 0.06666666666666667 0.5666666666666667 1
0.5 0.061111111111111095 0.5611111111111111 1
0.5 0.05555555555555556 0.5555555555555556 1
0.5 0.049999999999999996 0.55 1
0.5 0.04444444444444447 0.5444444444444445 1
0.5 0.0388888888888889 0.5388888888888889 1
0.5 0.03333333333333333 0.5333333333333333 1
0.5 0.0277777777777778 0.5277777777777778 1
0.5 0.022222222222222233 0.5222222222222223 1
0.5 0.016666666666666666 0.5166666666666667 1
0.5 0.0111111111111111 0.5111111111111111 1
0.5 0.005555555555555568 0.5055555555555555 1
0.5 0.0 0.5 1 X
0.4943820224719101 0.0 0.4943820224719101 1
0.48876404494382025 0.0 0.48876404494382025 1
0.48314606741573035 0.0 0.48314606741573035 1
0.4775280898876405 0.0 0.4775280898876405 1
0.47191011235955055 0.0 0.47191011235955055 1
0.46629213483146065 0.0 0.46629213483146065 1
0.4606741573033708 0.0 0.4606741573033708 1
0.4550561797752809 0.0 0.4550561797752809 1
0.44943820224719105 0.0 0.44943820224719105 1
0.44382022471910115 0.0 0.44382022471910115 1
0.43820224719101125 0.0 0.43820224719101125 1
0.4325842696629214 0.0 0.4325842696629214 1
0.42696629213483145 0.0 0.42696629213483145 1
0.42134831460674155 0.0 0.42134831460674155 1
0.4157303370786517 0.0 0.4157303370786517 1
0.4101123595505618 0.0 0.4101123595505618 1
0.4044943820224719 0.0 0.4044943820224719 1
0.39887640449438205 0.0 0.39887640449438205 1
0.3932584269662921 0.0 0.3932584269662921 1
0.3876404494382023 0.0 0.3876404494382023 1
0.38202247191011235 0.0 0.38202247191011235 1
0.3764044943820225 0.0 0.3764044943820225 1
0.3707865168539326 0.0 0.3707865168539326 1
0.3651685393258427 0.0 0.3651685393258427 1
0.35955056179775285 0.0 0.35955056179775285 1
0.35393258426966295 0.0 0.35393258426966295 1
0.348314606741573 0.0 0.348314606741573 1
0.34269662921348315 0.0 0.34269662921348315 1
0.33707865168539325 0.0 0.33707865168539325 1
0.3314606741573034 0.0 0.3314606741573034 1
0.32584269662921345 0.0 0.32584269662921345 1
0.3202247191011236 0.0 0.3202247191011236 1
0.3146067415730337 0.0 0.3146067415730337 1
0.3089887640449438 0.0 0.3089887640449438 1
0.30337078651685395 0.0 0.30337078651685395 1
0.29775280898876405 0.0 0.29775280898876405 1
0.29213483146067415 0.0 0.29213483146067415 1
0.28651685393258425 0.0 0.28651685393258425 1
0.2808988764044944 0.0 0.2808988764044944 1
0.2752808988764045 0.0 0.2752808988764045 1
0.2696629213483146 0.0 0.2696629213483146 1
0.2640449438202247 0.0 0.2640449438202247 1
0.25842696629213485 0.0 0.25842696629213485 1
0.25280898876404495 0.0 0.25280898876404495 1
0.24719101123595505 0.0 0.24719101123595505 1
0.24157303370786518 0.0 0.24157303370786518 1
0.23595505617977527 0.0 0.23595505617977527 1
0.2303370786516854 0.0 0.2303370786516854 1
0.2247191011235955 0.0 0.2247191011235955 1
0.21910112359550563 0.0 0.21910112359550563 1
0.21348314606741578 0.0 0.21348314606741578 1
0.20786516853932585 0.0 0.20786516853932585 1
0.20224719101123595 0.0 0.20224719101123595 1
0.19662921348314605 0.0 0.19662921348314605 1
0.19101123595505623 0.0 0.19101123595505623 1
0.1853932584269663 0.0 0.1853932584269663 1
0.1797752808988764 0.0 0.1797752808988764 1
0.1741573033707865 0.0 0.1741573033707865 1
0.16853932584269665 0.0 0.16853932584269665 1
0.16292134831460675 0.0 0.16292134831460675 1
0.15730337078651682 0.0 0.15730337078651682 1
0.15168539325842692 0.0 0.15168539325842692 1
0.14606741573033707 0.0 0.14606741573033707 1
0.14044943820224723 0.0 0.14044943820224723 1
0.13483146067415733 0.0 0.13483146067415733 1
0.1292134831460674 0.0 0.1292134831460674 1
0.12359550561797757 0.0 0.12359550561797757 1
0.11797752808988764 0.0 0.11797752808988764 1
0.11235955056179772 0.0 0.11235955056179772 1
0.10674157303370789 0.0 0.10674157303370789 1
0.10112359550561797 0.0 0.10112359550561797 1
0.09550561797752813 0.0 0.09550561797752813 1
0.08988764044943821 0.0 0.08988764044943821 1
0.0842696629213483 0.0 0.0842696629213483 1
0.07865168539325845 0.0 0.07865168539325845 1
0.07303370786516854 0.0 0.07303370786516854 1
0.06741573033707862 0.0 0.06741573033707862 1
0.06179775280898878 0.0 0.06179775280898878 1
0.05617977528089894 0.0 0.05617977528089894 1
0.05056179775280902 0.0 0.05056179775280902 1
0.04494382022471911 0.0 0.04494382022471911 1
0.03932584269662919 0.0 0.03932584269662919 1
0.033707865168539346 0.0 0.033707865168539346 1
0.02808988764044943 0.0 0.02808988764044943 1
0.022471910112359515 0.0 0.022471910112359515 1
0.016853932584269673 0.0 0.016853932584269673 1
0.011235955056179832 0.0 0.011235955056179832 1
0.005617977528089916 0.0 0.005617977528089916 1
0.0 0.0 0.0 1 \Gamma
Loading

0 comments on commit 23bab9f

Please sign in to comment.