diff options
author | afzpatel <122491982+afzpatel@users.noreply.github.com> | 2024-09-24 14:21:15 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-24 12:21:15 -0600 |
commit | 3b61a1f7784b2d4ef35cb139733a5c7a9d166b58 (patch) | |
tree | 3196015875bae703f41483127056e3acb4b7780e /var | |
parent | 3771278d5070c8b921686445f2256a2ee9f2cfe9 (diff) | |
download | spack-3b61a1f7784b2d4ef35cb139733a5c7a9d166b58.tar.gz spack-3b61a1f7784b2d4ef35cb139733a5c7a9d166b58.tar.bz2 spack-3b61a1f7784b2d4ef35cb139733a5c7a9d166b58.tar.xz spack-3b61a1f7784b2d4ef35cb139733a5c7a9d166b58.zip |
omniperf: New package (with deps) (#46239)
Co-authored-by: Bernhard Kaindl <bernhard.kaindl@cloud.com>
Diffstat (limited to 'var')
10 files changed, 294 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/omniperf/0001-remove-VERSION.sha-install.patch b/var/spack/repos/builtin/packages/omniperf/0001-remove-VERSION.sha-install.patch new file mode 100644 index 0000000000..779dfa6763 --- /dev/null +++ b/var/spack/repos/builtin/packages/omniperf/0001-remove-VERSION.sha-install.patch @@ -0,0 +1,24 @@ +From 0672d33d7c449fe75b0be5d476d1151b26e39b99 Mon Sep 17 00:00:00 2001 +From: Afzal Patel <Afzal.Patel@amd.com> +Date: Thu, 5 Sep 2024 14:29:36 +0000 +Subject: [PATCH] Remove install for VERSION.sha + +--- + CMakeLists.txt | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 05aac32..9cf588a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -278,7 +278,6 @@ install( + # support files and version info + install( + FILES src/argparser.py src/config.py src/omniperf_base.py src/roofline.py VERSION +- VERSION.sha + DESTINATION ${CMAKE_INSTALL_LIBEXECDIR}/${PROJECT_NAME} + COMPONENT main) + # src/omniperf_analyze +-- +2.43.5 + diff --git a/var/spack/repos/builtin/packages/omniperf/package.py b/var/spack/repos/builtin/packages/omniperf/package.py new file mode 100644 index 0000000000..11bf676c2b --- /dev/null +++ b/var/spack/repos/builtin/packages/omniperf/package.py @@ -0,0 +1,49 @@ +# Copyright 2013-2024 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 Omniperf(CMakePackage): + """Advanced Profiling and Analytics for AMD Hardware""" + + homepage = "https://github.com/ROCm/omniperf" + git = "https://github.com/ROCm/omniperf.git" + url = "https://github.com/ROCm/omniperf/archive/refs/tags/rocm-6.2.1.tar.gz" + + tags = ["rocm"] + + maintainers("afzpatel", "srekolam", "renjithravindrankannath") + + license("MIT") + + version("6.2.1", sha256="c14cb73b9fe17a3cca31489a73e8ea49cb278093f8d64c433b1bac387445074a") + + depends_on("python@3.8:") + depends_on("py-pip", type="run") + depends_on("py-astunparse@1.6.2", type=("build", "run")) # wants exact version + depends_on("py-colorlover", type=("build", "run")) + depends_on("py-pyyaml") + depends_on("py-matplotlib") + depends_on("py-pandas") + depends_on("py-pymongo") + depends_on("py-tabulate") + depends_on("py-tqdm") + depends_on("py-kaleido") + depends_on("py-plotille") + depends_on("py-dash-svg", type=("build", "run")) + depends_on("py-dash", type=("build", "run")) + depends_on("py-dash-bootstrap-components", type=("build", "run")) + + # VERSION.sha is not in the auto-generated ROCm release tarball + patch("0001-remove-VERSION.sha-install.patch") + + def cmake_args(self): + args = [self.define("ENABLE_TESTS", self.run_tests)] + return args + + @run_after("install") + def after_install(self): + touch(join_path(self.spec.prefix.libexec.omniperf, "VERSION.sha")) diff --git a/var/spack/repos/builtin/packages/py-contourpy/package.py b/var/spack/repos/builtin/packages/py-contourpy/package.py index 9bd134913f..b51d9b9cbf 100644 --- a/var/spack/repos/builtin/packages/py-contourpy/package.py +++ b/var/spack/repos/builtin/packages/py-contourpy/package.py @@ -18,6 +18,7 @@ class PyContourpy(PythonPackage): version("1.0.7", sha256="d8165a088d31798b59e91117d1f5fc3df8168d8b48c4acc10fc0df0d0bdbcc5e") version("1.0.5", sha256="896631cd40222aef3697e4e51177d14c3709fda49d30983269d584f034acc8a4") + depends_on("py-pybind11", type=("build", "link")) depends_on("cxx", type="build") with default_args(type="build"): diff --git a/var/spack/repos/builtin/packages/py-dash-bootstrap-components/package.py b/var/spack/repos/builtin/packages/py-dash-bootstrap-components/package.py new file mode 100644 index 0000000000..0872af0ee3 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-dash-bootstrap-components/package.py @@ -0,0 +1,22 @@ +# Copyright 2013-2024 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 PyDashBootstrapComponents(PythonPackage): + """Bootstrap themed components for use in Plotly Dash""" + + homepage = "https://dash-bootstrap-components.opensource.faculty.ai/" + pypi = "dash_bootstrap_components/dash_bootstrap_components-1.6.0.tar.gz" + git = "https://github.com/facultyai/dash-bootstrap-components/" + + license("Apache-2.0") + + version("1.6.0", sha256="960a1ec9397574792f49a8241024fa3cecde0f5930c971a3fc81f016cbeb1095") + + depends_on("python@3.8:", type=("build", "run")) + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-dash-svg/package.py b/var/spack/repos/builtin/packages/py-dash-svg/package.py new file mode 100644 index 0000000000..c3e5cd7e8f --- /dev/null +++ b/var/spack/repos/builtin/packages/py-dash-svg/package.py @@ -0,0 +1,19 @@ +# Copyright 2013-2024 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 PyDashSvg(PythonPackage): + """SVG support library for Plotly/Dash""" + + homepage = "https://github.com/stevej2608/dash-svg" + pypi = "dash_svg/dash_svg-0.0.12.tar.gz" + + license("MIT") + + version("0.0.12", sha256="a7115bf437d770b822c2dd53b9d9a981210619b7d17c925cbee04905fc761b4e") + + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-dash/package.py b/var/spack/repos/builtin/packages/py-dash/package.py new file mode 100644 index 0000000000..b68ae73d5b --- /dev/null +++ b/var/spack/repos/builtin/packages/py-dash/package.py @@ -0,0 +1,26 @@ +# Copyright 2013-2024 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 PyDash(PythonPackage): + """Dash is the most downloaded, trusted Python framework + for building ML & data science web apps.""" + + homepage = "https://dash.plotly.com/" + pypi = "dash/dash-2.17.1.tar.gz" + git = "https://github.com/plotly/dash.git" + + license("MIT") + + version("2.17.1", sha256="ee2d9c319de5dcc1314085710b72cd5fa63ff994d913bf72979b7130daeea28e") + + depends_on("python@3.8:", type=("build", "run")) + depends_on("py-setuptools", type="build") + depends_on("py-typing-extensions") + depends_on("py-flask") + depends_on("py-plotly") + depends_on("py-importlib-metadata") diff --git a/var/spack/repos/builtin/packages/py-plotille/package.py b/var/spack/repos/builtin/packages/py-plotille/package.py new file mode 100644 index 0000000000..a232da9a56 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-plotille/package.py @@ -0,0 +1,20 @@ +# Copyright 2013-2024 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 PyPlotille(PythonPackage): + """Plot in the terminal using braille dots.""" + + homepage = "https://github.com/tammoippen/plotille" + pypi = "plotille/plotille-5.0.0.tar.gz" + git = "https://github.com/tammoippen/plotille.git" + + version("5.0.0", sha256="99e5ca51a2e4c922ead3a3b0863cc2c6a9a4b3f701944589df10f42ce02ab3dc") + + license("MIT") + depends_on("python@3.7:", type=("build", "run")) + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/rocal/package.py b/var/spack/repos/builtin/packages/rocal/package.py new file mode 100644 index 0000000000..c086a23cdf --- /dev/null +++ b/var/spack/repos/builtin/packages/rocal/package.py @@ -0,0 +1,44 @@ +# Copyright 2013-2024 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 Rocal(CMakePackage): + """The AMD rocAL is designed to efficiently decode and process images and videos from a variety + of storage formats and modify them through a processing graph programmable by the user.""" + + homepage = "https://github.com/ROCm/rocAL" + url = "https://github.com/ROCm/rocAL/archive/refs/tags/rocm-6.2.0.tar.gz" + + maintainers("afzpatel", "srekolam", "renjithravindrankannath") + + license("MIT") + + version("6.2.0", sha256="c7c265375a40d4478a628258378726c252caac424f974456d488fce43890e157") + + depends_on("mivisionx@6.2.0", when="@6.2.0") + depends_on("llvm-amdgpu@6.2.0", when="@6.2.0") + depends_on("rpp@6.2.0", when="@6.2.0") + depends_on("libjpeg-turbo@2.0.6+partial_decoder") + depends_on("rapidjson") + depends_on("ffmpeg@4.4:") + + def patch(self): + filter_file( + r"${ROCM_PATH}/llvm/bin/clang++", + "{0}/bin/clang++".format(self.spec["llvm-amdgpu"].prefix), + "rocAL/rocAL_hip/CMakeLists.txt", + string=True, + ) + + def cmake_args(self): + args = [ + self.define("AMDRPP_PATH", self.spec["rpp"].prefix), + self.define("TURBO_JPEG_PATH", self.spec["libjpeg-turbo"].prefix), + self.define("MIVisionX_PATH", self.spec["mivisionx"].prefix), + self.define("CMAKE_INSTALL_PREFIX_PYTHON", self.spec.prefix), + ] + return args diff --git a/var/spack/repos/builtin/packages/rocdecode/package.py b/var/spack/repos/builtin/packages/rocdecode/package.py new file mode 100644 index 0000000000..9fe28bbe3c --- /dev/null +++ b/var/spack/repos/builtin/packages/rocdecode/package.py @@ -0,0 +1,43 @@ +# Copyright 2013-2024 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 Rocdecode(CMakePackage): + """rocDecode is a high performance video decode SDK for AMD hardware""" + + homepage = "https://github.com/ROCm/rocDecode" + git = "https://github.com/ROCm/rocDecode.git" + url = "https://github.com/ROCm/rocDecode/archive/refs/tags/rocm-6.2.0.tar.gz" + + tags = ["rocm"] + + maintainers("afzpatel", "srekolam", "renjithravindrankannath") + + license("MIT") + + version("6.2.0", sha256="fe0d7c19a4e65b93405566511880b94f25ef68c830d0088f9458da9baea1d4f9") + version("6.1.2", sha256="67a13aeaa495e06683124de5908e61cf2be3beff79b13d858897344aa809775e") + version("6.1.1", sha256="5914c91e433ec7e8511b8a9017d165a0589c1aff9f5527b413d0b3a32a3cc318") + version("6.1.0", sha256="8316dbde87f1fea782af6216c8d013e866542329a673fb24a668335c6169ef8f") + + amdgpu_targets = ROCmPackage.amdgpu_targets + + variant( + "amdgpu_target", + description="AMD GPU architecture", + values=auto_or_any_combination_of(*amdgpu_targets), + sticky=True, + ) + + for ver in ["6.1.0", "6.1.1", "6.1.2", "6.2.0"]: + depends_on(f"hip@{ver}", when=f"@{ver}") + + def cmake_args(self): + args = [] + if "auto" not in self.spec.variants["amdgpu_target"]: + args.append(self.define_from_variant("AMDGPU_TARGETS", "amdgpu_target")) + return args diff --git a/var/spack/repos/builtin/packages/rocpydecode/package.py b/var/spack/repos/builtin/packages/rocpydecode/package.py new file mode 100644 index 0000000000..3aea38e938 --- /dev/null +++ b/var/spack/repos/builtin/packages/rocpydecode/package.py @@ -0,0 +1,46 @@ +# Copyright 2013-2024 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 Rocpydecode(CMakePackage): + """rocPyDecode is a set of Python bindings to rocDecode C++ library which provides + full HW acceleration for video decoding on AMD GPUs.""" + + homepage = "https://github.com/ROCm/rocPyDecode" + url = "https://github.com/ROCm/rocPyDecode/archive/refs/tags/rocm-6.2.0.tar.gz" + + maintainers("afzpatel", "srekolam", "renjithravindrankannath") + + version("6.2.0", sha256="e465254cd3e96bbb59208e90293d7c6b7744b0fbcd928ef278ec568c83e63ff3") + + depends_on("py-pybind11") + depends_on("ffmpeg@4.4:5") + depends_on("rocdecode@6.2.0", when="@6.2.0") + depends_on("dlpack") + + def patch(self): + filter_file( + r"${ROCM_PATH}/llvm/bin/clang++", + "{0}/bin/clang++".format(self.spec["llvm-amdgpu"].prefix), + "CMakeLists.txt", + string=True, + ) + filter_file( + r"${ROCM_PATH}/share/rocdecode/utils", + "{0}/share/rocdecode/utils".format(self.spec["rocdecode"].prefix), + "CMakeLists.txt", + string=True, + ) + + def cmake_args(self): + args = [ + self.define("rocDecode_PATH", self.spec["rocdecode"].prefix), + self.define("FFMPEG_INCLUDE_DIR", self.spec["ffmpeg"].prefix.include), + self.define("CMAKE_INSTALL_PREFIX_PYTHON", self.spec.prefix), + self.define("CMAKE_CXX_FLAGS", "-I{0}".format(self.spec["dlpack"].prefix.include)), + ] + return args |