summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Meyers <meyersbs@users.noreply.github.com>2022-11-28 16:46:10 -0500
committerGitHub <noreply@github.com>2022-11-28 15:46:10 -0600
commita97312535a66f5a66828021b49c94c2e78b66e98 (patch)
tree72fcf8b75b17dc6a99a0a05b4b9fe7dec84c9920
parenta0180ef7418275535c474fc81e98331274bf497b (diff)
downloadspack-a97312535a66f5a66828021b49c94c2e78b66e98.tar.gz
spack-a97312535a66f5a66828021b49c94c2e78b66e98.tar.bz2
spack-a97312535a66f5a66828021b49c94c2e78b66e98.tar.xz
spack-a97312535a66f5a66828021b49c94c2e78b66e98.zip
New package: py-statmorph (#34158)
* New package py-statmorph w/ dependecies. Add py-astropy@5.1 * [@spackbot] updating style on behalf of meyersbs * [py-statmorph,py-astropy,py-pyerfa] minor fixes
-rw-r--r--var/spack/repos/builtin/packages/py-astropy/package.py12
-rw-r--r--var/spack/repos/builtin/packages/py-photutils/package.py30
-rw-r--r--var/spack/repos/builtin/packages/py-pyerfa/package.py32
-rw-r--r--var/spack/repos/builtin/packages/py-statmorph/package.py27
4 files changed, 100 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/py-astropy/package.py b/var/spack/repos/builtin/packages/py-astropy/package.py
index 28ff19a235..7f7281a129 100644
--- a/var/spack/repos/builtin/packages/py-astropy/package.py
+++ b/var/spack/repos/builtin/packages/py-astropy/package.py
@@ -16,6 +16,7 @@ class PyAstropy(PythonPackage):
homepage = "https://astropy.org/"
pypi = "astropy/astropy-4.0.1.post1.tar.gz"
+ version("5.1", sha256="1db1b2c7eddfc773ca66fa33bd07b25d5b9c3b5eee2b934e0ca277fa5b1b7b7e")
version(
"4.0.1.post1", sha256="5c304a6c1845ca426e7bc319412b0363fccb4928cb4ba59298acd1918eec44b5"
)
@@ -27,6 +28,7 @@ class PyAstropy(PythonPackage):
variant("extras", default=False, description="Enable extra functionality")
# Required dependencies
+ depends_on("python@3.8:", when="@5.1:", type=("build", "run"))
depends_on("python@3.6:", when="@4.0:", type=("build", "run"))
depends_on("python@3.5:", when="@3.0:", type=("build", "run"))
depends_on("python@2.7:2.8,3.4:", when="@2.0:", type=("build", "run"))
@@ -34,12 +36,19 @@ class PyAstropy(PythonPackage):
depends_on("python@2.6:", type=("build", "run"))
depends_on("py-setuptools", type="build")
depends_on("py-cython@0.29.13:", type="build")
+ depends_on("py-numpy@1.18:", when="@5.1:", type=("build", "run"))
depends_on("py-numpy@1.16:", when="@4.0:", type=("build", "run"))
depends_on("py-numpy@1.13:", when="@3.1:", type=("build", "run"))
depends_on("py-numpy@1.10:", when="@3.0:", type=("build", "run"))
depends_on("py-numpy@1.9:", when="@2.0:", type=("build", "run"))
depends_on("py-numpy@1.7:", when="@1.2:", type=("build", "run"))
depends_on("py-numpy", type=("build", "run"))
+ depends_on("py-packaging@19.0:", when="@5.1:", type=("build", "run"))
+ depends_on("py-pyyaml@3.13:", when="@5.1:", type=("build", "run"))
+ depends_on("py-pyerfa@2.0:", when="@5.1:", type=("build", "run"))
+ depends_on("py-setuptools-scm@6.2:", when="@5.1:", type="build")
+ depends_on("py-cython@0.29.30", when="@5.1:", type="build")
+ depends_on("py-extension-helpers", when="@5.1:", type="build")
depends_on("pkgconfig", type="build")
# Optional dependencies
@@ -72,7 +81,8 @@ class PyAstropy(PythonPackage):
# avoids issues with PyCode_New() in newer
# versions of python in the distributed
# cython-ized files
- os.remove("astropy/cython_version.py")
+ if os.path.exists("astropy/cython_version.py"):
+ os.remove("astropy/cython_version.py")
def install_options(self, spec, prefix):
args = [
diff --git a/var/spack/repos/builtin/packages/py-photutils/package.py b/var/spack/repos/builtin/packages/py-photutils/package.py
new file mode 100644
index 0000000000..de8e567d80
--- /dev/null
+++ b/var/spack/repos/builtin/packages/py-photutils/package.py
@@ -0,0 +1,30 @@
+# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack.package import *
+
+
+class PyPhotutils(PythonPackage):
+ """
+ Photutils is an Astropy package for detection and photometry of astronomical
+ sources.
+ """
+
+ homepage = "https://github.com/astropy/photutils"
+ pypi = "photutils/photutils-1.5.0.tar.gz"
+
+ version("1.5.0", sha256="014f7aa5a571401094d5cf9ffb57803b48869233feb80476ce377ecb91113689")
+
+ maintainers = ["meyersbs"]
+
+ # From setup.cfg
+ depends_on("python@3.8:", type=("build", "run"))
+ depends_on("py-numpy@1.18:", type=("build", "run"))
+ depends_on("py-astropy@5.0:", type=("build", "run"))
+ # From pyproject.toml
+ depends_on("py-setuptools", type="build")
+ depends_on("py-setuptools-scm", type="build")
+ depends_on("py-cython@0.29.22:", type="build")
+ depends_on("py-extension-helpers", type="build")
diff --git a/var/spack/repos/builtin/packages/py-pyerfa/package.py b/var/spack/repos/builtin/packages/py-pyerfa/package.py
new file mode 100644
index 0000000000..eb1a1ad23d
--- /dev/null
+++ b/var/spack/repos/builtin/packages/py-pyerfa/package.py
@@ -0,0 +1,32 @@
+# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack.package import *
+
+
+class PyPyerfa(PythonPackage):
+ """
+ PyERFA is the Python wrapper for the ERFA library (Essential Routines for
+ Fundamental Astronomy), a C library containing key algorithms for astronomy,
+ which is based on the SOFA library published by the International Astronomical
+ Union (IAU). All C routines are wrapped as Numpy universal functions, so that
+ they can be called with scalar or array inputs.
+ """
+
+ homepage = "https://github.com/liberfa/pyerfa"
+ pypi = "pyerfa/pyerfa-2.0.0.1.tar.gz"
+
+ maintainers = ["meyersbs"]
+
+ version("2.0.0.1", sha256="2fd4637ffe2c1e6ede7482c13f583ba7c73119d78bef90175448ce506a0ede30")
+
+ # From setup.cfg
+ depends_on("python@3.7:", type=("build", "run"))
+ depends_on("py-numpy@1.17:", type=("build", "run"))
+ depends_on("py-setuptools-scm@3.4:+toml", type="build")
+ # From pyproject.toml
+ depends_on("py-setuptools@42:", type="build")
+ depends_on("py-packaging", type="build")
+ depends_on("py-jinja2@2.10.3:", type="build")
diff --git a/var/spack/repos/builtin/packages/py-statmorph/package.py b/var/spack/repos/builtin/packages/py-statmorph/package.py
new file mode 100644
index 0000000000..bc093b2a1b
--- /dev/null
+++ b/var/spack/repos/builtin/packages/py-statmorph/package.py
@@ -0,0 +1,27 @@
+# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack.package import *
+
+
+class PyStatmorph(PythonPackage):
+ """
+ Python code for calculating non-parametric morphological diagnostics of galaxy
+ images.
+ """
+
+ homepage = "https://github.com/vrodgom/statmorph"
+ pypi = "statmorph/statmorph-0.4.0.tar.gz"
+
+ maintainers = ["meyersbs"]
+
+ version("0.4.0", sha256="7d1bb802baf3e203ac44c630a58c5049da5eb4d85091ac35e3f5c6ee4af8b05a")
+
+ depends_on("py-setuptools", type="build")
+ depends_on("py-numpy@1.14.0:", type=("build", "run"))
+ depends_on("py-scipy@0.19:", type=("build", "run"))
+ depends_on("py-scikit-image@0.14:", type=("build", "run"))
+ depends_on("py-astropy@2.0:", type=("build", "run"))
+ depends_on("py-photutils@0.7:", type=("build", "run"))