diff --git a/.github/workflows/build-wheel-release-upload.yml b/.github/workflows/build-wheel-release-upload.yml index f440716..61b6413 100644 --- a/.github/workflows/build-wheel-release-upload.yml +++ b/.github/workflows/build-wheel-release-upload.yml @@ -10,7 +10,7 @@ jobs: build-release: uses: scikit-package/release-scripts/.github/workflows/_build-wheel-release-upload.yml@v0 with: - project: diffpy.snmf + project: diffpy.stretched-nmf c_extension: false maintainer_GITHUB_username: sbillinge secrets: diff --git a/.github/workflows/check-news-item.yml b/.github/workflows/check-news-item.yml index 1c7c14f..b7224d9 100644 --- a/.github/workflows/check-news-item.yml +++ b/.github/workflows/check-news-item.yml @@ -9,4 +9,4 @@ jobs: check-news-item: uses: scikit-package/release-scripts/.github/workflows/_check-news-item.yml@v0 with: - project: diffpy.snmf + project: diffpy.stretched-nmf diff --git a/.github/workflows/matrix-and-codecov-on-merge-to-main.yml b/.github/workflows/matrix-and-codecov-on-merge-to-main.yml index 5360214..9307194 100644 --- a/.github/workflows/matrix-and-codecov-on-merge-to-main.yml +++ b/.github/workflows/matrix-and-codecov-on-merge-to-main.yml @@ -14,7 +14,7 @@ jobs: matrix-coverage: uses: scikit-package/release-scripts/.github/workflows/_matrix-and-codecov-on-merge-to-main.yml@v0 with: - project: diffpy.snmf + project: diffpy.stretched-nmf c_extension: false headless: false secrets: diff --git a/.github/workflows/publish-docs-on-release.yml b/.github/workflows/publish-docs-on-release.yml index 2f0efbc..c09a545 100644 --- a/.github/workflows/publish-docs-on-release.yml +++ b/.github/workflows/publish-docs-on-release.yml @@ -7,6 +7,6 @@ jobs: docs: uses: scikit-package/release-scripts/.github/workflows/_publish-docs-on-release.yml@v0 with: - project: diffpy.snmf + project: diffpy.stretched-nmf c_extension: false headless: false diff --git a/.github/workflows/tests-on-pr.yml b/.github/workflows/tests-on-pr.yml index 3c428be..9c3aa74 100644 --- a/.github/workflows/tests-on-pr.yml +++ b/.github/workflows/tests-on-pr.yml @@ -8,7 +8,7 @@ jobs: tests-on-pr: uses: scikit-package/release-scripts/.github/workflows/_tests-on-pr.yml@v0 with: - project: diffpy.snmf + project: diffpy.stretched-nmf c_extension: false headless: false secrets: diff --git a/README.rst b/README.rst index f26f845..93e82aa 100644 --- a/README.rst +++ b/README.rst @@ -1,11 +1,11 @@ |Icon| |title|_ =============== -.. |title| replace:: diffpy.snmf -.. _title: https://diffpy.github.io/diffpy.snmf +.. |title| replace:: diffpy.stretched-nmf +.. _title: https://diffpy.github.io/diffpy.stretched-nmf .. |Icon| image:: https://avatars.githubusercontent.com/diffpy - :target: https://diffpy.github.io/diffpy.snmf + :target: https://diffpy.github.io/diffpy.stretched-nmf :height: 100px |PyPI| |Forge| |PythonVersion| |PR| @@ -15,26 +15,26 @@ .. |Black| image:: https://img.shields.io/badge/code_style-black-black :target: https://github.com/psf/black -.. |CI| image:: https://github.com/diffpy/diffpy.snmf/actions/workflows/matrix-and-codecov-on-merge-to-main.yml/badge.svg - :target: https://github.com/diffpy/diffpy.snmf/actions/workflows/matrix-and-codecov-on-merge-to-main.yml +.. |CI| image:: https://github.com/diffpy/diffpy.stretched-nmf/actions/workflows/matrix-and-codecov-on-merge-to-main.yml/badge.svg + :target: https://github.com/diffpy/diffpy.stretched-nmf/actions/workflows/matrix-and-codecov-on-merge-to-main.yml -.. |Codecov| image:: https://codecov.io/gh/diffpy/diffpy.snmf/branch/main/graph/badge.svg - :target: https://codecov.io/gh/diffpy/diffpy.snmf +.. |Codecov| image:: https://codecov.io/gh/diffpy/diffpy.stretched-nmf/branch/main/graph/badge.svg + :target: https://codecov.io/gh/diffpy/diffpy.stretched-nmf -.. |Forge| image:: https://img.shields.io/conda/vn/conda-forge/diffpy.snmf - :target: https://anaconda.org/conda-forge/diffpy.snmf +.. |Forge| image:: https://img.shields.io/conda/vn/conda-forge/diffpy.stretched-nmf + :target: https://anaconda.org/conda-forge/diffpy.stretched-nmf .. |PR| image:: https://img.shields.io/badge/PR-Welcome-29ab47ff - :target: https://github.com/diffpy/diffpy.snmf/pulls + :target: https://github.com/diffpy/diffpy.stretched-nmf/pulls -.. |PyPI| image:: https://img.shields.io/pypi/v/diffpy.snmf - :target: https://pypi.org/project/diffpy.snmf/ +.. |PyPI| image:: https://img.shields.io/pypi/v/diffpy.stretched-nmf + :target: https://pypi.org/project/diffpy.stretched-nmf/ -.. |PythonVersion| image:: https://img.shields.io/pypi/pyversions/diffpy.snmf - :target: https://pypi.org/project/diffpy.snmf/ +.. |PythonVersion| image:: https://img.shields.io/pypi/pyversions/diffpy.stretched-nmf + :target: https://pypi.org/project/diffpy.stretched-nmf/ .. |Tracking| image:: https://img.shields.io/badge/issue_tracking-github-blue - :target: https://github.com/diffpy/diffpy.snmf/issues + :target: https://github.com/diffpy/diffpy.stretched-nmf/issues A python package implementing the stretched NMF algorithm. @@ -43,12 +43,12 @@ on the independent variable axis. For example, for powder diffraction data taken chemical phases where the measurements were done at different temperatures and the materials were undergoing thermal expansion. -For more information about the diffpy.snmf library, please consult our `online documentation `_. +For more information about the diffpy.stretched-nmf library, please consult our `online documentation `_. Citation -------- -If you use diffpy.snmf in a scientific publication, we would like you to cite this package as +If you use diffpy.stretched-nmf in a scientific publication, we would like you to cite this package as Ran Gu, Yevgeny Rakita, Ling Lan, Zach Thatcher, Gabrielle E. Kamm, Daniel O’Nolan, Brennan Mcbride, Allison Wustrow, James R. Neilson, Karena W. Chapman, Qiang Du, and Simon J. L. Billinge, `Stretched Non-negative Matrix Factorization @@ -67,49 +67,49 @@ To add "conda-forge" to the conda channels, run the following in a terminal. :: conda config --add channels conda-forge We want to install our packages in a suitable conda environment. -The following creates and activates a new environment named ``diffpy.snmf_env`` :: +The following creates and activates a new environment named ``diffpy.stretched-nmf_env`` :: - conda create -n diffpy.snmf_env diffpy.snmf - conda activate diffpy.snmf_env + conda create -n diffpy.stretched-nmf_env diffpy.stretched-nmf + conda activate diffpy.stretched-nmf_env The output should print the latest version displayed on the badges above. If the above does not work, you can use ``pip`` to download and install the latest release from `Python Package Index `_. -To install using ``pip`` into your ``diffpy.snmf_env`` environment, type :: +To install using ``pip`` into your ``diffpy.stretched-nmf_env`` environment, type :: - pip install diffpy.snmf + pip install diffpy.stretched-nmf If you prefer to install from sources, after installing the dependencies, obtain the source archive from -`GitHub `_. Once installed, ``cd`` into your ``diffpy.snmf`` directory +`GitHub `_. Once installed, ``cd`` into your ``diffpy.stretched-nmf`` directory and run the following :: pip install . This package also provides command-line utilities. To check the software has been installed correctly, type :: - diffpy.snmf --version + diffpy.stretched-nmf --version You can also type the following command to verify the installation. :: - python -c "import diffpy.snmf; print(diffpy.snmf.__version__)" + python -c "import diffpy.stretched_nmf; print(diffpy.stretched_nmf.__version__)" To view the basic usage and available commands, type :: - diffpy.snmf -h + diffpy.stretched-nmf -h Getting Started --------------- -You may consult our `online documentation `_ for tutorials and API references. +You may consult our `online documentation `_ for tutorials and API references. Support and Contribute ---------------------- -If you see a bug or want to request a feature, please `report it as an issue `_ and/or `submit a fix as a PR `_. +If you see a bug or want to request a feature, please `report it as an issue `_ and/or `submit a fix as a PR `_. -Feel free to fork the project and contribute. To install diffpy.snmf +Feel free to fork the project and contribute. To install diffpy.stretched-nmf in a development mode, with its sources being directly used by Python rather than copied to a package directory, use the following in the root directory :: @@ -130,14 +130,14 @@ trying to commit again. Improvements and fixes are always appreciated. -Before contributing, please read our `Code of Conduct `_. +Before contributing, please read our `Code of Conduct `_. Contact ------- -For more information on diffpy.snmf please visit the project `web-page `_ or email Simon Billinge at sb2896@columbia.edu. +For more information on diffpy.stretched-nmf please visit the project `web-page `_ or email Simon Billinge at sb2896@columbia.edu. Acknowledgements ---------------- -``diffpy.snmf`` is built and maintained with `scikit-package `_. +``diffpy.stretched-nmf`` is built and maintained with `scikit-package `_. diff --git a/cookiecutter.json b/cookiecutter.json index e7ef6b7..0bd986a 100644 --- a/cookiecutter.json +++ b/cookiecutter.json @@ -4,11 +4,11 @@ "maintainer_github_username": "sbillinge", "contributors": "Simon Billinge, John Halloran, Billinge Group members", "license_holders": "The Trustees of Columbia University in the City of New York", - "project_name": "diffpy.snmf", + "project_name": "diffpy.stretched-nmf", "github_username_or_orgname": "diffpy", - "github_repo_name": "diffpy.snmf", - "conda_pypi_package_dist_name": "diffpy.snmf", - "package_dir_name": "diffpy.snmf", + "github_repo_name": "diffpy.stretched-nmf", + "conda_pypi_package_dist_name": "diffpy.stretched-nmf", + "package_dir_name": "diffpy.stretched_nmf", "project_short_description": "A python package implementing the stretched NMF algorithm.", "project_keywords": "diffraction, PDF, x-ray, mapping", "minimum_supported_python_version": "3.11", diff --git a/docs/Makefile b/docs/Makefile index fdc96a7..e4b8eaf 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -6,7 +6,7 @@ SPHINXOPTS = SPHINXBUILD = sphinx-build PAPER = BUILDDIR = build -BASENAME = $(subst .,,$(subst $() $(),,diffpy.snmf)) +BASENAME = $(subst .,,$(subst $() $(),,diffpy.stretched-nmf)) # User-friendly check for sphinx-build ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) diff --git a/docs/source/api/snmf_class.rst b/docs/source/api/snmf_class.rst index 955f678..1fae6ea 100644 --- a/docs/source/api/snmf_class.rst +++ b/docs/source/api/snmf_class.rst @@ -1,7 +1,7 @@ SNMFOptimizer ============= -.. autoclass:: diffpy.snmf.snmf_class.SNMFOptimizer +.. autoclass:: diffpy.stretched_nmf.snmf_class.SNMFOptimizer :members: __init__, fit :undoc-members: :show-inheritance: diff --git a/docs/source/conf.py b/docs/source/conf.py index f9afe77..3582f01 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -1,7 +1,7 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- # -# diffpy.snmf documentation build configuration file, created by # noqa: E501 +# diffpy.stretched-nmf documentation build configuration file, created by # noqa: E501 # sphinx-quickstart on Thu Jan 30 15:49:41 2014. # # This file is execfile()d with the current directory set to its @@ -20,7 +20,7 @@ # Attempt to import the version dynamically from GitHub tag. try: - fullversion = version("diffpy.snmf") + fullversion = version("diffpy.stretched-nmf") except Exception: fullversion = "No version found. The correct version will appear in the released version." # noqa: E501 @@ -68,7 +68,7 @@ master_doc = "index" # General information about the project. -project = "diffpy.snmf" +project = "diffpy.stretched-nmf" copyright = "%Y, The Trustees of Columbia University in the City of New York" # The version info for the project you're documenting, acts as replacement for @@ -122,7 +122,7 @@ pygments_style = "sphinx" # A list of ignored prefixes for module index sorting. -modindex_common_prefix = ["diffpy.snmf"] +modindex_common_prefix = ["diffpy.stretched_nmf"] # Display all warnings for missing links. nitpicky = True @@ -137,7 +137,7 @@ html_context = { "display_github": True, "github_user": "diffpy", - "github_repo": "diffpy.snmf", + "github_repo": "diffpy.stretched-nmf", "github_version": "main", "conf_py_path": "/docs/source/", } @@ -221,7 +221,7 @@ # html_file_suffix = None # Output file base name for HTML help builder. -basename = "diffpy.snmf".replace(" ", "").replace(".", "") +basename = "diffpy.stretched-nmf".replace(" ", "").replace(".", "") htmlhelp_basename = basename + "doc" @@ -242,8 +242,8 @@ latex_documents = [ ( "index", - "diffpy.snmf.tex", - "diffpy.snmf Documentation", + "diffpy.stretched-nmf.tex", + "diffpy.stretched-nmf Documentation", ab_authors, "manual", ), @@ -277,8 +277,8 @@ man_pages = [ ( "index", - "diffpy.snmf", - "diffpy.snmf Documentation", + "diffpy.stretched-nmf", + "diffpy.stretched-nmf Documentation", ab_authors, 1, ) @@ -296,10 +296,10 @@ texinfo_documents = [ ( "index", - "diffpy.snmf", - "diffpy.snmf Documentation", + "diffpy.stretched-nmf", + "diffpy.stretched-nmf Documentation", ab_authors, - "diffpy.snmf", + "diffpy.stretched-nmf", "One line description of project.", "Miscellaneous", ), diff --git a/docs/source/getting-started.rst b/docs/source/getting-started.rst index 0dac4fd..92dd3f2 100644 --- a/docs/source/getting-started.rst +++ b/docs/source/getting-started.rst @@ -3,7 +3,7 @@ Getting started =============== -``diffpy.snmf`` implements the stretched NMF algorithm for factorizing signal +``diffpy.stretched-nmf`` implements the stretched NMF algorithm for factorizing signal sets while accounting for uniform stretching along the independent axis. Installation @@ -14,14 +14,14 @@ The preferred method is conda: .. code-block:: bash conda config --add channels conda-forge - conda create -n diffpy.snmf_env diffpy.snmf - conda activate diffpy.snmf_env + conda create -n diffpy.stretched-nmf_env diffpy.stretched-nmf + conda activate diffpy.stretched-nmf_env Alternatively, install from PyPI with pip: .. code-block:: bash - pip install diffpy.snmf + pip install diffpy.stretched-nmf For source installs (after cloning the repo): @@ -36,8 +36,8 @@ Verify the CLI and Python import: .. code-block:: bash - diffpy.snmf --version - python -c "import diffpy.snmf; print(diffpy.snmf.__version__)" + diffpy.stretched-nmf --version + python -c "import diffpy.stretched_nmf; print(diffpy.stretched_nmf.__version__)" Basic usage ----------- @@ -49,7 +49,7 @@ or ``init_weights``. .. code-block:: python import numpy as np - from diffpy.snmf.snmf_class import SNMFOptimizer + from diffpy.stretched_nmf.snmf_class import SNMFOptimizer rng = np.random.default_rng(0) # Example data: 200 points across 8 signals diff --git a/docs/source/index.rst b/docs/source/index.rst index 69b5af7..9d896f5 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -2,9 +2,9 @@ |title| ####### -.. |title| replace:: diffpy.snmf documentation +.. |title| replace:: diffpy.stretched-nmf documentation -``diffpy.snmf`` - A python package implementing the stretched NMF algorithm. +``diffpy.stretched-nmf`` - A python package implementing the stretched NMF algorithm. | Software version |release| | Last updated |today|. @@ -13,7 +13,7 @@ Getting started =============== -Welcome to the ``diffpy.snmf`` documentation! +Welcome to the ``diffpy.stretched-nmf`` documentation! To get started, please visit the :ref:`Getting started ` page. @@ -21,21 +21,21 @@ To get started, please visit the :ref:`Getting started ` page. Authors ======= -``diffpy.snmf`` is developed by Simon Billinge, John Halloran, Billinge Group members. The maintainer for this project is Simon Billinge. For a detailed list of contributors see -https://github.com/diffpy/diffpy.snmf/graphs/contributors. +``diffpy.stretched-nmf`` is developed by Simon Billinge, John Halloran, Billinge Group members. The maintainer for this project is Simon Billinge. For a detailed list of contributors see +https://github.com/diffpy/diffpy.stretched-nmf/graphs/contributors. ============ Installation ============ -See the `README `_ +See the `README `_ file included with the distribution. ================ Acknowledgements ================ -``diffpy.snmf`` is built and maintained with `scikit-package `_. +``diffpy.stretched-nmf`` is built and maintained with `scikit-package `_. ================= Table of contents diff --git a/news/package-name-update.rst b/news/package-name-update.rst new file mode 100644 index 0000000..6ffeaaa --- /dev/null +++ b/news/package-name-update.rst @@ -0,0 +1,23 @@ +**Added:** + +* + +**Changed:** + +* Move project/package naming and related references to the new ``diffpy.stretched-nmf`` name. + +**Deprecated:** + +* + +**Removed:** + +* + +**Fixed:** + +* Register ``pytest.mark.slow`` in pytest config to avoid unknown-marker warnings. + +**Security:** + +* diff --git a/pyproject.toml b/pyproject.toml index 2aa9db9..0fd01b2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,7 @@ requires = ["setuptools>=62.0", "setuptools-git-versioning>=2.0"] build-backend = "setuptools.build_meta" [project] -name = "diffpy.snmf" +name = "diffpy.stretched-nmf" dynamic=['version', 'dependencies'] authors = [ { name="Simon Billinge", email="sb2896@columbia.edu" }, @@ -33,8 +33,8 @@ classifiers = [ ] [project.urls] -Homepage = "https://github.com/diffpy/diffpy.snmf/" -Issues = "https://github.com/diffpy/diffpy.snmf/issues/" +Homepage = "https://github.com/diffpy/diffpy.stretched-nmf/" +Issues = "https://github.com/diffpy/diffpy.stretched-nmf/issues/" [tool.setuptools-git-versioning] enabled = true @@ -49,7 +49,7 @@ exclude = [] # exclude packages matching these glob patterns (empty by default) namespaces = false # to disable scanning PEP 420 namespaces (true by default) [project.scripts] -diffpy-snmf = "diffpy.snmf.app:main" +"diffpy.stretched-nmf" = "diffpy.stretched_nmf.snmf_app:main" [tool.setuptools.dynamic] dependencies = {file = ["requirements/pip.txt"]} @@ -86,3 +86,8 @@ exclude = ''' | tests/data )/ ''' + +[tool.pytest.ini_options] +markers = [ + "slow: marks tests as slow (deselect with '-m \"not slow\"')", +] diff --git a/src/diffpy/__init__.py b/src/diffpy/__init__.py index 71a432f..c98b6cd 100644 --- a/src/diffpy/__init__.py +++ b/src/diffpy/__init__.py @@ -7,7 +7,7 @@ # File coded by: Billinge Group members and community contributors. # # See GitHub contributions for a more detailed list of contributors. -# https://github.com/diffpy/diffpy.snmf/graphs/contributors +# https://github.com/diffpy/diffpy.stretched-nmf/graphs/contributors # # See LICENSE.rst for license information. # diff --git a/src/diffpy/snmf/__init__.py b/src/diffpy/stretched_nmf/__init__.py similarity index 82% rename from src/diffpy/snmf/__init__.py rename to src/diffpy/stretched_nmf/__init__.py index 39c0437..280f216 100644 --- a/src/diffpy/snmf/__init__.py +++ b/src/diffpy/stretched_nmf/__init__.py @@ -7,7 +7,7 @@ # File coded by: Simon Billinge, John Halloran, Billinge Group members. # # See GitHub contributions for a more detailed list of contributors. -# https://github.com/diffpy/diffpy.snmf/graphs/contributors +# https://github.com/diffpy/diffpy.stretched-nmf/graphs/contributors # # See LICENSE.rst for license information. # @@ -15,7 +15,7 @@ """A python package implementing the stretched NMF algorithm.""" # package version -from diffpy.snmf.version import __version__ # noqa +from diffpy.stretched_nmf.version import __version__ # noqa # silence the pyflakes syntax checker assert __version__ or True diff --git a/src/diffpy/snmf/main.py b/src/diffpy/stretched_nmf/main.py similarity index 93% rename from src/diffpy/snmf/main.py rename to src/diffpy/stretched_nmf/main.py index 25127b4..757410b 100644 --- a/src/diffpy/snmf/main.py +++ b/src/diffpy/stretched_nmf/main.py @@ -1,6 +1,6 @@ import numpy as np -from diffpy.snmf.snmf_class import SNMFOptimizer +from diffpy.stretched_nmf.snmf_class import SNMFOptimizer # Example input files (not provided) init_components_file = np.loadtxt("inputs/init_components.txt", dtype=float) diff --git a/src/diffpy/snmf/plotter.py b/src/diffpy/stretched_nmf/plotter.py similarity index 100% rename from src/diffpy/snmf/plotter.py rename to src/diffpy/stretched_nmf/plotter.py diff --git a/src/diffpy/snmf/snmf_app.py b/src/diffpy/stretched_nmf/snmf_app.py similarity index 74% rename from src/diffpy/snmf/snmf_app.py rename to src/diffpy/stretched_nmf/snmf_app.py index 5d3550f..57f6397 100644 --- a/src/diffpy/snmf/snmf_app.py +++ b/src/diffpy/stretched_nmf/snmf_app.py @@ -1,15 +1,15 @@ import argparse -from diffpy.snmf.version import __version__ # noqa +from diffpy.stretched_nmf.version import __version__ # noqa def main(): parser = argparse.ArgumentParser( - prog="diffpy.snmf", + prog="diffpy.stretched-nmf", description=( "A python package implementing the stretched NMF algorithm.\n\n" "For more information, visit: " - "https://github.com/diffpy/diffpy.snmf/" + "https://github.com/diffpy/diffpy.stretched-nmf/" ), formatter_class=argparse.RawDescriptionHelpFormatter, ) @@ -23,7 +23,7 @@ def main(): args = parser.parse_args() if args.version: - print(f"diffpy.snmf {__version__}") + print(f"diffpy.stretched-nmf {__version__}") else: # Default behavior when no arguments are given parser.print_help() diff --git a/src/diffpy/snmf/snmf_class.py b/src/diffpy/stretched_nmf/snmf_class.py similarity index 99% rename from src/diffpy/snmf/snmf_class.py rename to src/diffpy/stretched_nmf/snmf_class.py index db983a3..d5f6603 100644 --- a/src/diffpy/snmf/snmf_class.py +++ b/src/diffpy/stretched_nmf/snmf_class.py @@ -3,12 +3,12 @@ from scipy.optimize import minimize from scipy.sparse import coo_matrix, diags -from diffpy.snmf.plotter import SNMFPlotter +from diffpy.stretched_nmf.plotter import SNMFPlotter class SNMFOptimizer: - """An implementation of stretched NMF (sNMF), including sparse - stretched NMF. + """An implementation of stretched NMF, including sparse stretched + NMF. Instantiating the SNMFOptimizer class prepares initial guesses and sets up the optimization. It can then be run using fit(). The results matrices can diff --git a/src/diffpy/snmf/version.py b/src/diffpy/stretched_nmf/version.py similarity index 85% rename from src/diffpy/snmf/version.py rename to src/diffpy/stretched_nmf/version.py index 73004a2..0cbb046 100644 --- a/src/diffpy/snmf/version.py +++ b/src/diffpy/stretched_nmf/version.py @@ -7,7 +7,7 @@ # File coded by: Simon Billinge, John Halloran, Billinge Group members. # # See GitHub contributions for a more detailed list of contributors. -# https://github.com/diffpy/diffpy.snmf/graphs/contributors # noqa: E501 +# https://github.com/diffpy/diffpy.stretched-nmf/graphs/contributors # noqa: E501 # # See LICENSE.rst for license information. # @@ -21,6 +21,6 @@ from importlib.metadata import PackageNotFoundError, version try: - __version__ = version("diffpy.snmf") + __version__ = version("diffpy.stretched-nmf") except PackageNotFoundError: __version__ = "unknown" diff --git a/tests/test_snmf_optimizer.py b/tests/test_snmf_optimizer.py index 6c7f51b..aa316fb 100644 --- a/tests/test_snmf_optimizer.py +++ b/tests/test_snmf_optimizer.py @@ -3,7 +3,7 @@ import numpy as np import pytest -from diffpy.snmf.snmf_class import SNMFOptimizer +from diffpy.stretched_nmf.snmf_class import SNMFOptimizer DATA_DIR = Path(__file__).parent / "inputs/test_snmf_optimizer" diff --git a/tests/test_version.py b/tests/test_version.py index cac0822..b365d7d 100644 --- a/tests/test_version.py +++ b/tests/test_version.py @@ -1,10 +1,10 @@ """Unit tests for __version__.py.""" -import diffpy.snmf # noqa +import diffpy.stretched_nmf # noqa def test_package_version(): """Ensure the package version is defined and not set to the initial placeholder.""" - assert hasattr(diffpy.snmf, "__version__") - assert diffpy.snmf.__version__ != "0.0.0" + assert hasattr(diffpy.stretched_nmf, "__version__") + assert diffpy.stretched_nmf.__version__ != "0.0.0"