* Update C++ sources to 3.83 #973 * Drop support for Python 3.9 #967 * Added lonlat parameter to newprojplot #963 * Fix query_disc missing pixels near poles, fixed in C++ #968 * Warn users about ud_grade effect on spectra in docstring #960 * Update CFITSIO to 4.5.0 and ensure we build it as shared lib #942 - Release 1.17.3 * Rename trapz function to support latest scipy version #953 - Release 1.17.1 * Just fixing an issue in the PyPI publish action - Release 1.17.0 * The most important modification is that now scipy and matplotlib are optional dependencies, install them with pip install healpy[all]. Also includes a lot of packaging fixes. * Optional dependencies by @swyatt7 in #910 * Fix errors with Matplotlib 3.9 by @QuLogic in #944 * [doc] pull docstrings from dist2holes and hotspots cython functions by @zonca in #920 * Improve docs of read_alm by @zonca in #930 * update C++ sources to SVN commit 1238 by @zonca in #917 * update healpix sources to r1239 by @zonca in #941 * Use alice3 from libhealpix_cxx by @lpsinger in #939 * Fix pytest-cython errors by requiring pytest<8 by @lpsinger in #913 - Drop patches * python-healpy-matplotlib-1_9-compat.patch * python-healpy-scipy-1_14-compat.patch - Remove devel package: Unused, the src is no longer in the OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-healpy?expand=0&rev=20
108 lines
3.9 KiB
RPMSpec
108 lines
3.9 KiB
RPMSpec
#
|
|
# spec file for package python-healpy
|
|
#
|
|
# Copyright (c) 2025 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
%{?sle15_python_module_pythons}
|
|
Name: python-healpy
|
|
Version: 1.18.0
|
|
Release: 0
|
|
Summary: Python library to handle pixelated data on the sphere based on HEALPix
|
|
License: GPL-2.0-only
|
|
URL: https://github.com/healpy/healpy
|
|
Source: https://files.pythonhosted.org/packages/source/h/healpy/healpy-%{version}.tar.gz
|
|
BuildRequires: %{python_module Cython}
|
|
BuildRequires: %{python_module devel >= 3.10}
|
|
BuildRequires: %{python_module numpy-devel >= 1.19}
|
|
BuildRequires: %{python_module pip}
|
|
BuildRequires: %{python_module setuptools >= 60}
|
|
BuildRequires: %{python_module setuptools_scm >= 8}
|
|
BuildRequires: %{python_module wheel}
|
|
BuildRequires: fdupes
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: python-rpm-macros
|
|
BuildRequires: pkgconfig(cfitsio)
|
|
BuildRequires: pkgconfig(healpix_cxx)
|
|
BuildRequires: pkgconfig(libsharp)
|
|
Requires: python-astropy >= 4.0
|
|
Requires: python-numpy >= 1.19
|
|
Requires(post): update-alternatives
|
|
Requires(postun): update-alternatives
|
|
Recommends: python-matplotlib
|
|
Recommends: python-scipy
|
|
# SECTION Additional test requirements
|
|
# Symbol clashes with astropy < 4.0
|
|
BuildRequires: %{python_module astropy >= 4.0}
|
|
BuildRequires: %{python_module matplotlib}
|
|
BuildRequires: %{python_module pytest}
|
|
BuildRequires: %{python_module requests}
|
|
BuildRequires: %{python_module scipy}
|
|
# /SECTION
|
|
%python_subpackages
|
|
|
|
%description
|
|
healpy is a Python package to handle pixelated data on the sphere. It is based
|
|
on the Hierarchical Equal Area isoLatitude Pixelization (HEALPix) scheme and
|
|
bundles the HEALPix C++ library.
|
|
|
|
healpy provides utilities to:
|
|
* convert between sky coordinates and pixel indices in HEALPix nested and ring schemes
|
|
* find pixels within a disk, a polygon or a strip in the sky
|
|
* apply coordinate transformations between Galactic, Ecliptic and Equatorial reference frames
|
|
* apply custom rotations either to vectors or full maps
|
|
* read and write HEALPix maps to disk in FITS format
|
|
* upgrade and downgrade the resolution of existing HEALPix maps
|
|
* visualize maps in Mollweide, Gnomonic and Cartographic projections
|
|
* transform maps to Spherical Harmonics space and back using multi-threaded C++ routines
|
|
* compute Auto and Cross Power Spectra from maps and create map realizations from spectra
|
|
|
|
%prep
|
|
%autosetup -p1 -n healpy-%{version}
|
|
chmod -x lib/healpy/data/*.dat
|
|
|
|
%build
|
|
export CFLAGS="%{optflags}"
|
|
%pyproject_wheel
|
|
|
|
%install
|
|
%pyproject_install
|
|
%python_clone -a %{buildroot}%{_bindir}/healpy_get_wmap_maps.sh
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
|
|
%check
|
|
export PYTEST_DEBUG_TEMPROOT=$(mktemp -d -p ./)
|
|
# Skip tests requiring network access
|
|
donttest="test_astropy_download_file or test_rotate_map_polarization or test_pixelweights_local_datapath"
|
|
# Upstream is investigating: gh#healpy/healpy#987
|
|
donttest="$donttest or test_map2alm_lsq"
|
|
%pytest_arch test -k "not ($donttest)"
|
|
|
|
%post
|
|
%python_install_alternative healpy_get_wmap_maps.sh
|
|
|
|
%postun
|
|
%python_uninstall_alternative healpy_get_wmap_maps.sh
|
|
|
|
%files %{python_files}
|
|
%doc CHANGELOG.rst README.rst
|
|
%license COPYING
|
|
%python_alternative %{_bindir}/healpy_get_wmap_maps.sh
|
|
%{python_sitearch}/healpy/
|
|
%{python_sitearch}/healpy-%{version}.dist-info/
|
|
|
|
%changelog
|