diff -Nru pydl-1.0.0~rc1/debian/changelog pydl-1.0.0~rc2/debian/changelog --- pydl-1.0.0~rc1/debian/changelog 2020-11-11 18:05:33.000000000 +0000 +++ pydl-1.0.0~rc2/debian/changelog 2021-09-19 16:19:36.000000000 +0000 @@ -1,3 +1,13 @@ +pydl (1.0.0~rc2-1) unstable; urgency=medium + + * New upstram release + * Change d/watch to use Github instead of PyPI + * Replace Homepage field in d/control + * Update Standards-Version to 4.6.0.1 (no change needed) + * Remove unused signing key + + -- Vincent Prat Sun, 19 Sep 2021 18:19:36 +0200 + pydl (1.0.0~rc1-2) unstable; urgency=medium [ Debian Janitor ] diff -Nru pydl-1.0.0~rc1/debian/control pydl-1.0.0~rc2/debian/control --- pydl-1.0.0~rc1/debian/control 2020-11-11 18:05:33.000000000 +0000 +++ pydl-1.0.0~rc2/debian/control 2021-09-19 16:19:36.000000000 +0000 @@ -16,8 +16,8 @@ python3-setuptools-scm, python3-sphinx, python3-sphinx-astropy -Standards-Version: 4.5.0 -Homepage: https://pypi.python.org/pypi/pydl/ +Standards-Version: 4.6.0.1 +Homepage: https://github.com/weaverba137/pydl Vcs-Browser: https://salsa.debian.org/debian-astro-team/pydl Vcs-Git: https://salsa.debian.org/debian-astro-team/pydl.git Rules-Requires-Root: no diff -Nru pydl-1.0.0~rc1/debian/upstream/signing-key.asc pydl-1.0.0~rc2/debian/upstream/signing-key.asc --- pydl-1.0.0~rc1/debian/upstream/signing-key.asc 2020-05-04 16:35:34.000000000 +0000 +++ pydl-1.0.0~rc2/debian/upstream/signing-key.asc 1970-01-01 00:00:00.000000000 +0000 @@ -1,51 +0,0 @@ ------BEGIN PGP PUBLIC KEY BLOCK----- - -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 -=RcCw ------END PGP PUBLIC KEY BLOCK----- diff -Nru pydl-1.0.0~rc1/debian/watch pydl-1.0.0~rc2/debian/watch --- pydl-1.0.0~rc1/debian/watch 2020-05-04 16:35:34.000000000 +0000 +++ pydl-1.0.0~rc2/debian/watch 2021-09-19 16:19:36.000000000 +0000 @@ -1,5 +1,4 @@ version=4 -opts=dversionmangle=s/\+dfsg\d*//,\ -uversionmangle=s/(\d)[_\.\-\+]?((RC|rc|pre)\d*)$/$1~$2/,\ -pgpsigurlmangle=s/$/.asc/ \ - https://pypi.debian.net/pydl/pydl-(\d[.prec\d]*)\.tar\.gz +opts=filenamemangle=s/.+\/v?(\d\S+)\.tar\.gz/pydl-$1\.tar\.gz/,\ +uversionmangle=s/(\d)[_\.\-\+]?((RC|rc|pre)\d*)$/$1~$2/ \ + https://github.com/weaverba137/pydl/releases .*/v?(\d\S+)\.tar\.gz diff -Nru pydl-1.0.0~rc1/docs/changes.rst pydl-1.0.0~rc2/docs/changes.rst --- pydl-1.0.0~rc1/docs/changes.rst 2020-04-28 21:02:12.000000000 +0000 +++ pydl-1.0.0~rc2/docs/changes.rst 2021-07-22 21:35:35.000000000 +0000 @@ -2,6 +2,18 @@ PyDL Changelog ============== +1.0.0rc2 (2021-07-22) +--------------------- + +* Updates to package infrastructure (PR `#63`_). +* Update idlutils tag for SDSS bitmasks (PR `#62`_). +* Document behavior of :func:`pydl.rebin` for integer inputs; begin migration + to GitHub Actions for CI (PR `#61`_). + +.. _`#61`: https://github.com/weaverba137/pydl/pull/61 +.. _`#62`: https://github.com/weaverba137/pydl/pull/62 +.. _`#63`: https://github.com/weaverba137/pydl/pull/63 + 1.0.0rc1 (2020-04-28) --------------------- diff -Nru pydl-1.0.0~rc1/docs/conf.py pydl-1.0.0~rc2/docs/conf.py --- pydl-1.0.0~rc1/docs/conf.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/docs/conf.py 2021-07-22 21:35:35.000000000 +0000 @@ -52,7 +52,7 @@ #needs_sphinx = '1.2' # To perform a Sphinx version check that needs to be more specific than -# major.minor, call `check_sphinx_version("x.y.z")` here. +# major.minor, call `check_sphinx_version("X.Y.Z")` here. # check_sphinx_version("1.2.1") # List of patterns, relative to source directory, that match files and @@ -135,6 +135,9 @@ # Output file base name for HTML help builder. htmlhelp_basename = project + 'doc' +# Prefixes that are ignored for sorting the Python module index +modindex_common_prefix = ["pydl."] + # -- Options for LaTeX output ------------------------------------------------- @@ -159,7 +162,7 @@ extensions += ['sphinx_astropy.ext.edit_on_github'] edit_on_github_project = setup_cfg['github_project'] - edit_on_github_branch = "master" + edit_on_github_branch = "main" edit_on_github_source_root = "" edit_on_github_doc_root = "docs" @@ -167,6 +170,15 @@ # -- Resolving issue number to links in changelog ----------------------------- github_issues_url = 'https://github.com/{0}/issues/'.format(setup_cfg['github_project']) + +# -- Options for linkcheck output ------------------------------------------- +linkcheck_retry = 5 +linkcheck_ignore = [ + r'https://github\.com/astropy/astropy/(?:issues|pull)/\d+', +] +linkcheck_timeout = 180 +linkcheck_anchors = False + # -- Turn on nitpicky mode for sphinx (to warn about references not found) ---- # # nitpicky = True diff -Nru pydl-1.0.0~rc1/.github/workflows/ci_cron_weekly.yml pydl-1.0.0~rc2/.github/workflows/ci_cron_weekly.yml --- pydl-1.0.0~rc1/.github/workflows/ci_cron_weekly.yml 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/.github/workflows/ci_cron_weekly.yml 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,27 @@ +# GitHub Actions workflow that runs on a cron schedule. + +name: Cron Scheduled CI Tests + +on: + schedule: + # run at 6am UTC on Mondays + - cron: '0 6 * * 1' + +jobs: + # Testing links in documents is a good example of something to run on a schedule + # to catch links that stop working for some reason. + doc_test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set up Python to build docs with sphinx + uses: actions/setup-python@v2 + with: + python-version: 3.8 + - name: Install base dependencies + run: | + python -m pip install --upgrade pip + python -m pip install tox + - name: Check links in docs using tox + run: | + tox -e linkcheck diff -Nru pydl-1.0.0~rc1/.github/workflows/ci_tests.yml pydl-1.0.0~rc2/.github/workflows/ci_tests.yml --- pydl-1.0.0~rc1/.github/workflows/ci_tests.yml 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/.github/workflows/ci_tests.yml 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,86 @@ +# GitHub Actions workflow for testing and continuous integration. +# +# This file performs testing using tox and tox.ini to define and configure the test environments. + +name: CI Tests + +on: + push: + branches: + - main # GitHub now defaults to 'main' as the name of the primary branch. Change this as needed. + # tags: # run CI if specific tags are pushed + pull_request: + # branches: # only build on PRs against 'main' if you need to further limit when CI is run. + # - main + +jobs: + # Github Actions supports ubuntu, windows, and macos virtual environments: + # https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners + ci_tests: + name: ${{ matrix.name }} + runs-on: ${{ matrix.os }} + strategy: + matrix: + include: + - name: Code style checks + os: ubuntu-latest + python: 3.x + toxenv: codestyle + + - name: Python 3.7 with minimal dependencies + os: ubuntu-latest + python: 3.7 + toxenv: py37-test + + - name: Python 3.8 with all optional dependencies and coverage checking + os: ubuntu-latest + python: 3.8 + toxenv: py38-test-alldeps-cov + + - name: OS X - Python 3.8 with all optional dependencies + os: macos-latest + python: 3.8 + toxenv: py38-test-alldeps + + - name: Windows - Python 3.8 with all optional dependencies + os: windows-latest + python: 3.8 + toxenv: py38-test-alldeps + + # - name: Python 3.7 with oldest supported version of all dependencies + # os: ubuntu-16.04 + # python: 3.7 + # toxenv: py37-test-oldestdeps + + # - name: Python 3.8 with latest dev versions of key dependencies + # os: ubuntu-latest + # python: 3.8 + # toxenv: py38-test-devdeps + + - name: Test building of Sphinx docs + os: ubuntu-latest + python: 3.8 + toxenv: build_docs + + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + fetch-depth: 0 + - name: Set up python ${{ matrix.python }} on ${{ matrix.os }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python }} + - name: Install base dependencies + run: | + python -m pip install --upgrade pip + python -m pip install tox coveralls + - name: Install graphviz dependency + if: "endsWith(matrix.toxenv, 'build_docs')" + run: sudo apt-get -y install graphviz + - name: Test with tox + env: + COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + tox -e ${{ matrix.toxenv }} diff -Nru pydl-1.0.0~rc1/.gitignore pydl-1.0.0~rc2/.gitignore --- pydl-1.0.0~rc1/.gitignore 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/.gitignore 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,68 @@ +# Compiled files +*.py[cod] +*.a +*.o +*.so +__pycache__ + +# Ignore .c files by default to avoid including generated code. If you want to +# add a non-generated .c extension, use `git add -f filename.c`. +*.c + +# Other generated files +*/version.py +*/cython_version.py +htmlcov +.coverage +MANIFEST +.ipynb_checkpoints +.pytest_cache +pydl/pydl.cfg + +# Sphinx +docs/api +docs/_build + +# Eclipse editor project files +.project +.pydevproject +.settings + +# Pycharm editor project files +.idea + +# Floobits project files +.floo +.flooignore + +# Visual Studio Code project files +.vscode + +# Packages/installer info +*.egg +*.egg-info +dist +build +eggs +.eggs +parts +bin +var +sdist +develop-eggs +.installed.cfg +distribute-*.tar.gz + +# Other +.cache +.tmp +.tox +.*.sw[op] +*~ +.project +.pydevproject +.settings +pip-wheel-metadata/ + +# Mac OSX +.DS_Store diff -Nru pydl-1.0.0~rc1/MANIFEST.in pydl-1.0.0~rc2/MANIFEST.in --- pydl-1.0.0~rc1/MANIFEST.in 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/MANIFEST.in 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,19 @@ +include README.rst +# include CHANGES.rst +include setup.cfg +include LICENSE.rst +include pyproject.toml + +# recursive-include pydl *.pyx *.c *.pxd +recursive-include docs * +recursive-include pydl/*/data/* * +recursive-include pydl/tests/t * +recursive-include pydl/*/tests/t * +# recursive-include cextern * +# recursive-include scripts * + +prune build +prune docs/_build +prune docs/api + +global-exclude *.pyc *.o diff -Nru pydl-1.0.0~rc1/PKG-INFO pydl-1.0.0~rc2/PKG-INFO --- pydl-1.0.0~rc1/PKG-INFO 2020-04-28 21:02:45.000000000 +0000 +++ pydl-1.0.0~rc2/PKG-INFO 1970-01-01 00:00:00.000000000 +0000 @@ -1,112 +0,0 @@ -Metadata-Version: 2.1 -Name: pydl -Version: 1.0.0rc1 -Summary: Astropy affiliated package -Home-page: http://github.com/weaverba137/pydl -Author: Benjamin Alan Weaver -Author-email: baweaver@lbl.gov -License: BSD 3-Clause License -Description: ==== - PyDL - ==== - - .. image:: http://img.shields.io/badge/powered%20by-AstroPy-orange.svg?style=flat - :target: http://www.astropy.org - :alt: Powered by Astropy Badge - - .. image:: https://img.shields.io/pypi/l/pydl.svg - :target: https://pypi.python.org/pypi/pydl - :alt: License - - .. image:: https://zenodo.org/badge/DOI/10.5281/zenodo.2575874.svg - :target: https://doi.org/10.5281/zenodo.2575874 - :alt: DOI: 10.5281/zenodo.2575874 - - .. image:: https://img.shields.io/pypi/v/pydl.svg - :target: https://pypi.python.org/pypi/pydl - :alt: PyPI Badge - - .. image:: https://img.shields.io/travis/weaverba137/pydl.svg - :target: https://travis-ci.org/weaverba137/pydl - :alt: Travis Build Status - - .. image:: https://coveralls.io/repos/weaverba137/pydl/badge.svg?branch=master&service=github - :target: https://coveralls.io/github/weaverba137/pydl?branch=master - :alt: Test Coverage Status - - .. image:: https://readthedocs.org/projects/pydl/badge/?version=latest - :target: http://pydl.readthedocs.org/en/latest/ - :alt: Documentation Status - - Description - ----------- - - This package consists of Python_ replacements for functions that are part of - the `IDL®`_ built-in library or part of astronomical `IDL®`_ libraries. - The emphasis is on reproducing results of the astronomical library functions. - Only the bare minimum of `IDL®`_ built-in functions are implemented to support this. - - There are four astronomical libraries targeted: - - * idlutils_ : a general suite of tools heavily used by SDSS_. - * `Goddard utilities`_ : The `IDL®`_ Astronomy User's Libary, maintained by Wayne Landsman and distributed with idlutils_. - * idlspec2d_ : tools for working with SDSS_, BOSS_ and eBOSS_ spectroscopic data. - * photoop_ : tools for working with SDSS_ imaging data. - - This package affiliated with the astropy_ project and is registered with PyPI_. - - Full Documentation - ------------------ - - Please visit `PyDL on Read the Docs`_ - - History - ------- - - This package was initially developed on the SDSS-III_ `svn repository`_. It was - moved to the new GitHub_ repository on 2013-03-06. The present location of - the repository is http://github.com/weaverba137/pydl . - - License - ------- - - PyDL is free software licensed under a 3-clause BSD-style license. For details see - the ``LICENSE.rst`` file. - - Legal - ----- - - * IDL is a registered trademark of `Harris Geospatial Solutions`_. - - .. _Python: https://www.python.org - .. _`IDL®`: https://www.harrisgeospatial.com/Software-Technology/IDL - .. _idlutils: https://www.sdss.org/dr16/software/idlutils/ - .. _SDSS: https://www.sdss.org - .. _`Goddard utilities`: https://idlastro.gsfc.nasa.gov/ - .. _idlspec2d: https://svn.sdss.org/public/repo/eboss/idlspec2d/trunk/ - .. _BOSS: https://www.sdss.org/surveys/boss/ - .. _eBOSS: https://www.sdss.org/surveys/eboss/ - .. _photoop: https://svn.sdss.org/public/repo/sdss/photoop/trunk/ - .. _astropy: http://www.astropy.org - .. _PyPI: https://pypi.python.org/pypi/pydl/ - .. _`PyDL on Read the Docs`: https://pydl.readthedocs.io/en/latest/ - .. _SDSS-III: http://www.sdss3.org - .. _`svn repository`: https://www.sdss.org/dr16/software/products/ - .. _GitHub: https://github.com - .. _`Harris Geospatial Solutions`: https://www.harrisgeospatial.com/ - -Platform: UNKNOWN -Classifier: Development Status :: 5 - Production/Stable -Classifier: Environment :: Console -Classifier: Intended Audience :: Science/Research -Classifier: License :: OSI Approved :: BSD License -Classifier: Operating System :: OS Independent -Classifier: Programming Language :: Python :: 3 -Classifier: Topic :: Scientific/Engineering :: Physics -Classifier: Topic :: Scientific/Engineering :: Astronomy -Requires-Python: >=3.6 -Description-Content-Type: text/x-rst -Provides-Extra: all -Provides-Extra: test -Provides-Extra: astropy20 -Provides-Extra: docs diff -Nru pydl-1.0.0~rc1/pydl/_astropy_init.py pydl-1.0.0~rc2/pydl/_astropy_init.py --- pydl-1.0.0~rc1/pydl/_astropy_init.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/_astropy_init.py 2021-07-22 21:35:35.000000000 +0000 @@ -1,52 +1,13 @@ # Licensed under a 3-clause BSD style license - see LICENSE.rst +import os -__all__ = ['__version__'] - -# this indicates whether or not we are in the package's setup.py -try: - _ASTROPY_SETUP_ -except NameError: - import builtins - builtins._ASTROPY_SETUP_ = False +__all__ = ['__version__', 'test'] try: from .version import version as __version__ except ImportError: __version__ = '' - -if not _ASTROPY_SETUP_: # noqa - import os - from warnings import warn - from astropy.config.configuration import ( - update_default_config, - ConfigurationDefaultMissingError, - ConfigurationDefaultMissingWarning) - - # Create the test function for self test - from astropy.tests.runner import TestRunner - test = TestRunner.make_test_runner_in(os.path.dirname(__file__)) - test.__test__ = False - __all__ += ['test'] - - # add these here so we only need to cleanup the namespace at the end - config_dir = None - - if not os.environ.get('ASTROPY_SKIP_CONFIG_UPDATE', False): - config_dir = os.path.dirname(__file__) - config_template = os.path.join(config_dir, __package__ + ".cfg") - if os.path.isfile(config_template): - try: - update_default_config( - __package__, config_dir, version=__version__) - except TypeError as orig_error: - try: - update_default_config(__package__, config_dir) - except ConfigurationDefaultMissingError as e: - wmsg = (e.args[0] + - " Cannot install default profile. If you are " - "importing from source, this is expected.") - warn(ConfigurationDefaultMissingWarning(wmsg)) - del e - except Exception: - raise orig_error +# Create the test function for self test +from astropy.tests.runner import TestRunner +test = TestRunner.make_test_runner_in(os.path.dirname(__file__)) diff -Nru pydl-1.0.0~rc1/pydl/conftest.py pydl-1.0.0~rc2/pydl/conftest.py --- pydl-1.0.0~rc1/pydl/conftest.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/conftest.py 2021-07-22 21:35:35.000000000 +0000 @@ -1,7 +1,11 @@ -# This file is used to configure the behavior of pytest when using the Astropy -# test infrastructure. It needs to live inside the package in order for it to -# get picked up when running the tests inside an interpreter using -# packagename.test +"""Configure Test Suite. + +This file is used to configure the behavior of pytest when using the Astropy +test infrastructure. It needs to live inside the package in order for it to +get picked up when running the tests inside an interpreter using +packagename.test + +""" import os @@ -10,7 +14,7 @@ # For Astropy 3.0 and later, we can use the standalone pytest plugin if astropy_version < '3.0': from astropy.tests.pytest_plugins import * # noqa - # del pytest_report_header + del pytest_report_header ASTROPY_HEADER = True else: try: @@ -21,7 +25,13 @@ def pytest_configure(config): + """Configure Pytest with Astropy. + + Parameters + ---------- + config : pytest configuration + """ if ASTROPY_HEADER: config.option.astropy_header = True diff -Nru pydl-1.0.0~rc1/pydl/__init__.py pydl-1.0.0~rc2/pydl/__init__.py --- pydl-1.0.0~rc1/pydl/__init__.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/__init__.py 2021-07-22 21:35:35.000000000 +0000 @@ -16,7 +16,7 @@ # Packages may add whatever they like to this file, but # should keep this content at the top. # ---------------------------------------------------------------------------- -from ._astropy_init import * +from ._astropy_init import * # noqa # ---------------------------------------------------------------------------- # Enforce Python version check during package import. @@ -31,14 +31,13 @@ if sys.version_info < tuple((int(val) for val in __minimum_python_version__.split('.'))): raise UnsupportedPythonError("packagename does not support Python < {}".format(__minimum_python_version__)) -if not _ASTROPY_SETUP_: - # For egg_info test builds to pass, put package imports here. - from .file_lines import file_lines - from .median import median - from .pcomp import pcomp - from .rebin import rebin - from .smooth import smooth - from .uniq import uniq + +from .file_lines import file_lines +from .median import median +from .pcomp import pcomp +from .rebin import rebin +from .smooth import smooth +from .uniq import uniq # Workaround: Numpy 1.14.x changes the way arrays are printed. diff -Nru pydl-1.0.0~rc1/pydl/pydlspec2d/spec1d.py pydl-1.0.0~rc2/pydl/pydlspec2d/spec1d.py --- pydl-1.0.0~rc1/pydl/pydlspec2d/spec1d.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlspec2d/spec1d.py 2021-07-22 21:35:35.000000000 +0000 @@ -250,7 +250,7 @@ Returns ------- - :func:`tuple` of :class:`numpy.ndarray` + :class:`tuple` of :class:`numpy.ndarray` The fitting coefficients and fitted functions, respectively. """ from scipy.cluster.vq import kmeans, whiten @@ -1216,7 +1216,7 @@ Returns ------- - :func:`tuple` of :class:`numpy.ndarray` + :class:`tuple` of :class:`numpy.ndarray` The resampled flux, inverse variance and wavelength solution, respectively. """ @@ -1294,7 +1294,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the list of input spectra and a dictionary containing other metadata. """ diff -Nru pydl-1.0.0~rc1/pydl/pydlspec2d/spec2d.py pydl-1.0.0~rc2/pydl/pydlspec2d/spec2d.py --- pydl-1.0.0~rc1/pydl/pydlspec2d/spec2d.py 2019-02-22 23:39:20.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlspec2d/spec2d.py 2021-07-22 21:35:35.000000000 +0000 @@ -87,7 +87,7 @@ Returns ------- - :func:`tuple` of :class:`numpy.ndarray` + :class:`tuple` of :class:`numpy.ndarray` The resulting flux and inverse variance. Raises diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/bspline.py pydl-1.0.0~rc2/pydl/pydlutils/bspline.py --- pydl-1.0.0~rc1/pydl/pydlutils/bspline.py 2019-02-22 23:39:20.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/bspline.py 2021-07-22 21:35:35.000000000 +0000 @@ -153,7 +153,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing an integer error code, and the evaluation of the b-spline at the input values. An error code of -2 is a failure, -1 indicates dropped breakpoints, 0 is success, and positive @@ -214,7 +214,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the B-spline action matrix; the 'lower' parameter, a list of pixel positions, each corresponding to the first occurence of position greater than breakpoint indx; and 'upper', @@ -345,7 +345,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the results of the bspline evaluation and a mask indicating where the evaluation was good. """ @@ -456,7 +456,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` If problems were detected, the first item will be the index or indexes where the problem was detected, and the second item will simply be the input matrix. If no problems were detected, the first item @@ -546,7 +546,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the fitted bspline object and an output mask. """ nx = xdata.size diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/cooling.py pydl-1.0.0~rc2/pydl/pydlutils/cooling.py --- pydl-1.0.0~rc1/pydl/pydlutils/cooling.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/cooling.py 2021-07-22 21:35:35.000000000 +0000 @@ -21,7 +21,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing `logT` and `loglambda`, respectively. Raises diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/mangle.py pydl-1.0.0~rc2/pydl/pydlutils/mangle.py --- pydl-1.0.0~rc1/pydl/pydlutils/mangle.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/mangle.py 2021-07-22 21:35:35.000000000 +0000 @@ -490,7 +490,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing ``X`` and ``CM`` values for the cap. """ npoints, ncol = points.shape @@ -607,7 +607,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing two :class:`~numpy.ndarray`. First, a boolean vector giving the result for each point. Second, an integer vector giving the index of the polygon that contains the point. diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/math.py pydl-1.0.0~rc2/pydl/pydlutils/math.py --- pydl-1.0.0~rc1/pydl/pydlutils/math.py 2019-02-22 23:39:20.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/math.py 2021-07-22 21:35:35.000000000 +0000 @@ -244,7 +244,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing a mask where rejected data values are ``False`` and a boolean value set to ``True`` if `djs_reject` believes there is no further rejection to be done. diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/misc.py pydl-1.0.0~rc2/pydl/pydlutils/misc.py --- pydl-1.0.0~rc1/pydl/pydlutils/misc.py 2019-03-15 15:53:06.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/misc.py 2021-07-22 21:35:35.000000000 +0000 @@ -251,7 +251,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing a list of the lines in the table. If `html` is ``True``, also returns a list of lines of CSS for formatting the table. diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/rgbcolor.py pydl-1.0.0~rc2/pydl/pydlutils/rgbcolor.py --- pydl-1.0.0~rc1/pydl/pydlutils/rgbcolor.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/rgbcolor.py 2021-07-22 21:35:35.000000000 +0000 @@ -66,7 +66,7 @@ ---------- colors : :class:`~numpy.ndarray` 3D Array containing RGB image. The dimensions should be (X, Y, 3). - origin : :func:`tuple` or :class:`~numpy.ndarray` + origin : :class:`tuple` or :class:`~numpy.ndarray` An array with 3 elements. The "distance" from this origin is considered saturated. @@ -132,7 +132,7 @@ ---------- colors : :class:`~numpy.ndarray` 3D Array containing RGB image. The dimensions should be (X, Y, 3). - scales : :func:`tuple` or :class:`~numpy.ndarray`, optional + scales : :class:`tuple` or :class:`~numpy.ndarray`, optional An array with 3 elements. Returns diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/sdss.py pydl-1.0.0~rc2/pydl/pydlutils/sdss.py --- pydl-1.0.0~rc1/pydl/pydlutils/sdss.py 2019-03-15 15:53:06.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/sdss.py 2021-07-22 21:35:35.000000000 +0000 @@ -157,7 +157,7 @@ Returns ------- - :class:`bool` or :func:`tuple` + :class:`bool` or :class:`tuple` A boolean value or a tuple of bool. """ global maskbits @@ -677,7 +677,7 @@ return None -def set_maskbits(idlutils_version='v5_5_24', maskbits_file=None): +def set_maskbits(idlutils_version='v5_5_33', maskbits_file=None): """Populate the maskbits cache. Parameters diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/spheregroup.py pydl-1.0.0~rc2/pydl/pydlutils/spheregroup.py --- pydl-1.0.0~rc1/pydl/pydlutils/spheregroup.py 2019-03-15 15:53:06.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/spheregroup.py 2021-07-22 21:35:35.000000000 +0000 @@ -496,7 +496,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the group number of each object, the multiplicity of each group, the first member of each group, and the next member of the group for each object. @@ -583,7 +583,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the indices into the first set of points, the indices into the second set of points and the match distance in decimal degrees. diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/trace.py pydl-1.0.0~rc2/pydl/pydlutils/trace.py --- pydl-1.0.0~rc1/pydl/pydlutils/trace.py 2020-01-15 03:41:35.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/trace.py 2021-07-22 21:35:35.000000000 +0000 @@ -169,7 +169,7 @@ Returns ------- - :func:`tuple` of array-like + :class:`tuple` of array-like Fit coefficients, length `ncoeff`; fitted values. Raises @@ -396,7 +396,7 @@ Returns ------- - :func:`tuple` of array-like + :class:`tuple` of array-like The x, y positions. """ do_jump = self.has_jump and (not ignore_jump) @@ -475,7 +475,7 @@ Returns ------- - :func:`tuple` of array-like + :class:`tuple` of array-like The x, y positions. """ return tset.xy(xpos, ignore_jump) diff -Nru pydl-1.0.0~rc1/pydl/pydlutils/yanny.py pydl-1.0.0~rc2/pydl/pydlutils/yanny.py --- pydl-1.0.0~rc1/pydl/pydlutils/yanny.py 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/pydlutils/yanny.py 2021-07-22 21:35:35.000000000 +0000 @@ -1,4 +1,4 @@ -(str,)# Licensed under a 3-clause BSD style license - see LICENSE.rst +# Licensed under a 3-clause BSD style license - see LICENSE.rst # -*- coding: utf-8 -*- """This module corresponds to the yanny directory in idlutils. @@ -124,7 +124,7 @@ Returns ------- - :func:`tuple` + :class:`tuple` A tuple containing the first word and the remainder of the string. Examples diff -Nru pydl-1.0.0~rc1/pydl/rebin.py pydl-1.0.0~rc2/pydl/rebin.py --- pydl-1.0.0~rc1/pydl/rebin.py 2020-01-18 02:43:53.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/rebin.py 2021-07-22 21:35:35.000000000 +0000 @@ -19,7 +19,7 @@ ---------- x : :class:`~numpy.ndarray` The array to resample. - d : :func:`tuple` + d : :class:`tuple` The new shape of the array. sample : :class:`bool`, optional If ``True``, nearest-neighbor techniques will be used instead of @@ -35,6 +35,15 @@ :exc:`ValueError` If the new dimensions are incompatible with the algorithm. + Warnings + -------- + This function may not be 100% compatible with the IDL version + *for integer inputs*. It is not possible at present to examine the details + of the IDL code to determine the exact type manipulation that are used. + For further discussion see Issue `#60`_. + + .. _`#60`: https://github.com/weaverba137/pydl/issues/60 + References ---------- http://www.harrisgeospatial.com/docs/rebin.html @@ -72,8 +81,8 @@ sliceobj0 = [slice(None)]*len(d0) sliceobj1 = [slice(None)]*len(d0) sliceobj = [slice(None)]*len(d) - f = d0[k]/d[k] if d[k] > d0[k]: + f = d0[k]/d[k] for i in range(d[k]): p = f*i fp = int(floor(p)) @@ -97,6 +106,7 @@ sliceobj[k] = slice(i, i + 1) r[tuple(sliceobj)] = xx[tuple(sliceobj0)] else: + f = d0[k]//d[k] for i in range(d[k]): sliceobj[k] = slice(i, i + 1) if sample: @@ -106,6 +116,10 @@ else: sliceobj0[k] = slice(int(f*i), int(f*(i+1))) rshape = r[tuple(sliceobj)].shape - r[tuple(sliceobj)] = xx[tuple(sliceobj0)].sum(k).reshape(rshape)/f + rr = xx[tuple(sliceobj0)].sum(k).reshape(rshape) + if xx.dtype.kind == 'u' or xx.dtype.kind == 'i': + r[tuple(sliceobj)] = rr//f + else: + r[tuple(sliceobj)] = rr/f xx = r return r diff -Nru pydl-1.0.0~rc1/pydl/tests/test_pydl.py pydl-1.0.0~rc2/pydl/tests/test_pydl.py --- pydl-1.0.0~rc1/pydl/tests/test_pydl.py 2020-01-18 02:43:53.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/tests/test_pydl.py 2021-07-22 21:35:35.000000000 +0000 @@ -2,7 +2,7 @@ # -*- coding: utf-8 -*- """Test the top-level pydl functions. """ -# import pytest +import pytest import numpy as np try: from astropy.tests.compat import assert_allclose @@ -162,6 +162,86 @@ assert np.allclose(r, rexpect) +@pytest.mark.xfail +def test_rebin_int(): + """Test rebin on integers. Comparing to IDL code similar to this:: + + IDL> seed = 100 + IDL> array = FIX(RANDOMN(seed, 10, 20) * 100, TYPE=1) ; UINT8 + IDL> array_rebin = REBIN(array, 5, 10) + """ + array = np.array([[188, 186, 25, 212, 34, 98, 3, 235, 155, 148], + [107, 166, 4, 41, 101, 190, 39, 154, 153, 239], + [135, 181, 92, 161, 213, 136, 35, 61, 80, 164], + [123, 248, 8, 157, 96, 118, 99, 1, 109, 246], + [226, 71, 183, 27, 46, 99, 8, 239, 66, 25], + [ 27, 219, 37, 130, 5, 81, 65, 250, 96, 14], + [ 71, 157, 156, 136, 47, 225, 247, 191, 49, 12], + [231, 133, 9, 38, 243, 2, 235, 145, 23, 22], + [146, 38, 49, 89, 42, 57, 220, 214, 135, 47], + [101, 116, 122, 209, 141, 37, 158, 224, 245, 82], + [ 15, 47, 51, 250, 207, 193, 209, 228, 110, 1], + [ 59, 232, 216, 224, 24, 118, 190, 10, 107, 27], + [ 84, 193, 112, 206, 113, 171, 138, 117, 244, 20], + [ 5, 31, 128, 214, 200, 119, 59, 27, 57, 10], + [226, 71, 177, 85, 0, 68, 54, 207, 141, 250], + [ 52, 119, 121, 177, 165, 99, 68, 29, 137, 200], + [172, 91, 181, 187, 87, 250, 45, 154, 58, 83], + [ 56, 175, 189, 35, 203, 223, 243, 187, 252, 97], + [186, 172, 207, 128, 61, 231, 89, 57, 131, 222], + [206, 96, 29, 60, 3, 8, 221, 55, 60, 17]], dtype=np.uint8) + array_rebin = np.array([[161, 70, 105, 107, 173], + [171, 104, 140, 49, 149], + [135, 94, 57, 140, 50], + [148, 84, 129, 204, 26], + [100, 117, 69, 204, 127], + [ 88, 185, 135, 159, 61], + [ 78, 165, 150, 85, 82], + [116, 140, 83, 89, 181], + [123, 148, 190, 157, 122], + [165, 105, 75, 105, 107]], dtype=np.uint8) + + ar = rebin(array, (10, 5)) + assert (array_rebin == ar).all() + + +def test_rebin_int_sample(): + """Similar to test_rebin_int(), but using the sample option. + """ + array = np.array([[188, 186, 25, 212, 34, 98, 3, 235, 155, 148], + [107, 166, 4, 41, 101, 190, 39, 154, 153, 239], + [135, 181, 92, 161, 213, 136, 35, 61, 80, 164], + [123, 248, 8, 157, 96, 118, 99, 1, 109, 246], + [226, 71, 183, 27, 46, 99, 8, 239, 66, 25], + [ 27, 219, 37, 130, 5, 81, 65, 250, 96, 14], + [ 71, 157, 156, 136, 47, 225, 247, 191, 49, 12], + [231, 133, 9, 38, 243, 2, 235, 145, 23, 22], + [146, 38, 49, 89, 42, 57, 220, 214, 135, 47], + [101, 116, 122, 209, 141, 37, 158, 224, 245, 82], + [ 15, 47, 51, 250, 207, 193, 209, 228, 110, 1], + [ 59, 232, 216, 224, 24, 118, 190, 10, 107, 27], + [ 84, 193, 112, 206, 113, 171, 138, 117, 244, 20], + [ 5, 31, 128, 214, 200, 119, 59, 27, 57, 10], + [226, 71, 177, 85, 0, 68, 54, 207, 141, 250], + [ 52, 119, 121, 177, 165, 99, 68, 29, 137, 200], + [172, 91, 181, 187, 87, 250, 45, 154, 58, 83], + [ 56, 175, 189, 35, 203, 223, 243, 187, 252, 97], + [186, 172, 207, 128, 61, 231, 89, 57, 131, 222], + [206, 96, 29, 60, 3, 8, 221, 55, 60, 17]], dtype=np.uint8) + array_sample = np.array([[188, 25, 34, 3, 155], + [135, 92, 213, 35, 80], + [226, 183, 46, 8, 66], + [ 71, 156, 47, 247, 49], + [146, 49, 42, 220, 135], + [ 15, 51, 207, 209, 110], + [ 84, 112, 113, 138, 244], + [226, 177, 0, 54, 141], + [172, 181, 87, 45, 58], + [186, 207, 61, 89, 131]], dtype=np.uint8) + ars = rebin(array, (10, 5), sample=True) + assert (array_sample == ars).all() + + def test_smooth(): test_data_file = get_pkg_data_filename('t/smooth_data.txt') noise = np.loadtxt(test_data_file, dtype='d') diff -Nru pydl-1.0.0~rc1/pydl/version.py pydl-1.0.0~rc2/pydl/version.py --- pydl-1.0.0~rc1/pydl/version.py 2020-04-28 21:02:43.000000000 +0000 +++ pydl-1.0.0~rc2/pydl/version.py 1970-01-01 00:00:00.000000000 +0000 @@ -1,8 +0,0 @@ -# Note that we need to fall back to the hard-coded version if either -# setuptools_scm can't be imported or setuptools_scm can't determine the -# version, so we catch the generic 'Exception'. -try: - from setuptools_scm import get_version - version = get_version(root='..', relative_to=__file__) -except Exception: - version = '1.0.0rc1' diff -Nru pydl-1.0.0~rc1/README.rst pydl-1.0.0~rc2/README.rst --- pydl-1.0.0~rc1/README.rst 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/README.rst 2021-07-22 21:35:35.000000000 +0000 @@ -2,31 +2,33 @@ PyDL ==== -.. image:: http://img.shields.io/badge/powered%20by-AstroPy-orange.svg?style=flat +|Astropy Status| |License| |Zenodo| |PyPI Status| |Actions Status| |Coveralls Status| |Documentation Status| + +.. |Astropy Status| image:: http://img.shields.io/badge/powered%20by-AstroPy-orange.svg?style=flat :target: http://www.astropy.org :alt: Powered by Astropy Badge -.. image:: https://img.shields.io/pypi/l/pydl.svg +.. |License| image:: https://img.shields.io/pypi/l/pydl.svg :target: https://pypi.python.org/pypi/pydl :alt: License -.. image:: https://zenodo.org/badge/DOI/10.5281/zenodo.2575874.svg +.. |Zenodo| image:: https://zenodo.org/badge/DOI/10.5281/zenodo.2575874.svg :target: https://doi.org/10.5281/zenodo.2575874 :alt: DOI: 10.5281/zenodo.2575874 -.. image:: https://img.shields.io/pypi/v/pydl.svg +.. |PyPI Status| image:: https://img.shields.io/pypi/v/pydl.svg :target: https://pypi.python.org/pypi/pydl :alt: PyPI Badge -.. image:: https://img.shields.io/travis/weaverba137/pydl.svg - :target: https://travis-ci.org/weaverba137/pydl - :alt: Travis Build Status +.. |Actions Status| image:: https://github.com/weaverba137/pydl/actions/workflows/ci_tests.yml/badge.svg + :target: https://github.com/weaverba137/pydl/actions/workflows/ci_tests.yml + :alt: GitHub Actions CI Status -.. image:: https://coveralls.io/repos/weaverba137/pydl/badge.svg?branch=master&service=github - :target: https://coveralls.io/github/weaverba137/pydl?branch=master +.. |Coveralls Status| image:: https://coveralls.io/repos/weaverba137/pydl/badge.svg?branch=main&service=github + :target: https://coveralls.io/github/weaverba137/pydl?branch=main :alt: Test Coverage Status -.. image:: https://readthedocs.org/projects/pydl/badge/?version=latest +.. |Documentation Status| image:: https://readthedocs.org/projects/pydl/badge/?version=latest :target: http://pydl.readthedocs.org/en/latest/ :alt: Documentation Status diff -Nru pydl-1.0.0~rc1/.readthedocs.yml pydl-1.0.0~rc2/.readthedocs.yml --- pydl-1.0.0~rc1/.readthedocs.yml 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/.readthedocs.yml 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,16 @@ +# See https://docs.readthedocs.io/en/latest/yaml-config.html +version: 2 + +build: + image: latest + +python: + version: 3.7 + install: + - method: pip + path: . + extra_requirements: + - docs + - all + +formats: [] diff -Nru pydl-1.0.0~rc1/setup.cfg pydl-1.0.0~rc2/setup.cfg --- pydl-1.0.0~rc1/setup.cfg 2020-04-28 20:39:16.000000000 +0000 +++ pydl-1.0.0~rc2/setup.cfg 2021-07-22 21:35:35.000000000 +0000 @@ -65,6 +65,7 @@ addopts = --doctest-rst [coverage:run] +relative_files = True omit = pydl/_astropy_init* pydl/conftest.py diff -Nru pydl-1.0.0~rc1/tox.ini pydl-1.0.0~rc2/tox.ini --- pydl-1.0.0~rc1/tox.ini 1970-01-01 00:00:00.000000000 +0000 +++ pydl-1.0.0~rc2/tox.ini 2021-07-22 21:35:35.000000000 +0000 @@ -0,0 +1,112 @@ +[tox] +envlist = + py{36,37,38}-test{,-alldeps,-devdeps}{,-cov} + py{36,37,38}-test-numpy{116,117,118} + py{36,37,38}-test-astropy{30,40,lts} + astropy20 + build_docs + linkcheck + codestyle +requires = + setuptools >= 30.3.0 + pip >= 19.3.1 + setuptools_scm + tox-pypi-filter >= 0.12 +isolated_build = true + +[testenv] + +# The following option combined with the use of the tox-pypi-filter above allows +# project-wide pinning of dependencies, e.g. if new versions of pytest do not +# work correctly with pytest-astropy plugins. Most of the time the pinnings file +# should be empty. +pypi_filter = https://raw.githubusercontent.com/astropy/ci-helpers/master/pip_pinnings.txt + +# Pass through the following environment variables which may be needed for the CI +passenv = HOME WINDIR LC_ALL LC_CTYPE CC CI GITHUB_* COVERALLS_* + +# Run the tests in a temporary directory to make sure that we don't import +# this package from the source tree +changedir = .tmp/{envname} + +# tox environments are constructed with so-called 'factors' (or terms) +# separated by hyphens, e.g. test-devdeps-cov. Lines below starting with factor: +# will only take effect if that factor is included in the environment name. To +# see a list of example environments that can be run, along with a description, +# run: +# +# tox -l -v +# +description = + run tests + alldeps: with all optional dependencies + devdeps: with the latest developer version of key dependencies + oldestdeps: with the oldest supported version of key dependencies + cov: and test coverage + numpy116: with numpy 1.16.* + numpy117: with numpy 1.17.* + numpy118: with numpy 1.18.* + astropy30: with astropy 3.0.* + astropy40: with astropy 4.0.* + astropylts: with the latest astropy LTS + +# The following provides some specific pinnings for key packages +deps = + cov: coveralls + + numpy116: numpy==1.16.* + numpy117: numpy==1.17.* + numpy118: numpy==1.18.* + + astropy30: astropy==3.0.* + astropy40: astropy==4.0.* + astropylts: astropy==4.0.* + + devdeps: git+https://github.com/numpy/numpy.git#egg=numpy + devdeps: git+https://github.com/astropy/astropy.git#egg=astropy + +# The following indicates which extras_require from setup.cfg will be installed +extras = + test + alldeps: all + +commands = + pip freeze + !cov: pytest --pyargs pydl {toxinidir}/docs {posargs} + cov: pytest --pyargs pydl {toxinidir}/docs --cov pydl --cov-config={toxinidir}/setup.cfg {posargs} + cov: coveralls + +[testenv:astropy20] +description = run tests with astropy2.0.* +extras = astropy20 +deps = + astropy==2.0.* + numpy==1.14.* + pytest<3.7 + pytest-mock<2 +commands = + pip freeze + pytest -p astropy.tests.pytest_repeat -p astropy.extern.plugins.pytest_doctestplus.plugin -p astropy.extern.plugins.pytest_openfiles.plugin -p astropy.extern.plugins.pytest_remotedata.plugin --traceconfig --pyargs pydl {toxinidir}/docs {posargs} + +[testenv:build_docs] +changedir = docs +description = invoke sphinx-build to build the HTML docs +extras = docs +commands = + pip freeze + sphinx-build -W --keep-going -b html . _build/html + +[testenv:linkcheck] +changedir = docs +description = check the links in the HTML docs +extras = docs +commands = + pip freeze + sphinx-build -W --keep-going -b linkcheck . _build/html + +[testenv:codestyle] +skip_install = true +changedir = . +description = check code style, e.g. with flake8 +deps = flake8 +commands = flake8 pydl --count --max-line-length=100