From 8eaef8cc1004b68644534b47943eb3d6c12df56d Mon Sep 17 00:00:00 2001 From: Sean Kavanagh Date: Sat, 6 Apr 2024 14:41:01 -0400 Subject: [PATCH] Fix typos --- docs/examples/example_si222.md | 2 +- easyunfold/cli.py | 6 +++--- examples/MgO/POSCAR | 16 ---------------- tests/test_cli.py | 2 +- 4 files changed, 5 insertions(+), 21 deletions(-) delete mode 100644 examples/MgO/POSCAR diff --git a/docs/examples/example_si222.md b/docs/examples/example_si222.md index 1e98bbd..73b835f 100644 --- a/docs/examples/example_si222.md +++ b/docs/examples/example_si222.md @@ -210,7 +210,7 @@ Path in the primitive cell: W : 38 X : 50 \Gamma : 73 -Unfolding had been performed - use `unfold plot` to plot the spectral function. +Unfolding has been performed - use `unfold plot` to plot the spectral function. ``` Note that in most cases one would always want to include the additional kpoints to correctly capture the effect of symmetry breaking. diff --git a/easyunfold/cli.py b/easyunfold/cli.py index 34d653c..9a1366c 100644 --- a/easyunfold/cli.py +++ b/easyunfold/cli.py @@ -214,7 +214,7 @@ def unfold_status(ctx): click.echo(f' {label:<10}: {index+1:<5}') if unfoldset.is_calculated: - click.echo('Unfolding had been performed - use `unfold plot` to plot the spectral function.') + click.echo('Unfolding has been performed - use `unfold plot` to plot the spectral function.') else: click.echo('Please run the supercell band structure calculation and run `unfold calculate`.') @@ -305,7 +305,7 @@ def unfold_effective_mass(ctx, intensity_threshold, spin, band_filter, npoints, for mode in ['cbm', 'vbm']: for kid, subkid, iband in zip(*efm.get_band_extrema(mode=mode)): band_idx = ','.join(map(str, iband)) - table.append([kid, mode, subkid, band_idx]) + table.append([kid, mode.upper(), subkid, band_idx]) click.echo(tabulate(table, headers=['Kpoint index', 'Kind', 'Sub-kpoint index', 'Band indices'])) click.echo('') @@ -331,7 +331,7 @@ def print_data(entries, tag='me'): """Print the effective mass data""" table = [] for i, entry in enumerate(entries): - me = entry['effective_mass'] + me = round(entry['effective_mass'], 3) kf = entry['kpoint_from'] lf = entry['kpoint_label_from'] diff --git a/examples/MgO/POSCAR b/examples/MgO/POSCAR deleted file mode 100644 index d6750b7..0000000 --- a/examples/MgO/POSCAR +++ /dev/null @@ -1,16 +0,0 @@ -Mg4 O4 -1.0 -0.0000000000000000 4.2564840000000004 4.2564840000000004 -2.1282420000000002 0.0000000000000000 2.1282420000000002 -4.2564840000000004 4.2564840000000004 0.0000000000000000 -Mg O -4 4 -direct -0.01 0.01 0.0100000000000000 Mg -0.0000000000000000 0.0000000000000000 0.5000000000000000 Mg -0.5000000000000000 0.0000000000000000 0.0000000000000000 Mg -0.5000000000000000 0.0000000000000000 0.5000000000000000 Mg -0.7500000000000000 0.5000000000000000 0.2500000000000000 O -0.7500000000000000 0.5000000000000000 0.7500000000000000 O -0.2500000000000000 0.5000000000000000 0.2500000000000000 O -0.2500000000000000 0.5000000000000000 0.7500000000000000 O diff --git a/tests/test_cli.py b/tests/test_cli.py index 7e3a18b..3d1704b 100644 --- a/tests/test_cli.py +++ b/tests/test_cli.py @@ -207,7 +207,7 @@ def test_unfold(si_project_dir, tag): args_calc = ['unfold', '--data-file', 'test.json', 'status'] output = runner.invoke(easyunfold, args_calc) assert output.exit_code == 0 - assert 'had been performed' in output.stdout + assert 'has been performed' in output.stdout unfoldset = loadfn('test.json')