Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save SomeoneSerge/be4d68d539eedc623ec517f885836ec5 to your computer and use it in GitHub Desktop.
Save SomeoneSerge/be4d68d539eedc623ec517f885836ec5 to your computer and use it in GitHub Desktop.
nix log /nix/store/6f2dbxglqha0p38g53f4gqknc57s8wdp-python3.10-spectral-cube-0.6.0.drv
Sourcing python-remove-tests-dir-hook
Sourcing python-catch-conflicts-hook.sh
Sourcing python-remove-bin-bytecode-hook.sh
Sourcing pip-build-hook
Using pipBuildPhase
Using pipShellHook
Sourcing pip-install-hook
Using pipInstallPhase
Sourcing python-imports-check-hook.sh
Using pythonImportsCheckPhase
Sourcing python-namespaces-hook
Sourcing python-catch-conflicts-hook.sh
Sourcing pytest-check-hook
Using pytestCheckPhase
@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking sources
unpacking source archive /nix/store/rz6bcidq6689rxm23q1mllqacck52wbz-spectral-cube-0.6.0.tar.gz
source root is spectral-cube-0.6.0
setting SOURCE_DATE_EPOCH to timestamp 1633017864 of file spectral-cube-0.6.0/setup.cfg
@nix { "action": "setPhase", "phase": "patchPhase" }
patching sources
@nix { "action": "setPhase", "phase": "configurePhase" }
configuring
no configure script, doing nothing
@nix { "action": "setPhase", "phase": "buildPhase" }
building
Executing pipBuildPhase
Creating a wheel...
WARNING: The directory '/homeless-shelter/.cache/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you should use sudo's -H flag.
Processing /build/spectral-cube-0.6.0
Running command Preparing metadata (pyproject.toml)
/nix/store/qg3jn6cd12kphciq49grn38hk5fzgs0v-python3.10-setuptools-67.4.0/lib/python3.10/site-packages/setuptools/dist.py:788: UserWarning: Usage of dash-separated 'upload-dir' will not be supported in future versions. Please use the underscore name 'upload_dir' instead
warnings.warn(
/nix/store/qg3jn6cd12kphciq49grn38hk5fzgs0v-python3.10-setuptools-67.4.0/lib/python3.10/site-packages/setuptools/dist.py:788: UserWarning: Usage of dash-separated 'show-response' will not be supported in future versions. Please use the underscore name 'show_response' instead
warnings.warn(
running dist_info
creating /build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info
writing /build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/PKG-INFO
writing dependency_links to /build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/dependency_links.txt
writing requirements to /build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/requires.txt
writing top-level names to /build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/top_level.txt
writing manifest file '/build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/SOURCES.txt'
reading manifest file '/build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'README.md'
warning: no files found matching '*.c' under directory '*.pyx'
warning: no files found matching '*.pxd' under directory '*.pyx'
warning: no files found matching '*' under directory 'licenses'
warning: no files found matching '*' under directory 'cextern'
warning: no files found matching '*' under directory 'scripts'
no previously-included directories found matching 'build'
no previously-included directories found matching 'docs/_build'
no previously-included directories found matching 'docs/api'
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*.o' found anywhere in distribution
adding license file 'LICENSE.rst'
writing manifest file '/build/pip-modern-metadata-5o3s5eat/spectral_cube.egg-info/SOURCES.txt'
creating '/build/pip-modern-metadata-5o3s5eat/spectral_cube-0.6.0.dist-info'
Preparing metadata (pyproject.toml) ... [?25l[?25hdone
Building wheels for collected packages: spectral-cube
Running command Building wheel for spectral-cube (pyproject.toml)
/nix/store/qg3jn6cd12kphciq49grn38hk5fzgs0v-python3.10-setuptools-67.4.0/lib/python3.10/site-packages/setuptools/dist.py:788: UserWarning: Usage of dash-separated 'upload-dir' will not be supported in future versions. Please use the underscore name 'upload_dir' instead
warnings.warn(
/nix/store/qg3jn6cd12kphciq49grn38hk5fzgs0v-python3.10-setuptools-67.4.0/lib/python3.10/site-packages/setuptools/dist.py:788: UserWarning: Usage of dash-separated 'show-response' will not be supported in future versions. Please use the underscore name 'show_response' instead
warnings.warn(
running bdist_wheel
running build
running build_py
creating build
creating build/lib
creating build/lib/spectral_cube
copying spectral_cube/visualization-tools.py -> build/lib/spectral_cube
copying spectral_cube/masks.py -> build/lib/spectral_cube
copying spectral_cube/np_compat.py -> build/lib/spectral_cube
copying spectral_cube/analysis_utilities.py -> build/lib/spectral_cube
copying spectral_cube/_moments.py -> build/lib/spectral_cube
copying spectral_cube/__init__.py -> build/lib/spectral_cube
copying spectral_cube/spectral_cube.py -> build/lib/spectral_cube
copying spectral_cube/cube_utils.py -> build/lib/spectral_cube
copying spectral_cube/spectral_axis.py -> build/lib/spectral_cube
copying spectral_cube/ytcube.py -> build/lib/spectral_cube
copying spectral_cube/stokes_spectral_cube.py -> build/lib/spectral_cube
copying spectral_cube/base_class.py -> build/lib/spectral_cube
copying spectral_cube/wcs_utils.py -> build/lib/spectral_cube
copying spectral_cube/lower_dimensional_structures.py -> build/lib/spectral_cube
copying spectral_cube/version.py -> build/lib/spectral_cube
copying spectral_cube/dask_spectral_cube.py -> build/lib/spectral_cube
copying spectral_cube/conftest.py -> build/lib/spectral_cube
copying spectral_cube/utils.py -> build/lib/spectral_cube
copying spectral_cube/_astropy_init.py -> build/lib/spectral_cube
creating build/lib/spectral_cube/io
copying spectral_cube/io/casa_image.py -> build/lib/spectral_cube/io
copying spectral_cube/io/__init__.py -> build/lib/spectral_cube/io
copying spectral_cube/io/fits.py -> build/lib/spectral_cube/io
copying spectral_cube/io/core.py -> build/lib/spectral_cube/io
copying spectral_cube/io/class_lmv.py -> build/lib/spectral_cube/io
copying spectral_cube/io/casa_masks.py -> build/lib/spectral_cube/io
creating build/lib/spectral_cube/tests
copying spectral_cube/tests/test_io.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_wcs_utils.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/__init__.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_stokes_spectral_cube.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_visualization.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_projection.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/utilities.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_masks.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_spectral_cube.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_dask.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_spectral_axis.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_moments.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/setup_package.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_regrid.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_subcubes.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_analysis_functions.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_cube_utils.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/helpers.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_performance.py -> build/lib/spectral_cube/tests
copying spectral_cube/tests/test_casafuncs.py -> build/lib/spectral_cube/tests
creating build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/__init__.py -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/image.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/cubewcs2.hdr -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/partial_overlap_image.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/cubewcs1.hdr -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/fk5.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/no_overlap_fk5.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/example_cube.fits -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/greisen2006.hdr -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/255-pixel.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/example_cube.lmv -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/Makefile -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/255-fk5.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/no_overlap_image.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/partial_overlap_fk5.reg -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/header_jybeam.hdr -> build/lib/spectral_cube/tests/data
copying spectral_cube/tests/data/fk5_twoboxes.reg -> build/lib/spectral_cube/tests/data
creating build/lib/spectral_cube/tests/data/nomask.image
copying spectral_cube/tests/data/nomask.image/table.f0_TSM0 -> build/lib/spectral_cube/tests/data/nomask.image
copying spectral_cube/tests/data/nomask.image/table.lock -> build/lib/spectral_cube/tests/data/nomask.image
copying spectral_cube/tests/data/nomask.image/table.dat -> build/lib/spectral_cube/tests/data/nomask.image
copying spectral_cube/tests/data/nomask.image/table.info -> build/lib/spectral_cube/tests/data/nomask.image
copying spectral_cube/tests/data/nomask.image/table.f0 -> build/lib/spectral_cube/tests/data/nomask.image
creating build/lib/spectral_cube/tests/data/basic.image
copying spectral_cube/tests/data/basic.image/table.f0_TSM0 -> build/lib/spectral_cube/tests/data/basic.image
copying spectral_cube/tests/data/basic.image/table.lock -> build/lib/spectral_cube/tests/data/basic.image
copying spectral_cube/tests/data/basic.image/table.dat -> build/lib/spectral_cube/tests/data/basic.image
copying spectral_cube/tests/data/basic.image/table.info -> build/lib/spectral_cube/tests/data/basic.image
copying spectral_cube/tests/data/basic.image/table.f0 -> build/lib/spectral_cube/tests/data/basic.image
creating build/lib/spectral_cube/tests/data/basic_bigendian.image
copying spectral_cube/tests/data/basic_bigendian.image/table.f0_TSM0 -> build/lib/spectral_cube/tests/data/basic_bigendian.image
copying spectral_cube/tests/data/basic_bigendian.image/table.lock -> build/lib/spectral_cube/tests/data/basic_bigendian.image
copying spectral_cube/tests/data/basic_bigendian.image/table.dat -> build/lib/spectral_cube/tests/data/basic_bigendian.image
copying spectral_cube/tests/data/basic_bigendian.image/table.info -> build/lib/spectral_cube/tests/data/basic_bigendian.image
copying spectral_cube/tests/data/basic_bigendian.image/table.f0 -> build/lib/spectral_cube/tests/data/basic_bigendian.image
installing to build/bdist.linux-x86_64/wheel
running install
running install_lib
creating build/bdist.linux-x86_64
creating build/bdist.linux-x86_64/wheel
creating build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/visualization-tools.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/masks.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/np_compat.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/analysis_utilities.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/_moments.py -> build/bdist.linux-x86_64/wheel/spectral_cube
creating build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/casa_image.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/__init__.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/fits.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/core.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/class_lmv.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/io/casa_masks.py -> build/bdist.linux-x86_64/wheel/spectral_cube/io
copying build/lib/spectral_cube/__init__.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/spectral_cube.py -> build/bdist.linux-x86_64/wheel/spectral_cube
creating build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_io.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_wcs_utils.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/__init__.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_stokes_spectral_cube.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_visualization.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_projection.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/utilities.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_masks.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_spectral_cube.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_dask.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_spectral_axis.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_moments.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/setup_package.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_regrid.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_subcubes.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_analysis_functions.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_cube_utils.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/helpers.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/tests/test_performance.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
creating build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/image.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/cubewcs2.hdr -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/partial_overlap_image.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/cubewcs1.hdr -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/fk5.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/no_overlap_fk5.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/example_cube.fits -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/__init__.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/greisen2006.hdr -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/255-pixel.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
creating build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
copying build/lib/spectral_cube/tests/data/nomask.image/table.f0_TSM0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
copying build/lib/spectral_cube/tests/data/nomask.image/table.lock -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
copying build/lib/spectral_cube/tests/data/nomask.image/table.dat -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
copying build/lib/spectral_cube/tests/data/nomask.image/table.info -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
copying build/lib/spectral_cube/tests/data/nomask.image/table.f0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/nomask.image
creating build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
copying build/lib/spectral_cube/tests/data/basic.image/table.f0_TSM0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
copying build/lib/spectral_cube/tests/data/basic.image/table.lock -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
copying build/lib/spectral_cube/tests/data/basic.image/table.dat -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
copying build/lib/spectral_cube/tests/data/basic.image/table.info -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
copying build/lib/spectral_cube/tests/data/basic.image/table.f0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic.image
creating build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/basic_bigendian.image/table.f0_TSM0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/basic_bigendian.image/table.lock -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/basic_bigendian.image/table.dat -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/basic_bigendian.image/table.info -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/basic_bigendian.image/table.f0 -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data/basic_bigendian.image
copying build/lib/spectral_cube/tests/data/example_cube.lmv -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/Makefile -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/255-fk5.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/no_overlap_image.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/partial_overlap_fk5.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/header_jybeam.hdr -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/data/fk5_twoboxes.reg -> build/bdist.linux-x86_64/wheel/spectral_cube/tests/data
copying build/lib/spectral_cube/tests/test_casafuncs.py -> build/bdist.linux-x86_64/wheel/spectral_cube/tests
copying build/lib/spectral_cube/cube_utils.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/spectral_axis.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/ytcube.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/stokes_spectral_cube.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/base_class.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/wcs_utils.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/lower_dimensional_structures.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/version.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/dask_spectral_cube.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/conftest.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/utils.py -> build/bdist.linux-x86_64/wheel/spectral_cube
copying build/lib/spectral_cube/_astropy_init.py -> build/bdist.linux-x86_64/wheel/spectral_cube
running install_egg_info
running egg_info
writing spectral_cube.egg-info/PKG-INFO
writing dependency_links to spectral_cube.egg-info/dependency_links.txt
writing requirements to spectral_cube.egg-info/requires.txt
writing top-level names to spectral_cube.egg-info/top_level.txt
reading manifest file 'spectral_cube.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'README.md'
warning: no files found matching '*.c' under directory '*.pyx'
warning: no files found matching '*.pxd' under directory '*.pyx'
warning: no files found matching '*' under directory 'licenses'
warning: no files found matching '*' under directory 'cextern'
warning: no files found matching '*' under directory 'scripts'
no previously-included directories found matching 'build'
no previously-included directories found matching 'docs/_build'
no previously-included directories found matching 'docs/api'
warning: no previously-included files matching '*.pyc' found anywhere in distribution
warning: no previously-included files matching '*.o' found anywhere in distribution
adding license file 'LICENSE.rst'
writing manifest file 'spectral_cube.egg-info/SOURCES.txt'
Copying spectral_cube.egg-info to build/bdist.linux-x86_64/wheel/spectral_cube-0.6.0-py3.10.egg-info
running install_scripts
creating build/bdist.linux-x86_64/wheel/spectral_cube-0.6.0.dist-info/WHEEL
creating '/build/pip-wheel-0x1hnofq/.tmp-qd2s2n8k/spectral_cube-0.6.0-py3-none-any.whl' and adding 'build/bdist.linux-x86_64/wheel' to it
adding 'spectral_cube/__init__.py'
adding 'spectral_cube/_astropy_init.py'
adding 'spectral_cube/_moments.py'
adding 'spectral_cube/analysis_utilities.py'
adding 'spectral_cube/base_class.py'
adding 'spectral_cube/conftest.py'
adding 'spectral_cube/cube_utils.py'
adding 'spectral_cube/dask_spectral_cube.py'
adding 'spectral_cube/lower_dimensional_structures.py'
adding 'spectral_cube/masks.py'
adding 'spectral_cube/np_compat.py'
adding 'spectral_cube/spectral_axis.py'
adding 'spectral_cube/spectral_cube.py'
adding 'spectral_cube/stokes_spectral_cube.py'
adding 'spectral_cube/utils.py'
adding 'spectral_cube/version.py'
adding 'spectral_cube/visualization-tools.py'
adding 'spectral_cube/wcs_utils.py'
adding 'spectral_cube/ytcube.py'
adding 'spectral_cube/io/__init__.py'
adding 'spectral_cube/io/casa_image.py'
adding 'spectral_cube/io/casa_masks.py'
adding 'spectral_cube/io/class_lmv.py'
adding 'spectral_cube/io/core.py'
adding 'spectral_cube/io/fits.py'
adding 'spectral_cube/tests/__init__.py'
adding 'spectral_cube/tests/helpers.py'
adding 'spectral_cube/tests/setup_package.py'
adding 'spectral_cube/tests/test_analysis_functions.py'
adding 'spectral_cube/tests/test_casafuncs.py'
adding 'spectral_cube/tests/test_cube_utils.py'
adding 'spectral_cube/tests/test_dask.py'
adding 'spectral_cube/tests/test_io.py'
adding 'spectral_cube/tests/test_masks.py'
adding 'spectral_cube/tests/test_moments.py'
adding 'spectral_cube/tests/test_performance.py'
adding 'spectral_cube/tests/test_projection.py'
adding 'spectral_cube/tests/test_regrid.py'
adding 'spectral_cube/tests/test_spectral_axis.py'
adding 'spectral_cube/tests/test_spectral_cube.py'
adding 'spectral_cube/tests/test_stokes_spectral_cube.py'
adding 'spectral_cube/tests/test_subcubes.py'
adding 'spectral_cube/tests/test_visualization.py'
adding 'spectral_cube/tests/test_wcs_utils.py'
adding 'spectral_cube/tests/utilities.py'
adding 'spectral_cube/tests/data/255-fk5.reg'
adding 'spectral_cube/tests/data/255-pixel.reg'
adding 'spectral_cube/tests/data/Makefile'
adding 'spectral_cube/tests/data/__init__.py'
adding 'spectral_cube/tests/data/cubewcs1.hdr'
adding 'spectral_cube/tests/data/cubewcs2.hdr'
adding 'spectral_cube/tests/data/example_cube.fits'
adding 'spectral_cube/tests/data/example_cube.lmv'
adding 'spectral_cube/tests/data/fk5.reg'
adding 'spectral_cube/tests/data/fk5_twoboxes.reg'
adding 'spectral_cube/tests/data/greisen2006.hdr'
adding 'spectral_cube/tests/data/header_jybeam.hdr'
adding 'spectral_cube/tests/data/image.reg'
adding 'spectral_cube/tests/data/no_overlap_fk5.reg'
adding 'spectral_cube/tests/data/no_overlap_image.reg'
adding 'spectral_cube/tests/data/partial_overlap_fk5.reg'
adding 'spectral_cube/tests/data/partial_overlap_image.reg'
adding 'spectral_cube/tests/data/basic.image/table.dat'
adding 'spectral_cube/tests/data/basic.image/table.f0'
adding 'spectral_cube/tests/data/basic.image/table.f0_TSM0'
adding 'spectral_cube/tests/data/basic.image/table.info'
adding 'spectral_cube/tests/data/basic.image/table.lock'
adding 'spectral_cube/tests/data/basic_bigendian.image/table.dat'
adding 'spectral_cube/tests/data/basic_bigendian.image/table.f0'
adding 'spectral_cube/tests/data/basic_bigendian.image/table.f0_TSM0'
adding 'spectral_cube/tests/data/basic_bigendian.image/table.info'
adding 'spectral_cube/tests/data/basic_bigendian.image/table.lock'
adding 'spectral_cube/tests/data/nomask.image/table.dat'
adding 'spectral_cube/tests/data/nomask.image/table.f0'
adding 'spectral_cube/tests/data/nomask.image/table.f0_TSM0'
adding 'spectral_cube/tests/data/nomask.image/table.info'
adding 'spectral_cube/tests/data/nomask.image/table.lock'
adding 'spectral_cube-0.6.0.dist-info/LICENSE.rst'
adding 'spectral_cube-0.6.0.dist-info/METADATA'
adding 'spectral_cube-0.6.0.dist-info/WHEEL'
adding 'spectral_cube-0.6.0.dist-info/top_level.txt'
adding 'spectral_cube-0.6.0.dist-info/RECORD'
removing build/bdist.linux-x86_64/wheel
Building wheel for spectral-cube (pyproject.toml) ... [?25l[?25hdone
Created wheel for spectral-cube: filename=spectral_cube-0.6.0-py3-none-any.whl size=218558 sha256=faffaca38a7541cd3f8e3113c6aa2382dafab6f5028399bf7fb07d61f96f073b
Stored in directory: /build/pip-ephem-wheel-cache-nlqzkmyl/wheels/4f/b3/b6/66e2cc7abfac5dc0a99be8eeedb5b65c31e33283c708541dbf
Successfully built spectral-cube
Finished creating a wheel...
Finished executing pipBuildPhase
@nix { "action": "setPhase", "phase": "installPhase" }
installing
Executing pipInstallPhase
/build/spectral-cube-0.6.0/dist /build/spectral-cube-0.6.0
Processing ./spectral_cube-0.6.0-py3-none-any.whl
Requirement already satisfied: astropy in /nix/store/aygmmfb6313sd2l3r08m2794cqhd7aw0-python3.10-astropy-5.2.1/lib/python3.10/site-packages (from spectral-cube==0.6.0) (5.2.1)
Requirement already satisfied: radio-beam>=0.3.3 in /nix/store/3641533jcbsy0pzhnb62sypb3laf4q4s-python3.10-radio_beam-0.3.4/lib/python3.10/site-packages (from spectral-cube==0.6.0) (0.3.4)
Requirement already satisfied: dask[array] in /nix/store/i3izhj9y20kd5gb5q7ik45ay0x7q8wwd-python3.10-dask-2023.2.1/lib/python3.10/site-packages (from spectral-cube==0.6.0) (2023.2.1)
Requirement already satisfied: casa-formats-io in /nix/store/n0wj07xxpc58x8rvrf2ndl67zzws6lpp-python3.10-casa-formats-io-0.2.1/lib/python3.10/site-packages (from spectral-cube==0.6.0) (0.2.1)
Requirement already satisfied: numpy>=1.8.0 in /nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages (from spectral-cube==0.6.0) (1.24.2)
Requirement already satisfied: six in /nix/store/jl45bvbs1apwxizp61sjldcbw9a8rbzy-python3.10-six-1.16.0/lib/python3.10/site-packages (from spectral-cube==0.6.0) (1.16.0)
Requirement already satisfied: joblib in /nix/store/cpbi76s5pzdd2nilq1xxrfrk6gywcgxn-python3.10-joblib-1.2.0/lib/python3.10/site-packages (from spectral-cube==0.6.0) (1.2.0)
Requirement already satisfied: scipy in /nix/store/0qxr9zx0y6kkkspczxsqd38wbajsnd9p-python3.10-scipy-1.10.1/lib/python3.10/site-packages (from radio-beam>=0.3.3->spectral-cube==0.6.0) (1.10.1)
Requirement already satisfied: PyYAML>=3.13 in /nix/store/5z40dkf12ybx5nlw7ab0qznv3ll0dv82-python3.10-pyyaml-6.0/lib/python3.10/site-packages (from astropy->spectral-cube==0.6.0) (6.0)
Requirement already satisfied: pyerfa>=2.0 in /nix/store/sbbq7vfdb4ljsgad7s91hx4kvdjbazq8-python3.10-pyerfa-2.0.0.1/lib/python3.10/site-packages (from astropy->spectral-cube==0.6.0) (2.0.0.1)
Requirement already satisfied: packaging>=19.0 in /nix/store/hz1ayhmrwvbrbpv6r6q17p71yfp7qnsp-python3.10-packaging-23.0/lib/python3.10/site-packages (from astropy->spectral-cube==0.6.0) (23.0)
Requirement already satisfied: partd>=1.2.0 in /nix/store/yyxfxkgrdk8wz7d0fmidjiyaj4jcg7sm-python3.10-partd-1.3.0/lib/python3.10/site-packages (from dask[array]->spectral-cube==0.6.0) (1.3.0)
Requirement already satisfied: cloudpickle>=1.1.1 in /nix/store/zrd0q6gas50mils4kp2sk6328d3pvlfb-python3.10-cloudpickle-2.2.1/lib/python3.10/site-packages (from dask[array]->spectral-cube==0.6.0) (2.2.1)
Requirement already satisfied: click>=7.0 in /nix/store/spcxakfs6hg2yrhbxp6c2gkk538q30w0-python3.10-click-8.1.3/lib/python3.10/site-packages (from dask[array]->spectral-cube==0.6.0) (8.1.3)
Requirement already satisfied: toolz>=0.8.2 in /nix/store/nvpd702s9k9hm864zjj0jgkpx14lwmwx-python3.10-toolz-0.12.0/lib/python3.10/site-packages (from dask[array]->spectral-cube==0.6.0) (0.12.0)
Requirement already satisfied: fsspec>=0.6.0 in /nix/store/nxr5swvwkrxhkdd77cnhpqicjczkhglp-python3.10-fsspec-2022.10.0/lib/python3.10/site-packages (from dask[array]->spectral-cube==0.6.0) (2022.10.0)
Requirement already satisfied: locket in /nix/store/nqq5jiq4wnrlac4ls3dh6ysn5cib5mxi-python3.10-locket-1.0.0/lib/python3.10/site-packages (from partd>=1.2.0->dask[array]->spectral-cube==0.6.0) (1.0.0)
Installing collected packages: spectral-cube
Successfully installed spectral-cube-0.6.0
/build/spectral-cube-0.6.0
Finished executing pipInstallPhase
@nix { "action": "setPhase", "phase": "pythonOutputDistPhase" }
pythonOutputDistPhase
Executing pythonOutputDistPhase
Finished executing pythonOutputDistPhase
@nix { "action": "setPhase", "phase": "fixupPhase" }
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/4qcj6y6q4sp479qpkvymwqaa3wsb8ym1-python3.10-spectral-cube-0.6.0
checking for references to /build/ in /nix/store/4qcj6y6q4sp479qpkvymwqaa3wsb8ym1-python3.10-spectral-cube-0.6.0...
patching script interpreter paths in /nix/store/4qcj6y6q4sp479qpkvymwqaa3wsb8ym1-python3.10-spectral-cube-0.6.0
stripping (with command strip and flags -S) in /nix/store/4qcj6y6q4sp479qpkvymwqaa3wsb8ym1-python3.10-spectral-cube-0.6.0/lib
shrinking RPATHs of ELF executables and libraries in /nix/store/l93ji2zh89pqp6vv68xjym4hxh00da48-python3.10-spectral-cube-0.6.0-dist
checking for references to /build/ in /nix/store/l93ji2zh89pqp6vv68xjym4hxh00da48-python3.10-spectral-cube-0.6.0-dist...
patching script interpreter paths in /nix/store/l93ji2zh89pqp6vv68xjym4hxh00da48-python3.10-spectral-cube-0.6.0-dist
Executing pythonRemoveTestsDir
Finished executing pythonRemoveTestsDir
@nix { "action": "setPhase", "phase": "installCheckPhase" }
running install tests
no Makefile or custom installCheckPhase, doing nothing
@nix { "action": "setPhase", "phase": "pythonCatchConflictsPhase" }
pythonCatchConflictsPhase
@nix { "action": "setPhase", "phase": "pythonRemoveBinBytecodePhase" }
pythonRemoveBinBytecodePhase
@nix { "action": "setPhase", "phase": "pythonImportsCheckPhase" }
pythonImportsCheckPhase
Executing pythonImportsCheckPhase
@nix { "action": "setPhase", "phase": "pytestCheckPhase" }
pytestCheckPhase
Executing pytestCheckPhase
============================= test session starts ==============================
platform linux -- Python 3.10.10, pytest-7.2.1, pluggy-1.0.0
rootdir: /build/spectral-cube-0.6.0, configfile: setup.cfg
plugins: astropy-0.10.0, hypothesis-6.68.2, arraydiff-0.5.0, astropy-header-0.2.2, cov-4.0.0, doctestplus-0.12.1, filter-subpackage-0.1.2, mock-3.10.0, openfiles-0.5.0, remotedata-0.4.0
collecting ...  collecting 0 items  collecting 1 item  collecting 1 item  collecting 38 items  collecting 72 items  collecting 351 items  collecting 357 items  collecting 522 items  collecting 750 items  collecting 1607 items  collecting 1607 items  collecting 1641 items  collected 1653 items 
spectral_cube/spectral_axis.py . [ 0%]
spectral_cube/tests/test_analysis_functions.py ................. [ 1%]
spectral_cube/tests/test_casafuncs.py ......ssssssssssssss [ 2%]
spectral_cube/tests/test_cube_utils.py ....... [ 2%]
spectral_cube/tests/test_dask.py .s..s.. [ 3%]
spectral_cube/tests/test_io.py .................... [ 4%]
spectral_cube/tests/test_masks.py ...................................... [ 6%]
...............................................XX.... [ 9%]
spectral_cube/tests/test_moments.py FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF [ 12%]
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF [ 16%]
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF [ 20%]
FFFFFFFF [ 21%]
spectral_cube/tests/test_performance.py FFFs.. [ 21%]
spectral_cube/tests/test_projection.py .......................x......... [ 23%]
.....xxx.......x........................................................ [ 27%]
...................... [ 29%]
spectral_cube/tests/test_regrid.py F..F.F....FF..F..................F.F. [ 31%]
. [ 31%]
spectral_cube/tests/test_spectral_axis.py .............................. [ 33%]
...................... [ 34%]
spectral_cube/tests/test_spectral_cube.py .............................. [ 36%]
........................................................................ [ 40%]
........................................................................ [ 45%]
........................................................................ [ 49%]
............s.....s...........sssss..................................... [ 53%]
............ssssss........FFFF..........ss.............................. [ 58%]
........................................................................ [ 62%]
....................ssssss......ssssssssssss......ssssssssssss......ssss [ 67%]
ssssssss......ssssssssssss......ssssss.................................. [ 71%]
........................................................ssssss......ssss [ 75%]
ssssssss......ssssssssssss......ssssssssssss......ssssssssssss......ssss [ 80%]
ss.................................s.s..............xxxx................ [ 84%]
..................................................ssss...FF..F.F........ [ 88%]
....F.F.F.xxxxxxxxF.FF..F.FFF.................... [ 91%]
spectral_cube/tests/test_stokes_spectral_cube.py ....................... [ 93%]
................................................................... [ 97%]
spectral_cube/tests/test_subcubes.py ..ssssssssssssssssssss [ 98%]
spectral_cube/tests/test_visualization.py ..FF....ssss [ 99%]
spectral_cube/tests/test_wcs_utils.py ............ [100%]
=================================== FAILURES ===================================
____________________ test_strategies_consistent[False-0-0] _____________________
axis = 0, order = 0, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-0-1] _____________________
axis = 0, order = 1, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-0-2] _____________________
axis = 0, order = 2, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-1-0] _____________________
axis = 1, order = 0, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-1-1] _____________________
axis = 1, order = 1, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-1-2] _____________________
axis = 1, order = 2, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-2-0] _____________________
axis = 2, order = 0, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-2-1] _____________________
axis = 2, order = 1, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_strategies_consistent[False-2-2] _____________________
axis = 2, order = 2, use_dask = False
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-0-0] _____________________
axis = 0, order = 0, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-0-1] _____________________
axis = 0, order = 1, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-0-2] _____________________
axis = 0, order = 2, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-1-0] _____________________
axis = 1, order = 0, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-1-1] _____________________
axis = 1, order = 1, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-1-2] _____________________
axis = 1, order = 2, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-2-0] _____________________
axis = 2, order = 0, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-2-1] _____________________
axis = 2, order = 1, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_strategies_consistent[True-2-2] _____________________
axis = 2, order = 2, use_dask = True
@axis_order
def test_strategies_consistent(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:93:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-0-cube] ________________________
order = 0, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-0-0-slice] ________________________
order = 0, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-0-auto] ________________________
order = 0, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-0-ray] _________________________
order = 0, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-1-cube] ________________________
order = 0, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-0-1-slice] ________________________
order = 0, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-1-auto] ________________________
order = 0, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-1-ray] _________________________
order = 0, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-2-cube] ________________________
order = 0, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-0-2-slice] ________________________
order = 0, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-2-auto] ________________________
order = 0, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-0-2-ray] _________________________
order = 0, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-0-cube] ________________________
order = 1, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-1-0-slice] ________________________
order = 1, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-0-auto] ________________________
order = 1, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-0-ray] _________________________
order = 1, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-1-cube] ________________________
order = 1, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-1-1-slice] ________________________
order = 1, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-1-auto] ________________________
order = 1, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-1-ray] _________________________
order = 1, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-2-cube] ________________________
order = 1, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-1-2-slice] ________________________
order = 1, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-2-auto] ________________________
order = 1, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-1-2-ray] _________________________
order = 1, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-0-cube] ________________________
order = 2, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-2-0-slice] ________________________
order = 2, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-0-auto] ________________________
order = 2, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-0-ray] _________________________
order = 2, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-1-cube] ________________________
order = 2, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-2-1-slice] ________________________
order = 2, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-1-auto] ________________________
order = 2, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-1-ray] _________________________
order = 2, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-2-cube] ________________________
order = 2, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_reference[False-2-2-slice] ________________________
order = 2, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-2-auto] ________________________
order = 2, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[False-2-2-ray] _________________________
order = 2, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-0-cube] _________________________
order = 0, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-0-slice] ________________________
order = 0, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-0-auto] _________________________
order = 0, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-0-0-ray] _________________________
order = 0, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-1-cube] _________________________
order = 0, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-1-slice] ________________________
order = 0, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-1-auto] _________________________
order = 0, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-0-1-ray] _________________________
order = 0, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-2-cube] _________________________
order = 0, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-2-slice] ________________________
order = 0, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-0-2-auto] _________________________
order = 0, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-0-2-ray] _________________________
order = 0, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-0-cube] _________________________
order = 1, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-0-slice] ________________________
order = 1, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-0-auto] _________________________
order = 1, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-1-0-ray] _________________________
order = 1, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-1-cube] _________________________
order = 1, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-1-slice] ________________________
order = 1, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-1-auto] _________________________
order = 1, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-1-1-ray] _________________________
order = 1, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-2-cube] _________________________
order = 1, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-2-slice] ________________________
order = 1, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-1-2-auto] _________________________
order = 1, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-1-2-ray] _________________________
order = 1, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-0-cube] _________________________
order = 2, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-0-slice] ________________________
order = 2, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-0-auto] _________________________
order = 2, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-2-0-ray] _________________________
order = 2, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-1-cube] _________________________
order = 2, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-1-slice] ________________________
order = 2, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-1-auto] _________________________
order = 2, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-2-1-ray] _________________________
order = 2, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-2-cube] _________________________
order = 2, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-2-slice] ________________________
order = 2, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_reference[True-2-2-auto] _________________________
order = 2, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________ test_reference[True-2-2-ray] _________________________
order = 2, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_reference(order, axis, how, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:109:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-0-0] ___________________
axis = 0, order = 0, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-0-1] ___________________
axis = 0, order = 1, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-0-2] ___________________
axis = 0, order = 2, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-1-0] ___________________
axis = 1, order = 0, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-1-1] ___________________
axis = 1, order = 1, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-1-2] ___________________
axis = 1, order = 2, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-2-0] ___________________
axis = 2, order = 0, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-2-1] ___________________
axis = 2, order = 1, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[False-2-2] ___________________
axis = 2, order = 2, use_dask = False
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-0-0] ____________________
axis = 0, order = 0, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-0-1] ____________________
axis = 0, order = 1, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-0-2] ____________________
axis = 0, order = 2, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-1-0] ____________________
axis = 1, order = 0, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-1-1] ____________________
axis = 1, order = 1, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-1-2] ____________________
axis = 1, order = 2, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-2-0] ____________________
axis = 2, order = 0, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-2-1] ____________________
axis = 2, order = 1, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_consistent_mask_handling[True-2-2] ____________________
axis = 2, order = 2, use_dask = True
@axis_order
def test_consistent_mask_handling(axis, order, use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:117:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_convenience_methods[False] ________________________
use_dask = False
def test_convenience_methods(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:129:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_convenience_methods[True] ________________________
use_dask = True
def test_convenience_methods(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:129:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________________ test_linewidth[False] _____________________________
use_dask = False
def test_linewidth(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:138:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________________ test_linewidth[True] _____________________________
use_dask = True
def test_linewidth(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:138:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________________ test_preserve_unit[False] ___________________________
use_dask = False
def test_preserve_unit(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:159:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________________ test_preserve_unit[True] ___________________________
use_dask = True
def test_preserve_unit(use_dask):
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:159:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________________ test_with_flux_unit[False] __________________________
use_dask = False
def test_with_flux_unit(use_dask):
"""
As of Issue 184, redundant with test_reference
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:173:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________________ test_with_flux_unit[True] ___________________________
use_dask = True
def test_with_flux_unit(use_dask):
"""
As of Issue 184, redundant with test_reference
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:173:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-0-cube] _____________________
order = 0, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-0-slice] ____________________
order = 0, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-0-auto] _____________________
order = 0, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-0-0-ray] _____________________
order = 0, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-1-cube] _____________________
order = 0, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-1-slice] ____________________
order = 0, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-1-auto] _____________________
order = 0, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-0-1-ray] _____________________
order = 0, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-2-cube] _____________________
order = 0, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-2-slice] ____________________
order = 0, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-0-2-auto] _____________________
order = 0, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-0-2-ray] _____________________
order = 0, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-0-cube] _____________________
order = 1, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-0-slice] ____________________
order = 1, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-0-auto] _____________________
order = 1, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-1-0-ray] _____________________
order = 1, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-1-cube] _____________________
order = 1, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-1-slice] ____________________
order = 1, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-1-auto] _____________________
order = 1, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-1-1-ray] _____________________
order = 1, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-2-cube] _____________________
order = 1, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-2-slice] ____________________
order = 1, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-1-2-auto] _____________________
order = 1, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-1-2-ray] _____________________
order = 1, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-0-cube] _____________________
order = 2, axis = 0, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-0-slice] ____________________
order = 2, axis = 0, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-0-auto] _____________________
order = 2, axis = 0, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-2-0-ray] _____________________
order = 2, axis = 0, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-1-cube] _____________________
order = 2, axis = 1, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-1-slice] ____________________
order = 2, axis = 1, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-1-auto] _____________________
order = 2, axis = 1, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-2-1-ray] _____________________
order = 2, axis = 1, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-2-cube] _____________________
order = 2, axis = 2, how = 'cube', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-2-slice] ____________________
order = 2, axis = 2, how = 'slice', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[False-2-2-auto] _____________________
order = 2, axis = 2, how = 'auto', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[False-2-2-ray] _____________________
order = 2, axis = 2, how = 'ray', use_dask = False
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-0-cube] _____________________
order = 0, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-0-0-slice] _____________________
order = 0, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-0-auto] _____________________
order = 0, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-0-ray] ______________________
order = 0, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-1-cube] _____________________
order = 0, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-0-1-slice] _____________________
order = 0, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-1-auto] _____________________
order = 0, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-1-ray] ______________________
order = 0, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-2-cube] _____________________
order = 0, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-0-2-slice] _____________________
order = 0, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-2-auto] _____________________
order = 0, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-0-2-ray] ______________________
order = 0, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-0-cube] _____________________
order = 1, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-1-0-slice] _____________________
order = 1, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-0-auto] _____________________
order = 1, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-0-ray] ______________________
order = 1, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-1-cube] _____________________
order = 1, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-1-1-slice] _____________________
order = 1, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-1-auto] _____________________
order = 1, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-1-ray] ______________________
order = 1, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-2-cube] _____________________
order = 1, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-1-2-slice] _____________________
order = 1, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-2-auto] _____________________
order = 1, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-1-2-ray] ______________________
order = 1, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-0-cube] _____________________
order = 2, axis = 0, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-2-0-slice] _____________________
order = 2, axis = 0, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-0-auto] _____________________
order = 2, axis = 0, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-0-ray] ______________________
order = 2, axis = 0, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-1-cube] _____________________
order = 2, axis = 1, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-2-1-slice] _____________________
order = 2, axis = 1, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-1-auto] _____________________
order = 2, axis = 1, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-1-ray] ______________________
order = 2, axis = 1, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-2-cube] _____________________
order = 2, axis = 2, how = 'cube', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________ test_how_withfluxunit[True-2-2-slice] _____________________
order = 2, axis = 2, how = 'slice', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-2-auto] _____________________
order = 2, axis = 2, how = 'auto', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_how_withfluxunit[True-2-2-ray] ______________________
order = 2, axis = 2, how = 'ray', use_dask = True
@pytest.mark.parametrize(('order', 'axis', 'how'),
[(o, a, h)
for o in [0, 1, 2]
for a in [0, 1, 2]
for h in ['cube', 'slice', 'auto', 'ray']])
def test_how_withfluxunit(order, axis, how, use_dask):
"""
Regression test for issue 180
As of issue 184, this is mostly redundant with test_reference except that
it (kind of) checks that units are set
"""
> mc_hdu = moment_cube()
spectral_cube/tests/test_moments.py:198:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________________ test_pix_size _________________________________
def test_pix_size():
> mc_hdu = moment_cube()
spectral_cube/tests/test_performance.py:45:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_______________________ test_compare_pix_size_approaches _______________________
def test_compare_pix_size_approaches():
> mc_hdu = moment_cube()
spectral_cube/tests/test_performance.py:59:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_________________________________ test_pix_cen _________________________________
def test_pix_cen():
> mc_hdu = moment_cube()
spectral_cube/tests/test_performance.py:71:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/tests/test_moments.py:61: in moment_cube
cube = np.arange(27).reshape([3, 3, 3]).astype(np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________________ test_convolution[False] ____________________________
data_255_delta = PosixPath('/build/pytest-of-nixbld/pytest-0/test_convolution_False_0/255_delta.fits')
use_dask = False
def test_convolution(data_255_delta, use_dask):
cube, data = cube_and_raw(data_255_delta, use_dask=use_dask)
# 1" convolved with 1.5" -> 1.8027....
target_beam = Beam(1.802775637731995*u.arcsec, 1.802775637731995*u.arcsec,
0*u.deg)
> conv_cube = cube.convolve_to(target_beam)
spectral_cube/tests/test_regrid.py:42:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/utils.py:49: in wrapper
return function(self, *args, **kwargs)
spectral_cube/spectral_cube.py:3216: in convolve_to
newcube = self.apply_function_parallel_spatial(convfunc,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
----------------------------- Captured stderr call -----------------------------
WARNING: PossiblySlowWarning: This function (<function BaseSpectralCube.convolve_to at 0x7ffe60848700>) requires loading the entire cube into memory and may therefore be slow. [spectral_cube.utils]
------------------------------ Captured log call -------------------------------
WARNING  astropy:logger.py:237 PossiblySlowWarning: This function (<function BaseSpectralCube.convolve_to at 0x7ffe60848700>) requires loading the entire cube into memory and may therefore be slow.
_________________________ test_beams_convolution[True] _________________________
data_455_delta_beams = PosixPath('/build/pytest-of-nixbld/pytest-0/test_beams_convolution_True_0/455_delta_beams.fits')
use_dask = True
def test_beams_convolution(data_455_delta_beams, use_dask):
cube, data = cube_and_raw(data_455_delta_beams, use_dask=use_dask)
# 1" convolved with 1.5" -> 1.8027....
target_beam = Beam(1.802775637731995*u.arcsec, 1.802775637731995*u.arcsec,
0*u.deg)
> conv_cube = cube.convolve_to(target_beam)
spectral_cube/tests/test_regrid.py:66:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/dask_spectral_cube.py:77: in wrapper
cube = function(self, *args, **kwargs)
spectral_cube/dask_spectral_cube.py:1531: in convolve_to
beams = da.from_array(np.array(beams, dtype=np.object)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'object'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
______________________ test_beams_convolution_equal[True] ______________________
data_522_delta_beams = PosixPath('/build/pytest-of-nixbld/pytest-0/test_beams_convolution_equal_T0/522_delta_beams.fits')
use_dask = True
def test_beams_convolution_equal(data_522_delta_beams, use_dask):
cube, data = cube_and_raw(data_522_delta_beams, use_dask=use_dask)
# Only checking that the equal beam case is handled correctly.
# Fake the beam in the first channel. Then ensure that the first channel
# has NOT been convolved.
target_beam = Beam(1.0 * u.arcsec, 1.0 * u.arcsec, 0.0 * u.deg)
cube.beams.major[0] = target_beam.major
cube.beams.minor[0] = target_beam.minor
cube.beams.pa[0] = target_beam.pa
> conv_cube = cube.convolve_to(target_beam)
spectral_cube/tests/test_regrid.py:90:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/dask_spectral_cube.py:77: in wrapper
cube = function(self, *args, **kwargs)
spectral_cube/dask_spectral_cube.py:1531: in convolve_to
beams = da.from_array(np.array(beams, dtype=np.object)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'object'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
_________________________ test_spectral_smooth[False] __________________________
data_522_delta = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_False_0/522_delta.fits')
use_dask = False
def test_spectral_smooth(data_522_delta, use_dask):
cube, data = cube_and_raw(data_522_delta, use_dask=use_dask)
> result = cube.spectral_smooth(kernel=convolution.Gaussian1DKernel(1.0), use_memmap=False)
spectral_cube/tests/test_regrid.py:129:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:3047: in spectral_smooth
return self.apply_function_parallel_spectral(convolve,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2800: in _apply_function_parallel_base
outcube = np.empty(shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________________ test_spectral_smooth[True] __________________________
data_522_delta = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_True_0/522_delta.fits')
use_dask = True
def test_spectral_smooth(data_522_delta, use_dask):
cube, data = cube_and_raw(data_522_delta, use_dask=use_dask)
result = cube.spectral_smooth(kernel=convolution.Gaussian1DKernel(1.0), use_memmap=False)
> np.testing.assert_almost_equal(result[:,0,0].value,
convolution.Gaussian1DKernel(1.0,
x_size=5).array,
4)
spectral_cube/tests/test_regrid.py:131:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/nix/store/syz2y6j53y5hpzbs7l0965zwxshi8iyl-python3-3.10.10/lib/python3.10/contextlib.py:79: in inner
return func(*args, **kwds)
/nix/store/syz2y6j53y5hpzbs7l0965zwxshi8iyl-python3-3.10.10/lib/python3.10/contextlib.py:79: in inner
return func(*args, **kwds)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
args = (<function assert_array_almost_equal.<locals>.compare at 0x7ffe601489d0>, array([0.05399113, 0.24197145, 0.39894347, 0.24197145, 0.05399113]), array([0.05448868, 0.24420134, 0.40261995, 0.24420134, 0.05448868]))
kwds = {'err_msg': '', 'header': 'Arrays are not almost equal to 4 decimals', 'precision': 4, 'verbose': True}
@wraps(func)
def inner(*args, **kwds):
with self._recreate_cm():
> return func(*args, **kwds)
E AssertionError: 
E Arrays are not almost equal to 4 decimals
E 
E Mismatched elements: 5 / 5 (100%)
E Max absolute difference: 0.00367648
E Max relative difference: 0.00913138
E x: array([0.054 , 0.242 , 0.3989, 0.242 , 0.054 ])
E y: array([0.0545, 0.2442, 0.4026, 0.2442, 0.0545])
/nix/store/syz2y6j53y5hpzbs7l0965zwxshi8iyl-python3-3.10.10/lib/python3.10/contextlib.py:79: AssertionError
_________________________ test_spectral_smooth_4cores __________________________
data_522_delta = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_4cores0/522_delta.fits')
@pytest.mark.skipif('WINDOWS')
def test_spectral_smooth_4cores(data_522_delta):
pytest.importorskip('joblib')
cube, data = cube_and_raw(data_522_delta, use_dask=False)
> result = cube.spectral_smooth(kernel=convolution.Gaussian1DKernel(1.0), num_cores=4, use_memmap=True)
spectral_cube/tests/test_regrid.py:161:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:3047: in spectral_smooth
return self.apply_function_parallel_spectral(convolve,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
____________________________ test_downsample[True] _____________________________
use_memmap = True
data_255 = PosixPath('/build/pytest-of-nixbld/pytest-0/test_downsample_True_0/255.fits')
@pytest.mark.parametrize('use_memmap', (True,False))
def test_downsample(use_memmap, data_255):
# FIXME: this test should be updated to use the use_dask fixture once
# DaskSpectralCube.downsample_axis is fixed.
cube, data = cube_and_raw(data_255, use_dask=False)
> dscube = cube.downsample_axis(factor=2, axis=0, use_memmap=use_memmap)
spectral_cube/tests/test_regrid.py:381:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/utils.py:49: in wrapper
return function(self, *args, **kwargs)
spectral_cube/spectral_cube.py:3355: in downsample_axis
dsarr = np.memmap(ntf, mode='w+', shape=newshape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
----------------------------- Captured stderr call -----------------------------
WARNING: PossiblySlowWarning: This function (<function BaseSpectralCube.downsample_axis at 0x7ffe608488b0>) requires loading the entire cube into memory and may therefore be slow. [spectral_cube.utils]
------------------------------ Captured log call -------------------------------
WARNING  astropy:logger.py:237 PossiblySlowWarning: This function (<function BaseSpectralCube.downsample_axis at 0x7ffe608488b0>) requires loading the entire cube into memory and may therefore be slow.
__________________________ test_downsample_wcs[True] ___________________________
use_memmap = True
data_255 = PosixPath('/build/pytest-of-nixbld/pytest-0/test_downsample_wcs_True_0/255.fits')
@pytest.mark.parametrize('use_memmap', (True,False))
def test_downsample_wcs(use_memmap, data_255):
# FIXME: this test should be updated to use the use_dask fixture once
# DaskSpectralCube.downsample_axis is fixed.
cube, data = cube_and_raw(data_255, use_dask=False)
> dscube = (cube
.downsample_axis(factor=2, axis=1, use_memmap=use_memmap)
.downsample_axis(factor=2, axis=2, use_memmap=use_memmap))
spectral_cube/tests/test_regrid.py:420:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/utils.py:49: in wrapper
return function(self, *args, **kwargs)
spectral_cube/spectral_cube.py:3355: in downsample_axis
dsarr = np.memmap(ntf, mode='w+', shape=newshape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
----------------------------- Captured stderr call -----------------------------
WARNING: PossiblySlowWarning: This function (<function BaseSpectralCube.downsample_axis at 0x7ffe608488b0>) requires loading the entire cube into memory and may therefore be slow. [spectral_cube.utils]
------------------------------ Captured log call -------------------------------
WARNING  astropy:logger.py:237 PossiblySlowWarning: This function (<function BaseSpectralCube.downsample_axis at 0x7ffe608488b0>) requires loading the entire cube into memory and may therefore be slow.
_________________ test_with_mask_with_good_array_shape[False] __________________
use_dask = False
def test_with_mask_with_good_array_shape(use_dask):
cube = _dummy_cube(use_dask)
> mask = np.zeros((1, 5), dtype=np.bool)
spectral_cube/tests/test_spectral_cube.py:994:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'bool'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.bool` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
__________________ test_with_mask_with_good_array_shape[True] __________________
use_dask = True
def test_with_mask_with_good_array_shape(use_dask):
cube = _dummy_cube(use_dask)
> mask = np.zeros((1, 5), dtype=np.bool)
spectral_cube/tests/test_spectral_cube.py:994:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'bool'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.bool` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
__________________ test_with_mask_with_bad_array_shape[False] __________________
use_dask = False
def test_with_mask_with_bad_array_shape(use_dask):
cube = _dummy_cube(use_dask)
> mask = np.zeros((5, 5), dtype=np.bool)
spectral_cube/tests/test_spectral_cube.py:1002:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'bool'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.bool` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
__________________ test_with_mask_with_bad_array_shape[True] ___________________
use_dask = True
def test_with_mask_with_bad_array_shape(use_dask):
cube = _dummy_cube(use_dask)
> mask = np.zeros((5, 5), dtype=np.bool)
spectral_cube/tests/test_spectral_cube.py:1002:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'bool'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.bool` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
____________________________ test_convolve_to[True] ____________________________
data_vda_beams = PosixPath('/build/pytest-of-nixbld/pytest-0/test_convolve_to_True_0/vda_beams.fits')
use_dask = True
def test_convolve_to(data_vda_beams, use_dask):
cube, data = cube_and_raw(data_vda_beams, use_dask=use_dask)
> convolved = cube.convolve_to(Beam(0.5*u.arcsec))
spectral_cube/tests/test_spectral_cube.py:2112:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/dask_spectral_cube.py:77: in wrapper
cube = function(self, *args, **kwargs)
spectral_cube/dask_spectral_cube.py:1531: in convolve_to
beams = da.from_array(np.array(beams, dtype=np.object)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'object'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
____________________ test_convolve_to_jybeam_onebeam[False] ____________________
point_source_5_one_beam = PosixPath('/build/pytest-of-nixbld/pytest-0/test_convolve_to_jybeam_onebea0/point_source_conv_5_one_beam.fits')
use_dask = False
def test_convolve_to_jybeam_onebeam(point_source_5_one_beam, use_dask):
cube, data = cube_and_raw(point_source_5_one_beam, use_dask=use_dask)
> convolved = cube.convolve_to(Beam(10*u.arcsec))
spectral_cube/tests/test_spectral_cube.py:2122:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/utils.py:49: in wrapper
return function(self, *args, **kwargs)
spectral_cube/spectral_cube.py:3216: in convolve_to
newcube = self.apply_function_parallel_spatial(convfunc,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
----------------------------- Captured stderr call -----------------------------
WARNING: StokesWarning: Cube is a Stokes cube, returning spectral cube for I component [spectral_cube.io.core]
WARNING: PossiblySlowWarning: This function (<function BaseSpectralCube.convolve_to at 0x7ffe60848700>) requires loading the entire cube into memory and may therefore be slow. [spectral_cube.utils]
------------------------------ Captured log call -------------------------------
WARNING  astropy:logger.py:237 StokesWarning: Cube is a Stokes cube, returning spectral cube for I component
WARNING  astropy:logger.py:237 PossiblySlowWarning: This function (<function BaseSpectralCube.convolve_to at 0x7ffe60848700>) requires loading the entire cube into memory and may therefore be slow.
___________________ test_convolve_to_jybeam_multibeams[True] ___________________
point_source_5_spectral_beams = PosixPath('/build/pytest-of-nixbld/pytest-0/test_convolve_to_jybeam_multib1/point_source_conv_5_spectral_beams.fits')
use_dask = True
def test_convolve_to_jybeam_multibeams(point_source_5_spectral_beams, use_dask):
cube, data = cube_and_raw(point_source_5_spectral_beams, use_dask=use_dask)
> convolved = cube.convolve_to(Beam(10*u.arcsec))
spectral_cube/tests/test_spectral_cube.py:2134:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/dask_spectral_cube.py:77: in wrapper
cube = function(self, *args, **kwargs)
spectral_cube/dask_spectral_cube.py:1531: in convolve_to
beams = da.from_array(np.array(beams, dtype=np.object)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'object'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
----------------------------- Captured stderr call -----------------------------
WARNING: StokesWarning: Cube is a Stokes cube, returning spectral cube for I component [spectral_cube.io.core]
------------------------------ Captured log call -------------------------------
WARNING  astropy:logger.py:237 StokesWarning: Cube is a Stokes cube, returning spectral cube for I component
____________________ test_convolve_to_with_bad_beams[True] _____________________
data_vda_beams = PosixPath('/build/pytest-of-nixbld/pytest-0/test_convolve_to_with_bad_beam1/vda_beams.fits')
use_dask = True
def test_convolve_to_with_bad_beams(data_vda_beams, use_dask):
cube, data = cube_and_raw(data_vda_beams, use_dask=use_dask)
> convolved = cube.convolve_to(Beam(0.5*u.arcsec))
spectral_cube/tests/test_spectral_cube.py:2145:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/dask_spectral_cube.py:77: in wrapper
cube = function(self, *args, **kwargs)
spectral_cube/dask_spectral_cube.py:1531: in convolve_to
beams = da.from_array(np.array(beams, dtype=np.object)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'object'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
> warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
E FutureWarning: In the future `np.object` will be defined as the corresponding NumPy scalar.
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:300: FutureWarning
________________________ test_spatial_smooth_g2d[False] ________________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spatial_smooth_g2d_False_0/adv.fits')
use_dask = False
def test_spatial_smooth_g2d(data_adv, use_dask):
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
# Guassian 2D smoothing test
g2d = Gaussian2DKernel(3)
> cube_g2d = cube.spatial_smooth(g2d)
spectral_cube/tests/test_spectral_cube.py:2307:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2703: in spatial_smooth
newcube = self.apply_function_parallel_spatial(_gsmooth_image,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________ test_spatial_smooth_preserves_unit[False] ___________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spatial_smooth_preserves_0/adv.fits')
use_dask = False
def test_spatial_smooth_preserves_unit(data_adv, use_dask):
"""
Regression test for issue527
"""
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
cube._unit = u.K
# Guassian 2D smoothing test
g2d = Gaussian2DKernel(3)
> cube_g2d = cube.spatial_smooth(g2d)
spectral_cube/tests/test_spectral_cube.py:2334:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2703: in spatial_smooth
newcube = self.apply_function_parallel_spatial(_gsmooth_image,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
________________________ test_spatial_smooth_t2d[False] ________________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spatial_smooth_t2d_False_0/adv.fits')
use_dask = False
def test_spatial_smooth_t2d(data_adv, use_dask):
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
# Tophat 2D smoothing test
t2d = Tophat2DKernel(3)
> cube_t2d = cube.spatial_smooth(t2d)
spectral_cube/tests/test_spectral_cube.py:2345:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2703: in spatial_smooth
newcube = self.apply_function_parallel_spatial(_gsmooth_image,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
______________________ test_spatial_smooth_median[False] _______________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spatial_smooth_median_Fal0/adv.fits')
use_dask = False
def test_spatial_smooth_median(data_adv, use_dask):
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
> cube_median = cube.spatial_smooth_median(3)
spectral_cube/tests/test_spectral_cube.py:2394:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2667: in spatial_smooth_median
newcube = self.apply_function_parallel_spatial(_msmooth_image,
spectral_cube/spectral_cube.py:2926: in apply_function_parallel_spatial
return self._apply_function_parallel_base(images, function,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________ test_spectral_smooth_median[False-None] ____________________
num_cores = None
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_median_Fa0/adv.fits')
use_dask = False
@pytest.mark.parametrize('num_cores', (None, 1))
def test_spectral_smooth_median(num_cores, data_adv, use_dask):
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
> cube_spectral_median = cube.spectral_smooth_median(3, num_cores=num_cores)
spectral_cube/tests/test_spectral_cube.py:2418:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_spectral_smooth_median[False-1] _____________________
num_cores = 1
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_median_Fa1/adv.fits')
use_dask = False
@pytest.mark.parametrize('num_cores', (None, 1))
def test_spectral_smooth_median(num_cores, data_adv, use_dask):
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
> cube_spectral_median = cube.spectral_smooth_median(3, num_cores=num_cores)
spectral_cube/tests/test_spectral_cube.py:2418:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
__________________ test_spectral_smooth_median_4cores[False] ___________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_spectral_smooth_median_4c0/adv.fits')
use_dask = False
@pytest.mark.skipif('WINDOWS')
def test_spectral_smooth_median_4cores(data_adv, use_dask):
pytest.importorskip('joblib')
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=use_dask)
> cube_spectral_median = cube.spectral_smooth_median(3, num_cores=4)
spectral_cube/tests/test_spectral_cube.py:2434:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
_____________________ test_smooth_update_function_parallel _____________________
capsys = <_pytest.capture.CaptureFixture object at 0x7ffe5c24db10>
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_smooth_update_function_pa0/adv.fits')
@pytest.mark.skipif('WINDOWS')
def test_smooth_update_function_parallel(capsys, data_adv):
pytest.importorskip('joblib')
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=False)
# this is potentially a major disaster: if update_function can't be
# pickled, it won't work, which is why update_function is (very badly)
# defined outside of this function
> cube_spectral_median = cube.spectral_smooth_median(3, num_cores=4,
update_function=update_function)
spectral_cube/tests/test_spectral_cube.py:2456:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
______________________ test_smooth_update_function_serial ______________________
capsys = <_pytest.capture.CaptureFixture object at 0x7ffe5c37d5d0>
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_smooth_update_function_se0/adv.fits')
def test_smooth_update_function_serial(capsys, data_adv):
# This function only makes sense for the plain SpectralCube class
pytest.importorskip('scipy.ndimage')
cube, data = cube_and_raw(data_adv, use_dask=False)
def update_function():
print("Update Function Call")
> cube_spectral_median = cube.spectral_smooth_median(3, num_cores=1, parallel=False,
update_function=update_function)
spectral_cube/tests/test_spectral_cube.py:2475:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________________ test_parallel_bad_params ___________________________
data_adv = PosixPath('/build/pytest-of-nixbld/pytest-0/test_parallel_bad_params0/adv.fits')
@pytest.mark.skipif('not scipyOK')
def test_parallel_bad_params(data_adv):
# This function only makes sense for the plain SpectralCube class
cube, data = cube_and_raw(data_adv, use_dask=False)
with pytest.raises(ValueError,
match=("parallel execution was not requested, but "
"multiple cores were: these are incompatible "
"options. Either specify num_cores=1 or "
"parallel=True")):
> cube.spectral_smooth_median(3, num_cores=2, parallel=False,
update_function=update_function)
spectral_cube/tests/test_spectral_cube.py:2494:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
spectral_cube/spectral_cube.py:128: in wrapper
return func(*args, **kwargs)
spectral_cube/spectral_cube.py:2730: in spectral_smooth_median
return self.apply_function_parallel_spectral(ndimage.filters.median_filter,
spectral_cube/spectral_cube.py:2982: in apply_function_parallel_spectral
return self._apply_function_parallel_base(iteration_data=spectra,
spectral_cube/spectral_cube.py:2790: in _apply_function_parallel_base
outcube = np.memmap(ntf, mode='w+', shape=self.shape, dtype=np.float)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
attr = 'float'
def __getattr__(attr):
# Warn for expired attributes, and return a dummy function
# that always raises an exception.
import warnings
try:
msg = __expired_functions__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
def _expired(*args, **kwds):
raise RuntimeError(msg)
return _expired
# Emit warnings for deprecated attributes
try:
val, msg = __deprecated_attrs__[attr]
except KeyError:
pass
else:
warnings.warn(msg, DeprecationWarning, stacklevel=2)
return val
if attr in __future_scalars__:
# And future warnings for those that will change, but also give
# the AttributeError
warnings.warn(
f"In the future `np.{attr}` will be defined as the "
"corresponding NumPy scalar.", FutureWarning, stacklevel=2)
if attr in __former_attrs__:
> raise AttributeError(__former_attrs__[attr])
E AttributeError: module 'numpy' has no attribute 'float'.
E `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
E The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
E https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/__init__.py:305: AttributeError
___________________________ test_proj_imshow[False] ____________________________
data_vda_jybeam_lower = PosixPath('/build/pytest-of-nixbld/pytest-0/test_proj_imshow_False_0/vda_Jybeam_lower.fits')
use_dask = False
def test_proj_imshow(data_vda_jybeam_lower, use_dask):
plt = pytest.importorskip('matplotlib.pyplot')
cube, data = cube_and_raw(data_vda_jybeam_lower, use_dask=use_dask)
mom0 = cube.moment0()
if LooseVersion(plt.matplotlib.__version__) < LooseVersion('2.1'):
# imshow is now only compatible with more recent versions of matplotlib
# (apparently 2.0.2 was still incompatible)
plt.imshow(mom0.value)
else:
> plt.imshow(mom0)
spectral_cube/tests/test_visualization.py:26:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/pyplot.py:2668: in imshow
__ret = gca().imshow(
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/__init__.py:1442: in inner
return func(ax, *map(sanitize_sequence, args), **kwargs)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/axes/_axes.py:5665: in imshow
im.set_data(X)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/image.py:697: in set_data
self._A = cbook.safe_masked_invalid(A, copy=True)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/cbook/__init__.py:715: in safe_masked_invalid
xm = np.ma.masked_invalid(x, copy=False)
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/ma/core.py:2360: in masked_invalid
res = masked_where(~(np.isfinite(a)), a, copy=copy)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
condition = array([[False, False],
[False, False],
[False, False]])
a = <Projection [[2.01540319, 3.38838015],
[3.023533 , 2.64380312],
[2.2072431 , 1.99982092]] Jy km / (beam s)>
copy = False
def masked_where(condition, a, copy=True):
"""
Mask an array where a condition is met.
Return `a` as an array masked where `condition` is True.
Any masked values of `a` or `condition` are also masked in the output.
Parameters
----------
condition : array_like
Masking condition. When `condition` tests floating point values for
equality, consider using ``masked_values`` instead.
a : array_like
Array to mask.
copy : bool
If True (default) make a copy of `a` in the result. If False modify
`a` in place and return a view.
Returns
-------
result : MaskedArray
The result of masking `a` where `condition` is True.
See Also
--------
masked_values : Mask using floating point equality.
masked_equal : Mask where equal to a given value.
masked_not_equal : Mask where `not` equal to a given value.
masked_less_equal : Mask where less than or equal to a given value.
masked_greater_equal : Mask where greater than or equal to a given value.
masked_less : Mask where less than a given value.
masked_greater : Mask where greater than a given value.
masked_inside : Mask inside a given interval.
masked_outside : Mask outside a given interval.
masked_invalid : Mask invalid values (NaNs or infs).
Examples
--------
>>> import numpy.ma as ma
>>> a = np.arange(4)
>>> a
array([0, 1, 2, 3])
>>> ma.masked_where(a <= 2, a)
masked_array(data=[--, --, --, 3],
mask=[ True, True, True, False],
fill_value=999999)
Mask array `b` conditional on `a`.
>>> b = ['a', 'b', 'c', 'd']
>>> ma.masked_where(a == 2, b)
masked_array(data=['a', 'b', --, 'd'],
mask=[False, False, True, False],
fill_value='N/A',
dtype='<U1')
Effect of the `copy` argument.
>>> c = ma.masked_where(a <= 2, a)
>>> c
masked_array(data=[--, --, --, 3],
mask=[ True, True, True, False],
fill_value=999999)
>>> c[0] = 99
>>> c
masked_array(data=[99, --, --, 3],
mask=[False, True, True, False],
fill_value=999999)
>>> a
array([0, 1, 2, 3])
>>> c = ma.masked_where(a <= 2, a, copy=False)
>>> c[0] = 99
>>> c
masked_array(data=[99, --, --, 3],
mask=[False, True, True, False],
fill_value=999999)
>>> a
array([99, 1, 2, 3])
When `condition` or `a` contain masked values.
>>> a = np.arange(4)
>>> a = ma.masked_where(a == 2, a)
>>> a
masked_array(data=[0, 1, --, 3],
mask=[False, False, True, False],
fill_value=999999)
>>> b = np.arange(4)
>>> b = ma.masked_where(b == 0, b)
>>> b
masked_array(data=[--, 1, 2, 3],
mask=[ True, False, False, False],
fill_value=999999)
>>> ma.masked_where(a == 3, b)
masked_array(data=[--, 1, --, --],
mask=[ True, False, True, True],
fill_value=999999)
"""
# Make sure that condition is a valid standard-type mask.
cond = make_mask(condition, shrink=False)
a = np.array(a, copy=copy, subok=True)
(cshape, ashape) = (cond.shape, a.shape)
if cshape and cshape != ashape:
raise IndexError("Inconsistent shape between the condition and the input"
" (got %s and %s)" % (cshape, ashape))
if hasattr(a, '_mask'):
cond = mask_or(cond, a._mask)
cls = type(a)
else:
cls = MaskedArray
result = a.view(cls)
# Assign to *.mask so that structured masks are handled correctly.
> result.mask = _shrink_mask(cond)
E AttributeError: can't set attribute 'mask'
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/ma/core.py:1942: AttributeError
____________________________ test_proj_imshow[True] ____________________________
data_vda_jybeam_lower = PosixPath('/build/pytest-of-nixbld/pytest-0/test_proj_imshow_True_0/vda_Jybeam_lower.fits')
use_dask = True
def test_proj_imshow(data_vda_jybeam_lower, use_dask):
plt = pytest.importorskip('matplotlib.pyplot')
cube, data = cube_and_raw(data_vda_jybeam_lower, use_dask=use_dask)
mom0 = cube.moment0()
if LooseVersion(plt.matplotlib.__version__) < LooseVersion('2.1'):
# imshow is now only compatible with more recent versions of matplotlib
# (apparently 2.0.2 was still incompatible)
plt.imshow(mom0.value)
else:
> plt.imshow(mom0)
spectral_cube/tests/test_visualization.py:26:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/pyplot.py:2668: in imshow
__ret = gca().imshow(
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/__init__.py:1442: in inner
return func(ax, *map(sanitize_sequence, args), **kwargs)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/axes/_axes.py:5665: in imshow
im.set_data(X)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/image.py:697: in set_data
self._A = cbook.safe_masked_invalid(A, copy=True)
/nix/store/0zahrf4nj5blqsxi0653swx9875hpfv6-python3.10-matplotlib-3.7.0/lib/python3.10/site-packages/matplotlib/cbook/__init__.py:715: in safe_masked_invalid
xm = np.ma.masked_invalid(x, copy=False)
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/ma/core.py:2360: in masked_invalid
res = masked_where(~(np.isfinite(a)), a, copy=copy)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
condition = array([[False, False],
[False, False],
[False, False]])
a = <Projection [[2.01540319, 3.38838015],
[3.023533 , 2.64380312],
[2.2072431 , 1.99982092]] Jy km / (beam s)>
copy = False
def masked_where(condition, a, copy=True):
"""
Mask an array where a condition is met.
Return `a` as an array masked where `condition` is True.
Any masked values of `a` or `condition` are also masked in the output.
Parameters
----------
condition : array_like
Masking condition. When `condition` tests floating point values for
equality, consider using ``masked_values`` instead.
a : array_like
Array to mask.
copy : bool
If True (default) make a copy of `a` in the result. If False modify
`a` in place and return a view.
Returns
-------
result : MaskedArray
The result of masking `a` where `condition` is True.
See Also
--------
masked_values : Mask using floating point equality.
masked_equal : Mask where equal to a given value.
masked_not_equal : Mask where `not` equal to a given value.
masked_less_equal : Mask where less than or equal to a given value.
masked_greater_equal : Mask where greater than or equal to a given value.
masked_less : Mask where less than a given value.
masked_greater : Mask where greater than a given value.
masked_inside : Mask inside a given interval.
masked_outside : Mask outside a given interval.
masked_invalid : Mask invalid values (NaNs or infs).
Examples
--------
>>> import numpy.ma as ma
>>> a = np.arange(4)
>>> a
array([0, 1, 2, 3])
>>> ma.masked_where(a <= 2, a)
masked_array(data=[--, --, --, 3],
mask=[ True, True, True, False],
fill_value=999999)
Mask array `b` conditional on `a`.
>>> b = ['a', 'b', 'c', 'd']
>>> ma.masked_where(a == 2, b)
masked_array(data=['a', 'b', --, 'd'],
mask=[False, False, True, False],
fill_value='N/A',
dtype='<U1')
Effect of the `copy` argument.
>>> c = ma.masked_where(a <= 2, a)
>>> c
masked_array(data=[--, --, --, 3],
mask=[ True, True, True, False],
fill_value=999999)
>>> c[0] = 99
>>> c
masked_array(data=[99, --, --, 3],
mask=[False, True, True, False],
fill_value=999999)
>>> a
array([0, 1, 2, 3])
>>> c = ma.masked_where(a <= 2, a, copy=False)
>>> c[0] = 99
>>> c
masked_array(data=[99, --, --, 3],
mask=[False, True, True, False],
fill_value=999999)
>>> a
array([99, 1, 2, 3])
When `condition` or `a` contain masked values.
>>> a = np.arange(4)
>>> a = ma.masked_where(a == 2, a)
>>> a
masked_array(data=[0, 1, --, 3],
mask=[False, False, True, False],
fill_value=999999)
>>> b = np.arange(4)
>>> b = ma.masked_where(b == 0, b)
>>> b
masked_array(data=[--, 1, 2, 3],
mask=[ True, False, False, False],
fill_value=999999)
>>> ma.masked_where(a == 3, b)
masked_array(data=[--, 1, --, --],
mask=[ True, False, True, True],
fill_value=999999)
"""
# Make sure that condition is a valid standard-type mask.
cond = make_mask(condition, shrink=False)
a = np.array(a, copy=copy, subok=True)
(cshape, ashape) = (cond.shape, a.shape)
if cshape and cshape != ashape:
raise IndexError("Inconsistent shape between the condition and the input"
" (got %s and %s)" % (cshape, ashape))
if hasattr(a, '_mask'):
cond = mask_or(cond, a._mask)
cls = type(a)
else:
cls = MaskedArray
result = a.view(cls)
# Assign to *.mask so that structured masks are handled correctly.
> result.mask = _shrink_mask(cond)
E AttributeError: can't set attribute 'mask'
/nix/store/g7z1488i6lhqvh1p3mcg0gcrnll9986v-python3.10-numpy-1.24.2/lib/python3.10/site-packages/numpy/ma/core.py:1942: AttributeError
=========================== short test summary info ============================
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-0-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-0-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-0-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-1-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-1-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-1-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-2-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-2-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[False-2-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-0-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-0-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-0-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-1-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-1-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-1-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-2-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-2-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_strategies_consistent[True-2-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-0-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-1-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[False-2-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-0-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-1-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_reference[True-2-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-0-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-0-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-0-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-1-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-1-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-1-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-2-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-2-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[False-2-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-0-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-0-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-0-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-1-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-1-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-1-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-2-0] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-2-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_consistent_mask_handling[True-2-2] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_convenience_methods[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_convenience_methods[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_linewidth[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_linewidth[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_preserve_unit[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_preserve_unit[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_with_flux_unit[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_with_flux_unit[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-0-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-1-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[False-2-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-0-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-1-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-0-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-0-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-0-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-0-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-1-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-1-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-1-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-1-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-2-cube] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-2-slice] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-2-auto] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_moments.py::test_how_withfluxunit[True-2-2-ray] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_performance.py::test_pix_size - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_performance.py::test_compare_pix_size_approaches - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_performance.py::test_pix_cen - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_regrid.py::test_convolution[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_regrid.py::test_beams_convolution[True] - FutureWarning: In the future `np.object` will be defined as the correspondi...
FAILED spectral_cube/tests/test_regrid.py::test_beams_convolution_equal[True] - FutureWarning: In the future `np.object` will be defined as the correspondi...
FAILED spectral_cube/tests/test_regrid.py::test_spectral_smooth[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_regrid.py::test_spectral_smooth[True] - AssertionError:
FAILED spectral_cube/tests/test_regrid.py::test_spectral_smooth_4cores - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_regrid.py::test_downsample[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_regrid.py::test_downsample_wcs[True] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_with_mask_with_good_array_shape[False] - FutureWarning: In the future `np.bool` will be defined as the corresponding...
FAILED spectral_cube/tests/test_spectral_cube.py::test_with_mask_with_good_array_shape[True] - FutureWarning: In the future `np.bool` will be defined as the corresponding...
FAILED spectral_cube/tests/test_spectral_cube.py::test_with_mask_with_bad_array_shape[False] - FutureWarning: In the future `np.bool` will be defined as the corresponding...
FAILED spectral_cube/tests/test_spectral_cube.py::test_with_mask_with_bad_array_shape[True] - FutureWarning: In the future `np.bool` will be defined as the corresponding...
FAILED spectral_cube/tests/test_spectral_cube.py::test_convolve_to[True] - FutureWarning: In the future `np.object` will be defined as the correspondi...
FAILED spectral_cube/tests/test_spectral_cube.py::test_convolve_to_jybeam_onebeam[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_convolve_to_jybeam_multibeams[True] - FutureWarning: In the future `np.object` will be defined as the correspondi...
FAILED spectral_cube/tests/test_spectral_cube.py::test_convolve_to_with_bad_beams[True] - FutureWarning: In the future `np.object` will be defined as the correspondi...
FAILED spectral_cube/tests/test_spectral_cube.py::test_spatial_smooth_g2d[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spatial_smooth_preserves_unit[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spatial_smooth_t2d[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spatial_smooth_median[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spectral_smooth_median[False-None] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spectral_smooth_median[False-1] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_spectral_smooth_median_4cores[False] - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_smooth_update_function_parallel - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_smooth_update_function_serial - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_spectral_cube.py::test_parallel_bad_params - AttributeError: module 'numpy' has no attribute 'float'.
FAILED spectral_cube/tests/test_visualization.py::test_proj_imshow[False] - AttributeError: can't set attribute 'mask'
FAILED spectral_cube/tests/test_visualization.py::test_proj_imshow[True] - AttributeError: can't set attribute 'mask'
= 219 failed, 1233 passed, 182 skipped, 17 xfailed, 2 xpassed in 3026.81s (0:50:26) =
/nix/store/sw36plhp82916wwg6i6097rkzza7d950-stdenv-linux/setup: line 1594: pop_var_context: head of shell_variables not a function context
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment