diff --git a/container/dependencies.nix b/container/dependencies.nix index d6e9e6d..1f46fbd 100755 --- a/container/dependencies.nix +++ b/container/dependencies.nix @@ -25,7 +25,7 @@ let patched_rPackages = which curl wget zip unzip - pandoc + pandoc quarto dcm2niix dcmtk gdcm simpleitk ants cudaPackages.cudatoolkit snakemake @@ -65,6 +65,7 @@ let patched_rPackages = avro backcall bleach + bokeh catboost certifi cffi @@ -73,20 +74,24 @@ let patched_rPackages = cryptography cycler cython + dask datasets debugpy decorator defusedxml + deid #efficientnet-pytorch entrypoints evaluate einops - grad-cam + #grad-cam # waiting for https://github.com/NixOS/nixpkgs/issues/220341 + fastai greenlet h5py httplib2 hupper idna + ignite imageio importlib-metadata ipykernel @@ -98,6 +103,8 @@ let patched_rPackages = #nipype antspyx iso8601 + jax + jaxlibWithCuda jedi jinja2 joblib @@ -112,7 +119,7 @@ let patched_rPackages = kaggle keras keyring - keyrings-alt + keyrings-cryptfile kiwisolver lightgbm llvmlite @@ -127,6 +134,7 @@ let patched_rPackages = mdai nbclient nbconvert + nbdev nbformat nest-asyncio networkx @@ -155,6 +163,7 @@ let patched_rPackages = protobuf ptyprocess pudb + #pycm pycparser pycrypto pydicom @@ -178,6 +187,7 @@ let patched_rPackages = pyzmq qtconsole qtpy + qudida requests requests-cache requests_oauthlib @@ -187,24 +197,30 @@ let patched_rPackages = scipy secretstorage send2trash - six slicer sqlalchemy + tables terminado terminaltables testpath text-unidecode + plotnine + polars + pymc3 pytorchWithCuda pytorch-lightning - tensorflow - tensorboardx - torchvision - torchmetrics rising simpleitk seaborn - sentencepiece # for transformers tokenizing + sentencepiece + siuba + skorch statsmodels + tensorflow + tensorboardx + torchvision + torchmetrics + timm torchio tornado tqdm diff --git a/container/nix-requirements.txt b/container/nix-requirements.txt index e634a84..b8f8437 100644 --- a/container/nix-requirements.txt +++ b/container/nix-requirements.txt @@ -195,8 +195,6 @@ networkx nibabel nilearn nipype -niwidgets -nose notebook numba numpy diff --git a/container/overlay.nix b/container/overlay.nix index 1a6a57e..1f55338 100644 --- a/container/overlay.nix +++ b/container/overlay.nix @@ -1,126 +1,36 @@ old-pkgs: final: prev: { - dcmtk = old-pkgs.dcmtk; python310 = prev.python310.override { packageOverrides = pfinal: pprev: { - opencv3 = pprev.opencv3.override { openblas = final.openblasCompat; }; - torch = pprev.torch.override { cudaSupport = true; }; - poetry = pprev.poetry.overrideAttr (af: ap: { postPatch = '' - substituteInPlace pyproject.toml \ - --replace 'crashtest = "^0.3.0"' 'crashtest = "*"' \ - --replace 'xattr = { version = "^0.9.7"' 'xattr = { version = "^0.10.0"' \ - --replace 'cleo = "^2.0.0"' "" - ''; }); - tensorflow = pprev.tensorflow-build.override ({ + # remove `torch` and `tensorflow` overrides when config.enableCuda is set + # after https://github.com/NixOS/nixpkgs/issues/220341 is resolved + torch = pprev.torch.override { cudaSupport = true; - }); - ttach = pfinal.buildPythonPackage rec { - pname = "ttach"; - version = "0.0.3"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "EgxN2IH+sOnI3WOxVPJlWJHD4gaJtoqU0WK/1VV7y0g="; - }; - checkInputs = [ pfinal.pytest pfinal.torch ]; - }; - #torchvision = pprev.torchvision.override { pytorch = pfinal.pytorchWithCuda; }; - pydeprecate = pfinal.buildPythonPackage rec { - pname = "pyDeprecate"; - version = "0.3.1"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "+iaHCSTTR1Yhw0QEXCwBoWugNBE6kCYAx451s/rF9yw="; - }; }; - torchmetrics = pfinal.buildPythonPackage rec { - pname = "torchmetrics"; - version = "0.7.3"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "h150Sm22PIh1cmDWPLgJGdA5hzSn9Fb46kGBuy25V9g="; - }; - propagatedBuildInputs = with pfinal; [ numpy torch pydeprecate ]; - checkInputs = with pfinal; [ pytest pytest-doctestplus pytestCheckHook ]; - }; - lightning-utilities = pfinal.buildPythonPackage rec { - pname = "lightning-utilities"; - version = "0.5.0"; - src = final.fetchFromGitHub { - owner = "Lightning-AI"; - repo = "utilities"; - rev = "v" + version; - hash = "sha256-J73sUmX1a7ww+rt1vwBt9P0Xbeoxag6jR0W63xEySCI="; - }; - propagatedBuildInputs = with pfinal; [ fire typing-extensions packaging ]; - #checkInputs = with pfinal; [ pytestCheckHook ]; - doCheck = false; - }; - pytorch-lightning = pprev.pytorch-lightning.overrideAttrs (oa: rec { - propagatedBuildInputs = oa.propagatedBuildInputs ++ - (with pfinal; [ pydeprecate torchmetrics fsspec croniter - deepdiff arrow psutil beautifulsoup4 lightning-utilities - inquirer tensorboardx - ]); - version = "1.8.6"; - src = final.fetchFromGitHub { - owner = "Lightning-AI"; - repo = oa.pname; - rev = version; - hash = "sha256-5AyOCeRFiV7rdmoBPx03Xju6eTR/3jiE+HQBiEmdzmo="; - }; - PACKAGE_NAME="pytorch"; - postPatch = '' - substituteInPlace requirements/app/base.txt --replace "inquirer>=2.10.0" "inquirer" - ''; + tensorflow = pprev.tensorflow-build.override ({ + cudaSupport = true; }); - grad-cam = pfinal.buildPythonPackage rec { - pname = "grad-cam"; - version = "1.3.7"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "y9LlgmgbP7X+Qdx+cs0Z4b1mXgPhgCX1IFCvLTI8ces="; - }; - propagatedBuildInputs = with pfinal; [ - numpy pillow torch torchvision ttach tqdm opencv3 - ]; - postPatch = '' - substituteInPlace requirements.txt --replace "opencv-python" "" - ''; - }; qudida = pfinal.buildPythonPackage rec { pname = "qudida"; version = "0.0.4"; src = pfinal.fetchPypi { inherit pname version; - sha256 = "2xmOKIerDJqgAj5WWvv/Qd+3azYfhf1eE/eA11uhjMg="; - }; + hash = "sha256-2xmOKIerDJqgAj5WWvv/Qd+3azYfhf1eE/eA11uhjMg="; + }; + propagatedBuildInputs = with pfinal; [ - numpy scikit-learn typing-extensions opencv3 + numpy scikit-learn typing-extensions opencv4 ]; + nativeCheckInputs = [ pfinal.pytestCheckHook ]; + doCheck = false; # no tests in PyPI dist + postPatch = '' - echo "numpy>=0.18.0" > requirements.txt - echo "scikit-learn>=0.19.1" >> requirements.txt - echo "typing-extensions" >> requirements.txt - substituteInPlace setup.py --replace \ - "install_requires=get_install_requirements(INSTALL_REQUIRES, CHOOSE_INSTALL_REQUIRES)" \ - "install_requires=INSTALL_REQUIRES" - ''; + echo "numpy>=0.18.0" > requirements.txt + echo "scikit-learn>=0.19.1" >> requirements.txt + echo "typing-extensions" >> requirements.txt + substituteInPlace setup.py --replace \ + "install_requires=get_install_requirements(INSTALL_REQUIRES, CHOOSE_INSTALL_REQUIRES)" \ + "install_requires=INSTALL_REQUIRES" + ''; }; - # albumentations = pfinal.buildPythonPackage rec { - # pname = "albumentations"; - # version = "1.1.0"; - # src = pfinal.fetchPypi { - # inherit pname version; - # sha256 = "YLBnswk5CLzFKtsqpdRPV+vbuKtXpHsLQvPcHTsc6CQ="; - # }; - # propagatedBuildInputs = with pfinal; [ - # numpy scipy scikitimage pyyaml qudida torch torchvision imgaug - # ]; - # checkInputs = [ pfinal.pytest ]; - # postPatch = '' - # substituteInPlace setup.py --replace \ - # "install_requires=get_install_requirements(INSTALL_REQUIRES, CHOOSE_INSTALL_REQUIRES)" \ - # "install_requires=INSTALL_REQUIRES" - # ''; - # }; simpleitk = pfinal.buildPythonPackage rec { pname = "SimpleITK"; version = "2.2.1"; @@ -149,7 +59,8 @@ old-pkgs: final: prev: { simpleitk deprecated nibabel click humanize scipy torch tqdm ]; - checkInputs = with pfinal; [ pytest matplotlib ]; + preCheck = ''export HOME=$(mktemp -d)''; + nativeCheckInputs = with pfinal; [ pytest matplotlib ]; pythonImportsCheck = [ "torchio" ]; }; ipycanvas = pfinal.buildPythonPackage rec { @@ -206,59 +117,6 @@ old-pkgs: final: prev: { substituteInPlace pyproject.toml --replace "psycopg2-binary" "psycopg2" ''; }; - interface_meta = pfinal.buildPythonPackage rec { - pname = "interface_meta"; - version = "1.2.5"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "DIGRCsIAo0N5TbEwYndVkuTJbMnw1V6lOFzcOIlFsX0="; - }; - propagatedBuildInputs = with pfinal; [ - setupmeta - ]; - }; - formulaic = pfinal.buildPythonPackage rec { - pname = "formulaic"; - version = "0.3.2"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "PhYmJWIUesve2hF413isGJqTvWPiNIJhvYtdMD8XP20="; - }; - propagatedBuildInputs = with pfinal; [ - astor interface_meta numpy pandas scipy wrapt - ]; - checkInputs = with pfinal; [ pytestCheckHook sympy ]; - }; - # pybids = pfinal.buildPythonPackage rec { - # version = "0.14.0"; - # pname = "pybids"; - - # src = pfinal.fetchPypi { - # inherit pname version; - # sha256 = "73c4d03aad333f2a7cb4405abe96f55a33cffa4b5a2d23fad6ac5767c45562ef"; - # }; - - # propagatedBuildInputs = with pfinal; [ - # click - # num2words - # numpy - # scipy - # pandas - # nibabel - # patsy - # bids-validator - # sqlalchemy - # formulaic - # ]; - - # checkInputs = with pfinal; [ pytestCheckHook ]; - # pythonImportsCheck = [ "bids" ]; - # postPatch = '' - # substituteInPlace setup.cfg --replace "formulaic ~=0.2.4" "formulaic" - # substituteInPlace setup.cfg --replace "sqlalchemy <1.4.0.dev0" "sqlalchemy" - # ''; - # doCheck = false; - # }; antspyx = pfinal.buildPythonPackage rec { pname = "antspyx"; version = "0.3.5"; @@ -279,15 +137,15 @@ old-pkgs: final: prev: { patchelf --set-rpath "${rpath}" "$lib" ''; */ }; - mdai = pfinal.buildPythonPackage rec { + mdai = pfinal.buildPythonPackage rec { pname = "mdai"; version = "0.12.2"; src = pfinal.fetchPypi { inherit pname version; sha256 = "XC6n5fLMMQwkgSgxTyswUydGh+K6WqMzOJEkOZt0DPI="; }; - nativeBuildInputs = [ final.patchelf final.poetry ]; - propagatedBuildInputs = with pfinal; [ arrow matplotlib nibabel numpy opencv3 pandas pillow + nativeBuildInputs = [ final.patchelf pprev.poetry-core ]; + propagatedBuildInputs = with pfinal; [ arrow matplotlib nibabel numpy opencv4 pandas pillow pydicom requests retrying scikitimage tqdm dicom2nifti pyyaml ]; @@ -295,46 +153,19 @@ old-pkgs: final: prev: { pythonImportsCheck = [ "mdai" ]; postPatch = '' - substituteInPlace pyproject.toml --replace 'opencv-python ="*"' "" - ''; + substituteInPlace pyproject.toml --replace 'opencv-python ="*"' "" + ''; }; - cmaes = pfinal.buildPythonPackage rec { - pname = "cmaes"; - version = "0.8.2"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "HAS6I97ZJe8TuW9Cz71mepBepbgHVMdQ5kSLn82pal0="; - }; - propagatedBuildInputs = with pfinal; [ numpy ]; - }; - pyorthanc = pfinal.buildPythonPackage rec { - pname = "pyorthanc"; - version = "1.11.2"; - src = pfinal.fetchPypi { - inherit pname version; - sha256 = "mw92w4VO6HnjKy8Qof8Hidr5MpX6Dom5jxmA5flswNk="; + optuna = with final; with pfinal; callPackage ./overlays/optuna/optuna.nix {}; + #widgetsnbextension = with final; with pfinal; + # callPackage ./overlays/widgetsnbextension/widgetsnbextension.nix {}; + charticles = with final; rPackages.buildRPackage { + name = "charticles"; + src = fetchgit { + url = "ssh://git@github.com/LKS-CHART/charticles"; + rev = "3bf371f"; + sha256 = "qYUpliKrEFM4PVOUrSfh/2Iffl898lL78zb9iVskc7c="; }; - postPatch = '' - substituteInPlace pyproject.toml --replace 'httpx = "^0.23.0"' "" - substituteInPlace setup.py --replace "'httpx>=0.23.0,<0.24.0'" "'httpx'" - substituteInPlace setup.py --replace "'pydicom>=2.3.0,<3.0.0'" "'pydicom'" - ''; - propagatedBuildInputs = with pfinal; [ httpx pydicom requests ]; }; - optuna = with final; with pfinal; callPackage ./overlays/optuna/optuna.nix {}; - evaluate = with final; with pfinal; callPackage ./overlays/evaluate {}; - ipywidgets = with final; with pfinal; callPackage ./overlays/ipywidgets/ipywidgets.nix {}; - widgetsnbextension = with final; with pfinal; - callPackage ./overlays/widgetsnbextension/widgetsnbextension.nix {}; - nbconvert = with final; with pfinal; callPackage ./overlays/nbconvert/nbconvert.nix {}; - }; - }; - charticles = with final; rPackages.buildRPackage { - name = "charticles"; - src = fetchgit { - url = "ssh://git@github.com/LKS-CHART/charticles"; - rev = "3bf371f"; - sha256 = "qYUpliKrEFM4PVOUrSfh/2Iffl898lL78zb9iVskc7c="; - }; - }; + }; }; } diff --git a/container/overlays/evaluate/default.nix b/container/overlays/evaluate/default.nix deleted file mode 100644 index a8039f5..0000000 --- a/container/overlays/evaluate/default.nix +++ /dev/null @@ -1,93 +0,0 @@ -# Copyright (c) 2003-2023 Eelco Dolstra and the Nixpkgs/NixOS contributors - -# Permission is hereby granted, free of charge, to any person obtaining -# a copy of this software and associated documentation files (the -# "Software"), to deal in the Software without restriction, including -# without limitation the rights to use, copy, modify, merge, publish, -# distribute, sublicense, and/or sell copies of the Software, and to -# permit persons to whom the Software is furnished to do so, subject to -# the following conditions: - -# The above copyright notice and this permission notice shall be -# included in all copies or substantial portions of the Software. - -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -{ lib -, buildPythonPackage -, fetchFromGitHub -, pythonOlder -, pythonRelaxDepsHook -, pytestCheckHook -, cookiecutter -, datasets -, dill -, fsspec -, huggingface-hub -, importlib-metadata -, multiprocess -, numpy -, packaging -, pandas -, requests -, responses -, tqdm -, xxhash -}: - -buildPythonPackage rec { - pname = "evaluate"; - version = "0.4.0"; - format = "setuptools"; - - disabled = pythonOlder "3.7"; - - src = fetchFromGitHub { - owner = "huggingface"; - repo = pname; - rev = "refs/tags/v${version}"; - hash = "sha256-O3W2m12R94iY3F7xgkIiiIyqI6vqiZPXn4jAqEDjVCw="; - }; - - nativeBuildInputs = [ pythonRelaxDepsHook ]; - pythonRelaxDeps = [ "responses" ]; - - propagatedBuildInputs = [ - cookiecutter - datasets - numpy - dill - pandas - requests - tqdm - xxhash - multiprocess - fsspec - huggingface-hub - packaging - responses - ] ++ lib.optionals (pythonOlder "3.8") [ - importlib-metadata - ]; - - # most tests require internet access. - doCheck = false; - - pythonImportsCheck = [ - "evaluate" - ]; - - meta = with lib; { - homepage = "https://huggingface.co/docs/evaluate/index"; - description = "Easily evaluate machine learning models and datasets"; - changelog = "https://github.com/huggingface/evaluate/releases/tag/v${version}"; - license = licenses.asl20; - maintainers = with maintainers; [ bcdarwin ]; - }; -} diff --git a/container/overlays/ipywidgets/ipywidgets.nix b/container/overlays/ipywidgets/ipywidgets.nix deleted file mode 100644 index 606386a..0000000 --- a/container/overlays/ipywidgets/ipywidgets.nix +++ /dev/null @@ -1,61 +0,0 @@ -# Copyright (c) 2003-2023 Eelco Dolstra and the Nixpkgs/NixOS contributors - -# Permission is hereby granted, free of charge, to any person obtaining -# a copy of this software and associated documentation files (the -# "Software"), to deal in the Software without restriction, including -# without limitation the rights to use, copy, modify, merge, publish, -# distribute, sublicense, and/or sell copies of the Software, and to -# permit persons to whom the Software is furnished to do so, subject to -# the following conditions: - -# The above copyright notice and this permission notice shall be -# included in all copies or substantial portions of the Software. - -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -{ buildPythonPackage -, fetchPypi -, ipykernel -, ipython -, jupyterlab-widgets -, lib -, nbformat -, pytestCheckHook -, traitlets -, widgetsnbextension -}: - -buildPythonPackage rec { - pname = "ipywidgets"; - version = "7.7.1"; - format = "setuptools"; - - src = fetchPypi { - inherit pname version; - hash = "sha256-Xy+ht6+uGvMsiAiMmCitl43pPd2jk9ftQU5VP+6T3Ks="; - }; - - propagatedBuildInputs = [ - ipython - ipykernel - jupyterlab-widgets - traitlets - nbformat - widgetsnbextension - ]; - - checkInputs = [ pytestCheckHook ]; - - meta = { - description = "IPython HTML widgets for Jupyter"; - homepage = "https://ipython.org/"; - license = lib.licenses.bsd3; - maintainers = with lib.maintainers; [ fridh ]; - }; -} diff --git a/flake.lock b/flake.lock index 7325e14..1d2bb60 100644 --- a/flake.lock +++ b/flake.lock @@ -3,11 +3,11 @@ "flake-compat": { "flake": false, "locked": { - "lastModified": 1641205782, - "narHash": "sha256-4jY7RCWUoZ9cKD8co0/4tFARpWB+57+r1bLLvXNJliY=", + "lastModified": 1673956053, + "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", "owner": "edolstra", "repo": "flake-compat", - "rev": "b7547d3eed6f32d06102ead8991ec52ab0a4f1a7", + "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", "type": "github" }, "original": { @@ -39,11 +39,11 @@ ] }, "locked": { - "lastModified": 1672992692, - "narHash": "sha256-/eLQLSNIa22ARTZbk+x8i0iE8khe1eiHWkuxgTVXZ7g=", + "lastModified": 1676383589, + "narHash": "sha256-KCkWZXCjH+C4Kn7fUGSrEl5btk+sERHhZueSsvVbPWc=", "owner": "guibou", "repo": "nixGL", - "rev": "643e730efb981ffaf8478f441ec9b9aeea1c89f5", + "rev": "c917918ab9ebeee27b0dd657263d3f57ba6bb8ad", "type": "github" }, "original": { @@ -54,40 +54,25 @@ }, "nixpkgs": { "locked": { - "lastModified": 1673453871, - "narHash": "sha256-nU567KGDuHr7hsVFbKzcSby7jWGOrqWOAmJ14X4doOo=", - "owner": "NixOS", + "lastModified": 1678654296, + "narHash": "sha256-aVfw3ThpY7vkUeF1rFy10NAkpKDS2imj3IakrzT0Occ=", + "owner": "nixos", "repo": "nixpkgs", - "rev": "851558501d28bd3117010f71cd1afc7684394849", + "rev": "5a1dc8acd977ff3dccd1328b7c4a6995429a656b", "type": "github" }, "original": { - "id": "nixpkgs", - "ref": "851558501d28bd3", - "type": "indirect" - } - }, - "nixpkgs-old": { - "locked": { - "lastModified": 1647887150, - "narHash": "sha256-1TnRvE3qhhafrQnGapaaSVue6nEwRUICkz227TfHHQw=", - "owner": "NixOS", + "owner": "nixos", + "ref": "nixos-unstable", "repo": "nixpkgs", - "rev": "4c3c80df545ec5cb26b5480979c3e3f93518cbe5", "type": "github" - }, - "original": { - "id": "nixpkgs", - "ref": "4c3c80df545e", - "type": "indirect" } }, "root": { "inputs": { "flake-compat": "flake-compat", "nixGL": "nixGL", - "nixpkgs": "nixpkgs", - "nixpkgs-old": "nixpkgs-old" + "nixpkgs": "nixpkgs" } } }, diff --git a/flake.nix b/flake.nix index 152e5cb..3f5fc75 100644 --- a/flake.nix +++ b/flake.nix @@ -2,36 +2,39 @@ description = "A container and dev environment for medical imaging data science"; # Nixpkgs / NixOS version to use. - inputs.nixpkgs.url = "nixpkgs/851558501d28bd3"; - inputs.nixpkgs-old.url = "nixpkgs/4c3c80df545e"; - inputs.nixGL.url = "github:guibou/nixGL"; - inputs.nixGL.inputs.nixpkgs.follows = "nixpkgs"; + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + nixGL.url = "github:guibou/nixGL"; + nixGL.inputs.nixpkgs.follows = "nixpkgs"; - inputs.flake-compat = { - url = "github:edolstra/flake-compat"; - flake = false; + flake-compat = { + url = "github:edolstra/flake-compat"; + flake = false; + }; }; - outputs = { self, nixpkgs, nixpkgs-old, nixGL, ... }: + outputs = { self, nixpkgs, nixGL, ... }: let # Generate a user-friendly version number. version = builtins.substring 0 8 self.lastModifiedDate; # System types to support. - supportedSystems = [ "x86_64-linux" ]; + supportedSystems = [ "x86_64-linux" ]; # Helper function to generate an attrset '{ x86_64-linux = f "x86_64-linux"; ... }'. forAllSystems = nixpkgs.lib.genAttrs supportedSystems; - pkgsOverlay = forAllSystems (system: import ./container/overlay.nix (import nixpkgs-old {inherit system;})); + pkgsOverlay = forAllSystems (system: import ./container/overlay.nix { }); #(import nixpkgs-old {inherit system;})); # Nixpkgs instantiated for supported system types. nixpkgsFor = forAllSystems ( system: import nixpkgs { inherit system; - config.allowUnfree = true; - overlays = [ pkgsOverlay.${system} nixGL.overlay ]; + config.allowUnfree = true; + #config.cudaSupport = true; # waiting on https://github.com/NixOS/nixpkgs/issues/220341 + config.cudaCapabilities = [ "7.5" ]; + overlays = [ pkgsOverlay.${system} nixGL.overlay ]; }); # Import the relevant dependencies