diff options
Diffstat (limited to 'gnu/packages/astronomy.scm')
-rw-r--r-- | gnu/packages/astronomy.scm | 301 |
1 files changed, 269 insertions, 32 deletions
diff --git a/gnu/packages/astronomy.scm b/gnu/packages/astronomy.scm index 2f08b656c0..46839c802f 100644 --- a/gnu/packages/astronomy.scm +++ b/gnu/packages/astronomy.scm @@ -37,6 +37,7 @@ #:use-module (gnu packages compression) #:use-module (gnu packages curl) #:use-module (gnu packages databases) + #:use-module (gnu packages documentation) #:use-module (gnu packages flex) #:use-module (gnu packages fontutils) #:use-module (gnu packages gcc) @@ -44,6 +45,9 @@ #:use-module (gnu packages gl) #:use-module (gnu packages glib) #:use-module (gnu packages gnome) + #:use-module (gnu packages gps) + #:use-module (gnu packages graph) + #:use-module (gnu packages graphviz) #:use-module (gnu packages gtk) #:use-module (gnu packages image) #:use-module (gnu packages image-processing) @@ -51,6 +55,7 @@ #:use-module (gnu packages libusb) #:use-module (gnu packages lua) #:use-module (gnu packages maths) + #:use-module (gnu packages multiprecision) #:use-module (gnu packages ncurses) #:use-module (gnu packages netpbm) #:use-module (gnu packages perl) @@ -70,6 +75,7 @@ #:use-module (gnu packages sphinx) #:use-module (gnu packages textutils) #:use-module (gnu packages time) + #:use-module (gnu packages tls) #:use-module (gnu packages version-control) #:use-module (gnu packages video) #:use-module (gnu packages wxwidgets) @@ -205,6 +211,63 @@ moment, supported SPICE files are: @end itemize\n") (license license:cecill))) +(define-public calcmysky + (package + (name "calcmysky") + (version "0.2.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/10110111/CalcMySky") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0bib5shy8wzc7j5ph218dl9hqrqip491mn25gakyghbvaqxgm27d")))) + (build-system cmake-build-system) + (arguments + (list #:configure-flags + #~(list "-DQT_VERSION=6" + "-DCMAKE_CXX_FLAGS=-fPIC"))) + (inputs + (list eigen glm qtbase)) + (home-page "https://10110111.github.io/CalcMySky/") + (synopsis "Simulator of light scattering by planetary atmospheres") + (description + "CalcMySky is a software package that simulates scattering of light by the +atmosphere to render daytime and twilight skies (without stars). Its primary +purpose is to enable realistic view of the sky in applications such as +planetaria. Secondary objective is to make it possible to explore atmospheric +effects such as glories, fogbows etc., as well as simulate unusual environments +such as on Mars or an exoplanet orbiting a star with a non-solar spectrum of +radiation. + +This package consists of three parts: + +@itemize +@item @code{calcmysky} utility that does the precomputation of the atmosphere +model to enable rendering. + +@item @code{libShowMySky} library that lets the applications render the +atmosphere model. + +@item @code{ShowMySky} preview GUI that makes it possible to preview the +rendering of the atmosphere model and examine its properties. +@end itemize") + (license license:gpl3+))) + +(define-public calcmysky-qt5 + (package/inherit calcmysky + (name "calcmysky-qt5") + (arguments + (list #:configure-flags + #~(list "-DQT_VERSION=5" + "-DCMAKE_CXX_FLAGS=-fPIC"))) + (inputs + (modify-inputs (package-inputs calcmysky) + (replace "qtbase" qtbase-5))) + (synopsis "Qt5 build for the CalcMySky library."))) + (define-public aoflagger (package (name "aoflagger") @@ -346,7 +409,7 @@ wide set of telescopes.") python python-numpy wcslib)) - (home-page "http://casacore.github.io/casacore/") + (home-page "https://casacore.github.io/casacore/") (synopsis "Suite of C++ libraries for radio astronomy data processing") (description "The casacore package contains the core libraries of the old @@ -650,7 +713,7 @@ programs for the manipulation and analysis of astronomical data.") (inputs `(("openblas" ,openblas) ("fftw" ,fftwf))) - (home-page "http://www.astromatic.net/software/sextractor") + (home-page "https://www.astromatic.net/software/sextractor") (synopsis "Extract catalogs of sources from astronomical images") (description "SExtractor is a program that builds a catalogue of objects from an @@ -699,7 +762,7 @@ image formats.") (define-public splash (package (name "splash") - (version "3.5.1") + (version "3.7.2") (source (origin (method git-fetch) (uri (git-reference @@ -707,7 +770,7 @@ image formats.") (commit (string-append "v" version)))) (sha256 (base32 - "12s3w96wzd4zpxw4adzhalkr57fgdk7cjp6bj596jnd87pz3rhyd")) + "0nsm6rk0bi99xz7wclk0zy4bpqf0qcsdln5cdjb30lhpf37i2fpa")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (arguments @@ -835,45 +898,65 @@ deconvolution). Such post-processing is not performed by Stackistry.") (define-public stellarium (package (name "stellarium") - (version "0.21.1") + (version "1.2") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/Stellarium/stellarium" - "/releases/download/v" version - "/stellarium-" version ".tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/Stellarium/stellarium") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) (sha256 - (base32 "049jlc8vx06pad5h2syrmf7f1l346yr5iraai0wkn8s8pk30j8q7")))) + (base32 "1655lz848k7m4vqs7n3vxjwn5n4pkykwl6x7nbanqcqzlixm5xnk")))) (build-system cmake-build-system) + ;; TODO: Complete documentation build and split into dedicated outputs. + (arguments + (list + ;; FIXME: Tests keep failing on 100% when preparing test-suit for INDI. + #:tests? #f + #:test-target "test" + #:configure-flags + #~(list "-DENABLE_GPS=1" + ;; TODO: Enable when all of the dependencies are availalbe for Qt6. + "-DENABLE_QT6=0" + "-DENABLE_TESTING=0" + (string-append "-DCMAKE_CXX_FLAGS=-isystem " + #$(this-package-input "qtserialport") "/include/qt5")) + #:phases + #~(modify-phases %standard-phases + (add-before 'check 'set-offscreen-display + (lambda _ + (setenv "QT_QPA_PLATFORM" "offscreen") + (setenv "HOME" "/tmp")))))) (inputs - (list qtbase-5 + (list calcmysky-qt5 + gpsd + indi + libnova + openssl + qtbase-5 + qtcharts qtlocation qtmultimedia-5 + qtpositioning qtscript qtserialport + qttranslations + qtwebengine-5 + qxlsx-qt5 zlib)) (native-inputs - `(("gettext" ,gettext-minimal) ; xgettext is used at compile time - ("perl" ,perl) ; for pod2man - ("qtbase" ,qtbase-5) ; Qt MOC is needed at compile time - ("qttools-5" ,qttools-5))) - (arguments - `(#:test-target "test" - #:configure-flags (list "-DENABLE_TESTING=1" - (string-append - "-DCMAKE_CXX_FLAGS=-isystem " - (assoc-ref %build-inputs "qtserialport") - "/include/qt5")) - #:phases (modify-phases %standard-phases - (add-before 'check 'set-offscreen-display - (lambda _ - ;; Make Qt render "offscreen", required for tests. - (setenv "QT_QPA_PLATFORM" "offscreen") - (setenv "HOME" "/tmp") - #t))))) + (list doxygen + gettext-minimal + graphviz + mesa + perl + python-wrapper + qttools-5)) (home-page "https://stellarium.org/") (synopsis "3D sky viewer") - (description "Stellarium is a planetarium. It shows a realistic sky in + (description + "Stellarium is a planetarium. It shows a realistic sky in 3D, just like what you see with the naked eye, binoculars, or a telescope. It can be used to control telescopes over a serial port for tracking celestial objects.") @@ -1199,6 +1282,37 @@ attempting to maintain ISTP compliance @end itemize") (license license:expat))) +(define-public python-czml3 + (package + (name "python-czml3") + (version "0.7.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/poliastro/czml3") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0pbwcsmc9nw591rck586ca9hwwhmm54rjjmp8gflhzq8b7f48lkc")))) + (build-system pyproject-build-system) + (propagated-inputs + (list python-attrs + python-dateutil + python-w3lib)) + (native-inputs + (list python-astropy + python-pytest + python-pytest-cov + python-pytest-mypy)) + (home-page "https://github.com/poliastro/czml3") + (synopsis "Python library to write CZML") + (description + "CZML3 is a Python library to write CZML, a JSON format for describing +a time-dynamic graphical scene, primarily for display in a web browser running +Cesium.") + (license license:expat))) + (define-public python-drms (package (name "python-drms") @@ -1340,6 +1454,81 @@ the easy construction of interactive matplotlib widget based animations.") of astronomical sources.") (license license:bsd-3))) +(define-public python-poliastro + (package + (name "python-poliastro") + (version "0.17.0") + (source + (origin + ;; PyPi tarball lacks tests. + (method git-fetch) + (uri (git-reference + (url "https://github.com/poliastro/poliastro") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1iclyjp0cvm6hp5qf4fzklszxvhj3idkxgb6a9h7xzg9bf5j5gi2")))) + (build-system pyproject-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; NOTE: Tests take about 7-10 minutes to pass. + (add-before 'check 'prepare-test-environment + (lambda _ + (setenv "HOME" "/tmp") + ;; TODO: Review failing tests later when any upstream + ;; suggestions are provided: + ;; https://github.com/poliastro/poliastro/issues/1618 + (substitute* "tests/test_czml.py" + (("def test_czml_add_trajectory") "def __off_test_czml_add_trajectory") + (("def test_czml_custom_packet") "def __off_test_czml_custom_packet") + (("def test_czml_ground_station") "def __off_test_czml_ground_station") + (("def test_czml_groundtrack") "def __off_test_czml_groundtrack") + (("def test_czml_preamble") "def __off_test_czml_preamble")))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "pytest" + ;; Skip tests that need remote data. + "-m" "not remote_data"))))))) + (native-inputs + (list python-coverage + python-hypothesis + python-mypy + python-flit-core + python-pytest + python-pytest-cov + python-pytest-doctestplus + python-pytest-mpl + python-pytest-mypy)) + (propagated-inputs + (list python-astropy + python-astroquery + python-czml3 + python-jplephem + python-matplotlib + python-numba + python-numpy + python-pandas + python-plotly + python-pyerfa + python-scipy)) + (home-page "https://www.poliastro.space/") + (synopsis "Astrodynamics in Python") + (description + "POLIASTRO is a Python library for interactive Astrodynamics and Orbital +Mechanics, with a focus on ease of use, speed, and quick visualization. It +provides a simple and intuitive API, and handles physical quantities with +units. + +Some features include orbit propagation, solution of the Lambert's problem, +conversion between position and velocity vectors and classical orbital +elements and orbit plotting, among others. It focuses on interplanetary +applications, but can also be used to analyze artificial satellites in +Low-Earth Orbit (LEO).") + (license license:expat))) + (define-public python-poppy (package (name "python-poppy") @@ -1655,6 +1844,54 @@ positions of the sun: dawn, sunrise, solar noon, sunset, dusk, solar elevation, solar azimuth, rahukaalam, and the phases of the moon.") (license license:asl2.0))) +(define-public python-spherical-geometry + (package + (name "python-spherical-geometry") + (version "1.2.22") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/spacetelescope/spherical_geometry") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0kzcncqir4v7nhk9lxj9gxr32p3krkaqa58y2i4kksgxxy24qw4z")))) + (build-system python-build-system) + (arguments + (list + ;; NOTE: (Sharlatan-20220523T231348+0100): Tests depends on old Python2 + ;; libarry `sphere' + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'preparations + (lambda _ + ;; Fixing: setuptools-scm was unable to detect version for ... + (substitute* "setup.py" + (("use_scm_version=True") + (format #f "version=~s" #$version)) + (("setup_requires=\\['setuptools_scm'\\],.*") + "")) + ;; Use our own libraries in place of bundles. + (setenv "USE_SYSTEM_QD" "1")))))) + (native-inputs + (list python-pytest + python-setuptools-scm)) + (inputs + (list qd)) + (propagated-inputs + (list python-astropy + python-numpy)) + (home-page "https://github.com/spacetelescope/tweakwcs") + (synopsis "Python astronimical package for handling spherical polygons") + (description + "The @code{spherical_geometry} library is a Python package for handling +spherical polygons that represent arbitrary regions of the sky.") + ;; LICENSE.rst Association of Universities for Research in Astronomy (AURA) + ;; QD_LIBRARY_LICENSE.rst for bandeled QD source + (license license:bsd-3))) + (define-public libnova (package (name "libnova") @@ -1683,7 +1920,7 @@ elevation, solar azimuth, rahukaalam, and the phases of the moon.") (synopsis "Celestial mechanics, astrometry and astrodynamics library") (description "Libnova is a general purpose, double precision, Celestial Mechanics, Astrometry and Astrodynamics library.") - (home-page "http://libnova.sourceforge.net/") + (home-page "https://libnova.sourceforge.net/") (license (list license:lgpl2.0+ license:gpl2+)))) ; examples/transforms.c & lntest/*.c @@ -1889,7 +2126,7 @@ on FITS files: (string-append "CPPFLAGS=-I" netpbm "/include/netpbm") ;; no nasa jpl cspice support "--without-cspice" ))))) - (home-page "http://xplanet.sourceforge.net/") + (home-page "https://xplanet.sourceforge.net/") (synopsis "Planetary body renderer") (description "Xplanet renders an image of a planet into an X window or file. |