diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 988937c..0000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "python.pythonPath": "/usr/local/bin/python3" -} \ No newline at end of file diff --git a/docs/source/figures/.DS_Store b/docs/source/figures/.DS_Store new file mode 100644 index 0000000..5008ddf Binary files /dev/null and b/docs/source/figures/.DS_Store differ diff --git a/docs/source/figures/ir_lda_700_better.png b/docs/source/figures/ir_lda_700_better.png deleted file mode 100644 index cedeca4..0000000 Binary files a/docs/source/figures/ir_lda_700_better.png and /dev/null differ diff --git a/docs/source/figures/mgo_xps.png b/docs/source/figures/mgo_xps.png deleted file mode 100644 index 3b7ffed..0000000 Binary files a/docs/source/figures/mgo_xps.png and /dev/null differ diff --git a/galore.log b/galore.log deleted file mode 100644 index 261b494..0000000 --- a/galore.log +++ /dev/null @@ -1,120 +0,0 @@ -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root: Sn s: 6.000e-04 -INFO:root: Sn p: 3.850e-04 -INFO:root: Sn d: 3.700e-03 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 40.8 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: O s: 4.171e-01 -INFO:root: O p: 1.704e+00 -INFO:root: Sn s: 9.140e-02 -INFO:root: Sn p: 7.160e-02 -INFO:root: Sn d: 8.636e-01 -INFO:root:Scaling overlay intensity by 47177.68663440785 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 5.95 keV -INFO:root: Citation: J. H. Scofield (1973) Lawrence Livermore National Laboratory Report No. UCRL-51326, -Parametrised as log-log order 8 polynomial (A. J. Jackson 2018) -INFO:root: Link: https://doi.org/10.2172/4545040 -INFO:root: Orbital cross-section weights per electron: -INFO:root: O s: 1.879e+01 -INFO:root: O p: 3.304e-01 -WARNING:root:Could not find cross-section data for element O, orbital d. Skipping this orbital. -INFO:root: Sn s: 4.510e+01 -INFO:root: Sn p: 1.924e+01 -INFO:root: Sn d: 5.067e+01 -INFO:root:Scaling overlay intensity by 95194.5691326041 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 5.95 keV -INFO:root: Citation: J. H. Scofield (1973) Lawrence Livermore National Laboratory Report No. UCRL-51326, -Parametrised as log-log order 8 polynomial (A. J. Jackson 2018) -INFO:root: Link: https://doi.org/10.2172/4545040 -INFO:root: Orbital cross-section weights per electron: -INFO:root: O s: 1.879e+01 -INFO:root: O p: 3.304e-01 -WARNING:root:Could not find cross-section data for element O, orbital d. Skipping this orbital. -INFO:root: Sn s: 4.510e+01 -INFO:root: Sn p: 1.924e+01 -INFO:root: Sn d: 5.067e+01 -INFO:root:Scaling overlay intensity by 95194.5691326041 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root: Sn s: 6.000e-04 -INFO:root: Sn p: 3.850e-04 -INFO:root: Sn d: 3.700e-03 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 -INFO:root:Applying cross-section weighting values to PDOS: -INFO:root: Photon energy: 1486.6 eV -INFO:root: Citation: Yeh, J.J. and Lindau, I. (1985) Atomic Data and Nuclear Data Tables 32 pp 1-155 -INFO:root: Link: https://doi.org/10.1016/0092-640X(85)90016-6 -INFO:root: Orbital cross-section weights per electron: -INFO:root: Mg s: 1.900e-04 -INFO:root: Mg p: 7.667e-04 -INFO:root: O s: 9.500e-04 -INFO:root: O p: 6.000e-05 diff --git a/galore/.DS_Store b/galore/.DS_Store new file mode 100644 index 0000000..af09dd6 Binary files /dev/null and b/galore/.DS_Store differ diff --git a/galore/project/.DS_Store b/galore/project/.DS_Store new file mode 100644 index 0000000..a60c887 Binary files /dev/null and b/galore/project/.DS_Store differ diff --git a/galore/project/setup.cfg b/galore/project/setup.cfg deleted file mode 100644 index c8674b8..0000000 --- a/galore/project/setup.cfg +++ /dev/null @@ -1,5 +0,0 @@ -[metadata] -license_file = LICENSE - -[bdist_wheel] -universal = 1 \ No newline at end of file diff --git a/galore/project/setup.py b/galore/project/setup.py deleted file mode 100644 index b635a6d..0000000 --- a/galore/project/setup.py +++ /dev/null @@ -1,86 +0,0 @@ -""" -Galore: Gaussian and Lorentzian broadening of simulated spectra -""" - -from os.path import abspath, dirname -from setuptools import setup, find_packages -import unittest - -project_dir = abspath(dirname(__file__)) - - -def unit_tests(): - test_loader = unittest.TestLoader() - test_suite = test_loader.discover('test', pattern='test*.py') - return test_suite - -if __name__ == "__main__": - - setup( - name='galore', - version='0.6.2', - description='Broadening and weighting for simulated spectra', - long_description=""" - Apply Gaussian and Lorentzian broadening to data from ab initio - calculations. The two main intended applications are - - 1. Broadening of electronic density-of-states to simulate photoemission - spectroscopy (PES) data. Orbital contributions may also be weighted to - account for the frequency-dependent photoionisation cross-section. - - 2. Application of Lorentzian instrumental broadening to simulated - Raman spectra from DFPT calculations. - """, - url="https://github.com/SMTG-UCL/galore", - author="Scanlon Materials Theory Group", - author_email="d.scanlon@ucl.ac.uk", - license='GPL v3', - - classifiers=[ - 'Development Status :: 5 - Production/Stable', - 'Intended Audience :: Science/Research', - 'License :: OSI Approved :: GNU General Public License v3 (GPLv3)', - 'Natural Language :: English', - 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.4', - 'Programming Language :: Python :: 3.5', - 'Programming Language :: Python :: 3.6', - 'Programming Language :: Python :: 3.6', - 'Topic :: Scientific/Engineering :: Chemistry', - 'Topic :: Scientific/Engineering :: Physics' - ], - keywords=('spectroscopy spectra chemistry physics raman xps haxpes pes' - ' photoelectron dos pdos gaussian lorentzian broadening'), - include_package_data=True, - packages=find_packages(exclude=['docs', 'test']), - install_requires=['numpy', 'scipy', 'matplotlib'], - extras_require={'docs': ["sphinx", - "sphinx_rtd_theme", - "sphinx-argparse", - "sphinxcontrib-bibtex"], - 'vasp': ['monty <= v4.0.2;python_version < "3.6"', - 'pymatgen == 2018.1.19;python_version ~= "3.4"', - 'ruamel.yaml <= 0.15.94;python_version ~= "3.4"', - 'numpy ~= 1.16;python_version ~= "3.4"', - 'pymatgen <= 2019.6.20;python_version ~= "3.5"', - 'pymatgen <= 2021.2.8.1;python_version ~= "3.6"', - 'pymatgen;python_version >= "3.7"', - 'numpy >= 1.17;python_version >= "3.6"']}, - python_requires='!=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, <4', - entry_points={ - 'console_scripts': [ - 'galore=galore.cli.galore:main', - 'galore-get-cs=galore.cli.galore_get_cs:main', - 'galore-plot-cs=galore.cli.galore_plot_cs:main' - ] - }, - test_suite='setup.unit_tests' - ) - -# If a package includes data files (e.g. elemental masses), these should be -# added to setup as package_data={'package_name': ['rel_path2datafile.dat']} -# Other top-level data files (e.g. example config files) can be added with -# data_files=[('installation_directory', ['rel_path/datafile.dat'])]. -# See https://packaging.python.org/distributing/ -# -# For GUI, add gui_scripts to entry_points diff --git a/mgo_xps.png b/mgo_xps.png deleted file mode 100644 index 0c8d293..0000000 Binary files a/mgo_xps.png and /dev/null differ diff --git a/test/MgO/.DS_Store b/test/MgO/.DS_Store index 1a38722..d0fa06e 100644 Binary files a/test/MgO/.DS_Store and b/test/MgO/.DS_Store differ diff --git a/test/test.py b/test/test.py index 07a7c4a..a860e03 100644 --- a/test/test.py +++ b/test/test.py @@ -41,6 +41,7 @@ def stdout_redirect(): class test_dos_functions(unittest.TestCase): +###不知道在测什么 但是好像测了这个函数test_simple_dos_spikes def test_simple_dos_spikes(self): """Test total DOS / spectrum plotter from CSV data, spike sampling""" ylabel = 'some label' @@ -100,6 +101,7 @@ def test_simple_dos_linear(self): class test_array_functions(unittest.TestCase): +###好像是用来测试delta函数,xy_to_1d函数,gaussian函数的 def test_delta(self): self.assertEqual(galore.delta(1, 1.5, w=1), 1) @@ -125,6 +127,7 @@ def test_gaussian(self): class test_io_functions(unittest.TestCase): +## 好像是用来测试formats这个包里的部分函数的 def setUp(self): self.tempdir = tempfile.mkdtemp() @@ -259,5 +262,3 @@ def test_read_complete_dos(self): csv_test_string = os.linesep.join( ("Frequency,Value", "0,0.0", "1,0.005", "2,0.02", "3,0.045", "4,0.08", "")) -if __name__ == '__main__': - unittest.main() diff --git a/test/test_check_imports.py b/test/test_check_imports.py deleted file mode 100644 index 7e38224..0000000 --- a/test/test_check_imports.py +++ /dev/null @@ -1,100 +0,0 @@ -import unittest -import galore - - - -class test_check_imports(unittest.TestCase): - "We use this to test whether the following functions and packages were imported into galore or not " - - def test_check_get_cross_sections(self): - - try: - from galore import get_cross_section - except ImportError as e: - self.assertEqual(e, None) - - def test_check_cross_sections_info(self): - - try: - from galore import cross_sections_info - except ImportError as e: - self.assertEqual(e, None) - - def test_check_sqrt(self): - - try: - from galore import sqrt - except ImportError as e: - self.assertEqual(e, None) - - def test_check_log(self): - - try: - from galore import log - except ImportError as e: - self.assertEqual(e, None) - - - def test_check_OrderedDict(self): - - try: - from galore import OrderedDict - except ImportError as e: - self.assertEqual(e, None) - - - def test_check_Sequence(self): - - try: - from galore import Sequence - except ImportError as e: - self.assertEqual(e, None) - - - def test_check_logging(self): - - try: - from galore import logging - except ImportError as e: - self.assertEqual(e, None) - - def test_check_print_function(self): - - try: - from galore import print_function - except ImportError as e: - self.assertEqual(e, None) - - - def test_check_interp1d(self): - - try: - from galore import interp1d - except ImportError as e: - self.assertEqual(e, None) - - - - def test_check_numpy(self): - - try: - from galore import np - except ImportError as e: - self.assertEqual(e, None) - - - def test_check_os_path(self): - - try: - from galore import os - except ImportError as e: - self.assertEqual(e, None) - - - - -if __name__ == '__main__': - unittest.main() - - - \ No newline at end of file