diff --git a/var/spack/repos/builtin/packages/py-dacite/package.py b/var/spack/repos/builtin/packages/py-dacite/package.py new file mode 100644 index 00000000000..006b50d95ec --- /dev/null +++ b/var/spack/repos/builtin/packages/py-dacite/package.py @@ -0,0 +1,20 @@ +# Copyright Spack Project Developers. See COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyDacite(PythonPackage): + """Simple creation of data classes from dictionaries.""" + + homepage = "https://github.com/konradhalas/dacite" + pypi = "dacite/dacite-1.8.0.tar.gz" + + license("MIT") + + version("1.8.0", sha256="6257a5e505b61a8cafee7ef3ad08cf32ee9b885718f42395d017e0a9b4c6af65") + + depends_on("python@3.6:") + + depends_on("py-setuptools", type="build") diff --git a/var/spack/repos/builtin/packages/py-datasets/package.py b/var/spack/repos/builtin/packages/py-datasets/package.py index e9104f77823..3b9c6b80176 100644 --- a/var/spack/repos/builtin/packages/py-datasets/package.py +++ b/var/spack/repos/builtin/packages/py-datasets/package.py @@ -17,6 +17,7 @@ class PyDatasets(PythonPackage): license("Apache-2.0") + version("3.2.0", sha256="9a6e1a356052866b5dbdd9c9eedb000bf3fc43d986e3584d9b028f4976937229") version("2.20.0", sha256="3c4dbcd27e0f642b9d41d20ff2efa721a5e04b32b2ca4009e0fc9139e324553f") version("2.8.0", sha256="a843b69593914071f921fc1086fde939f30a63415a34cdda5db3c0acdd58aff2") version("1.8.0", sha256="d57c32bb29e453ee7f3eb0bbca3660ab4dd2d0e4648efcfa987432624cab29d3") @@ -30,7 +31,7 @@ class PyDatasets(PythonPackage): depends_on("py-pandas") depends_on("py-requests@2.19:") depends_on("py-xxhash") - depends_on("py-multiprocess") + depends_on("py-multiprocess@:0.70.16") depends_on("py-packaging") with when("@:1.8.0"): depends_on("py-dill@:0.3.6") @@ -39,24 +40,28 @@ class PyDatasets(PythonPackage): depends_on("py-huggingface-hub@:0.0") depends_on("py-importlib-metadata", when="^python@:3.7") depends_on("py-pyarrow@1:3+parquet") - depends_on("py-tqdm@4.27:4.49", when="@:1.8.0") + depends_on("py-tqdm@4.27:4.49") + with when("@2.8.0"): + depends_on("py-responses@:0.18") with when("@2.8.0:"): depends_on("py-aiohttp") depends_on("py-pyyaml@5.1:") - depends_on("python@3.7:") - with when("@2.8.0"): depends_on("py-dill@:0.3.6") depends_on("py-fsspec@2021.11.1:+http") depends_on("py-huggingface-hub@0.2:0") depends_on("py-pyarrow@6:+parquet") - depends_on("py-responses@:0.18") depends_on("py-tqdm@4.62.1:") + depends_on("python@3.7:") with when("@2.20.0:"): depends_on("py-filelock") depends_on("py-dill@0.3.0:0.3.8") # temporary upper bound depends_on("py-fsspec@2023.1.0:2024.5.0+http") depends_on("py-huggingface-hub@0.21.2:") - depends_on("py-pyarrow@15:+parquet") + depends_on("py-pyarrow@15:+parquet+dataset") depends_on("py-requests@2.32.2:") depends_on("py-tqdm@4.66.3:") depends_on("python@3.8:") + with when("@3.2.0:"): + depends_on("py-huggingface-hub@0.23.0:") + depends_on("py-fsspec@2023.1.0:2024.9.0+http") + depends_on("python@3.9:") diff --git a/var/spack/repos/builtin/packages/py-nanotron/package.py b/var/spack/repos/builtin/packages/py-nanotron/package.py new file mode 100644 index 00000000000..c08fe169aa1 --- /dev/null +++ b/var/spack/repos/builtin/packages/py-nanotron/package.py @@ -0,0 +1,37 @@ +# Copyright Spack Project Developers. See COPYRIGHT file for details. +# +# SPDX-License-Identifier: (Apache-2.0 OR MIT) + +from spack.package import * + + +class PyNanotron(PythonPackage): + """Minimalistic large language model 3D-parallelism training.""" + + homepage = "https://github.com/huggingface/nanotron" + url = "https://github.com/huggingface/nanotron/archive/refs/tags/v0.4.tar.gz" + git = "https://github.com/huggingface/nanotron.git" + + maintainers("thomas-bouvier") + + license("Apache-2.0") + + version("main", branch="main") + version("0.4", sha256="30e9cdd07e86166dd9690351d9d995b3560810044fdca64737ed042cd91c792a") + + variant("examples", default=True, description="Build with example scripts support") + + depends_on("python@3.6:3.11") + + depends_on("py-setuptools", type="build") + depends_on("py-torch@1.13.0:", type=("build", "run")) + depends_on("py-pyyaml", type=("build", "run")) + depends_on("py-numpy@:2", type=("build", "run")) + depends_on("py-packaging", type=("build", "run")) + depends_on("py-safetensors", type=("build", "run")) + depends_on("py-dacite", type=("build", "run")) + depends_on("py-tqdm", type=("build", "run")) + depends_on("py-datasets", type=("build", "run"), when="@0.5:") + + depends_on("py-transformers", type=("build", "run"), when="+examples") + depends_on("py-flash-attn", type=("build", "run"), when="+examples") diff --git a/var/spack/repos/builtin/packages/py-safetensors/package.py b/var/spack/repos/builtin/packages/py-safetensors/package.py index 7dad8a9acc5..c2f73bc6cbe 100644 --- a/var/spack/repos/builtin/packages/py-safetensors/package.py +++ b/var/spack/repos/builtin/packages/py-safetensors/package.py @@ -11,6 +11,8 @@ class PySafetensors(PythonPackage): homepage = "https://github.com/huggingface/safetensors" pypi = "safetensors/safetensors-0.3.1.tar.gz" + maintainers("thomas-bouvier") + version("0.4.5", sha256="d73de19682deabb02524b3d5d1f8b3aaba94c72f1bbfc7911b9b9d5d391c0310") version("0.4.3", sha256="2f85fc50c4e07a21e95c24e07460fe6f7e2859d0ce88092838352b798ce711c2") version("0.3.1", sha256="571da56ff8d0bec8ae54923b621cda98d36dcef10feb36fd492c4d0c2cd0e869")