Hi Guix team!
This is the last set of patches which adding with SunPy - solar data analysis
environment for Python.
python-opencv is required for tests only which are silent right now, package
is not presented Guix yet and require a more attention due to complexity.
Build was tested only on x86_64 hardware.
> ./pre-inst-env guix build python-drms python-mpl-animators python-hvpy python-reproject python-sunpy --rounds=2
> /gnu/store/a4afv7qc124szmfn6z08m1c66m3gpv6m-python-sunpy-4.0.6
> /gnu/store/brx97jn7k5iixqpgvkbgl4i3kzyvkm3f-python-reproject-0.9.1
> /gnu/store/f6zbxpvglgq9kj16js2pkw3iy6mmv37m-python-hvpy-1.0.1
> /gnu/store/i143f9pijxs01v280cq6hr1132nafdza-python-mpl-animators-1.1.0
> /gnu/store/f2072k95gjjjfrhjk2rzk158hlp6bdv4-python-drms-0.6.3
Sharlatan Hellseher (5):
gnu: Add python-drms.
gnu: Add python-mpl-animators.
gnu: Add python-hvpy.
gnu: Add python-reproject.
gnu: Add python-sunpy.
gnu/packages/astronomy.scm | 225 +++++++++++++++++++++++++++++++++++++
1 file changed, 225 insertions(+)
base-commit: 22d44f87763f86a05e9679d9ad2c99e17f4c79be
--
2.38.0
* gnu/packages/astronomy.scm (python-drms): New variable. --- gnu/packages/astronomy.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index d450d1dd94..4ae2e1caa2 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1142,6 +1142,43 @@ (define-public python-cdflib @end itemize") (license license:expat))) +(define-public python-drms + (package + (name "python-drms") + (version "0.6.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "drms" version)) + (sha256 + (base32 "1b0w350y4wbgyy19zcf28xbb85mqq6gnhb6ppibbc4hbn2ixbcvj")))) + (build-system python-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (replace 'check + (lambda* (#:key inputs outputs tests? + #:allow-other-keys) + (when tests? + (add-installed-pythonpath inputs outputs) + (setenv "JSOC_EMAIL" "jsoc@sunpy.org") + (invoke "python" "-m" "pytest" "-vv"))))))) + (native-inputs + (list python-astropy + python-pytest-astropy + python-pytest + python-setuptools-scm)) + (propagated-inputs (list python-numpy python-pandas)) + (home-page "https://sunpy.org") + (synopsis "Access astronomical HMI, AIA and MDI data with Python") + (description + "DRMS module provides an easy-to-use interface for accessing HMI, AIA and MDI +data with Python. It uses the publicly accessible +JSOC (@url{http://jsoc.stanford.edu/}) DRMS server by default, but can also be +used with local NetDRMS sites.") + (license license:bsd-2))) + (define-public python-ephem (package (name "python-ephem") -- 2.38.0
* gnu/packages/astronomy.scm (python-mpl-animators): New variable. --- gnu/packages/astronomy.scm | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 4ae2e1caa2..81a051b537 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1202,6 +1202,32 @@ (define-public python-ephem of dates.") (license license:expat))) +(define-public python-mpl-animators + (package + (name "python-mpl-animators") + (version "1.1.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "mpl_animators" version)) + (sha256 + (base32 "12kjmj7rn3pk9ly82h5s5hn0kl3kxkr7bgkz9zr9k59pir8z1r8b")))) + (build-system pyproject-build-system) + (native-inputs + (list python-pytest + python-pytest-mpl + python-setuptools-scm)) + (propagated-inputs + (list python-astropy + python-matplotlib + python-numpy)) + (home-page "https://sunpy.org") + (synopsis "Interactive animations with matplotlib") + (description + "The @code{mpl_animators} package provides a set of classes which allow the +easy construction of interactive matplotlib widget based animations.") + (license license:bsd-3))) + (define-public python-photutils (package (name "python-photutils") -- 2.38.0
* gnu/packages/astronomy.scm (python-hvpy): New variable. --- gnu/packages/astronomy.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 81a051b537..eb3b1f01b9 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1202,6 +1202,27 @@ (define-public python-ephem of dates.") (license license:expat))) +(define-public python-hvpy + (package + (name "python-hvpy") + (version "1.0.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "hvpy" version)) + (sha256 + (base32 "0r0asyflz2sw9zn5vgs138nh81m0rbwbakmrncbc1ghdr3g6jahv")))) + (build-system pyproject-build-system) + (arguments + (list #:tests? #f)) ; Requires HTTP(S) access to api.beta.helioviewer.org + (propagated-inputs (list python-pydantic python-requests)) + (native-inputs (list python-pytest python-pytest-astropy)) + (home-page "https://helioviewer.org/") + (synopsis "Helioviewer Python API Wrapper") + (description "@code{hvpy} is a Python API wrapper around the formal @url{Helioviewer API, +https://api.helioviewer.org/docs/v2/}.") + (license license:bsd-2))) + (define-public python-mpl-animators (package (name "python-mpl-animators") -- 2.38.0
* gnu/packages/astronomy.scm (python-reproject): New variable. --- gnu/packages/astronomy.scm | 56 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index eb3b1f01b9..26d036a0be 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -1355,6 +1355,62 @@ (define-public python-regions (description "Regions is an Astropy package for region handling.") (license license:bsd-3))) +(define-public python-reproject + (package + (name "python-reproject") + (version "0.9.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "reproject" version)) + (sha256 + (base32 "1msysqbhkfi3bmw29wipk250a008bnng7din56md9ipbwiar8x55")))) + (build-system pyproject-build-system) + (arguments + (list + ;; FIXME: Failing tests + ;; + ;; reproject/adaptive/core.py:7: in <module> + ;; from .deforest import map_coordinates + ;; E ModuleNotFoundError: No module named 'reproject.adaptive.deforest' + ;; + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-before 'install 'writable-compiler + (lambda _ + (make-file-writable "reproject/_compiler.c"))) + (add-before 'check 'writable-compiler + (lambda _ + (make-file-writable "reproject/_compiler.c"))) + (add-before 'check 'writable-home + (lambda _ + (setenv "HOME" (getcwd))))))) + (propagated-inputs + (list python-astropy + python-astropy-healpix + python-numpy + python-pytest + python-scipy)) + (native-inputs + (list python-asdf + python-cython + python-extension-helpers + python-gwcs + python-pytest-astropy + python-pyvo + python-semantic-version + python-setuptools-scm + python-shapely)) + (home-page "https://reproject.readthedocs.io") + (synopsis "Astronomical image reprojection in Python") + (description + "This package provides a functionality to reproject astronomical images using +various techniques via a uniform interface, where reprojection is the +re-gridding of images from one world coordinate system to another e.g. +changing the pixel resolution, orientation, coordinate system.") + (license license:bsd-3))) + (define-public python-astral (package (name "python-astral") -- 2.38.0
* gnu/packages/astronomy.scm (python-sunpy): New variable. --- gnu/packages/astronomy.scm | 85 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 26d036a0be..dbe5b4c943 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -36,6 +36,7 @@ (define-module (gnu packages astronomy) #:use-module (gnu packages cmake) #:use-module (gnu packages compression) #:use-module (gnu packages curl) + #:use-module (gnu packages databases) #:use-module (gnu packages flex) #:use-module (gnu packages fontutils) #:use-module (gnu packages gcc) @@ -1411,6 +1412,90 @@ (define-public python-reproject changing the pixel resolution, orientation, coordinate system.") (license license:bsd-3))) +(define-public python-sunpy + (package + (name "python-sunpy") + (version "4.0.6") + (source + (origin + (method url-fetch) + (uri (pypi-uri "sunpy" version)) + (sha256 + (base32 "0aiirb6l8zshdrpsvh6d5ki759ah9zfm9gbl0in985hprwwxyrq1")))) + (build-system pyproject-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'install 'writable-compiler + (lambda _ + (make-file-writable "sunpy/_compiler.c"))) + (add-before 'check 'prepare-test-environment + (lambda _ + (setenv "HOME" "/tmp") + (make-file-writable "sunpy/_compiler.c") + ;; TODO: (Sharlatan-20221106T115800+0000): Review failing tests + (substitute* "sunpy/image/tests/test_transform.py" + (("def test_clipping") "def __off_test_clipping") + (("def test_nans") "def __off_test_nans") + (("def test_endian") "def __off_test_endian")) + (substitute* "sunpy/map/tests/test_mapbase.py" + (("def test_derotating_nonpurerotation_pcij") + "def __off_test_derotating_nonpurerotation_pcij")) + (substitute* "sunpy/map/sources/tests/test_mdi_source.py" + (("def test_synoptic_source") + "def __off_test_synoptic_source")) + (substitute* "sunpy/tests/tests/test_self_test.py" + (("def test_main_nonexisting_module") + "def __off_test_main_nonexisting_module") + (("def test_main_stdlib_module") + "def __off_test_main_stdlib_module"))))))) + (native-inputs + (list python-aiohttp + python-extension-helpers + python-hvpy + python-packaging + python-pytest + python-pytest-astropy + python-pytest-doctestplus + python-pytest-mock + python-pytest-mpl + python-pytest-xdist + python-setuptools-scm)) + (propagated-inputs + (list parfive + python-asdf + python-asdf-astropy + python-astropy + python-beautifulsoup4 + python-cdflib + python-dask + python-dateutil + python-drms + python-glymur + python-h5netcdf + python-h5py + python-hypothesis + python-jplephem + python-matplotlib + python-mpl-animators + python-numpy + ;; python-opencv-python ; not packed yet + python-pandas + python-reproject + python-scikit-image + python-scipy + python-semantic-version + python-sqlalchemy + python-tqdm + python-zeep)) + (home-page "https://sunpy.org") + (synopsis "Python library for Solar Physics") + (description + "SunPy is package for solar physics and is meant to be a free alternative to the +SolarSoft data analysis environment.") + (license license:bsd-2))) + (define-public python-astral (package (name "python-astral") -- 2.38.0
[-- Attachment #1: Type: text/plain, Size: 1238 bytes --] Sharlatan Hellseher <sharlatanus@gmail.com> writes: > Hi Guix team! > > This is the last set of patches which adding with SunPy - solar data analysis > environment for Python. > > python-opencv is required for tests only which are silent right now, package > is not presented Guix yet and require a more attention due to complexity. > > Build was tested only on x86_64 hardware. > >> ./pre-inst-env guix build python-drms python-mpl-animators python-hvpy python-reproject python-sunpy --rounds=2 >> /gnu/store/a4afv7qc124szmfn6z08m1c66m3gpv6m-python-sunpy-4.0.6 >> /gnu/store/brx97jn7k5iixqpgvkbgl4i3kzyvkm3f-python-reproject-0.9.1 >> /gnu/store/f6zbxpvglgq9kj16js2pkw3iy6mmv37m-python-hvpy-1.0.1 >> /gnu/store/i143f9pijxs01v280cq6hr1132nafdza-python-mpl-animators-1.1.0 >> /gnu/store/f2072k95gjjjfrhjk2rzk158hlp6bdv4-python-drms-0.6.3 > > Sharlatan Hellseher (5): > gnu: Add python-drms. > gnu: Add python-mpl-animators. > gnu: Add python-hvpy. > gnu: Add python-reproject. > gnu: Add python-sunpy. > > gnu/packages/astronomy.scm | 225 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 225 insertions(+) Thanks! I fixed a couple lint warnings and pushed to master as 78ee6dcfe13c1561ff1d5cdfc2c2d4fa8afe0883. Chris [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 987 bytes --]