From bbf1a067556b0d19780d507c910e844c8a8a7e96 Mon Sep 17 00:00:00 2001 From: mmcky Date: Tue, 4 Apr 2023 10:15:32 +1000 Subject: [PATCH 1/3] ENH: Upgrade anaconda==2023.03 + CUDA 12.1 --- .github/workflows/cache.yml | 6 ++---- .github/workflows/ci.yml | 6 ++---- .github/workflows/execution-linux.yml | 2 +- .github/workflows/execution-osx.yml | 2 +- .github/workflows/execution-win.yml | 2 +- .github/workflows/linkcheck.yml | 2 +- .github/workflows/publish.yml | 6 ++---- environment.yml | 4 ++-- 8 files changed, 12 insertions(+), 18 deletions(-) diff --git a/.github/workflows/cache.yml b/.github/workflows/cache.yml index 04bb3669..9fd0bc62 100644 --- a/.github/workflows/cache.yml +++ b/.github/workflows/cache.yml @@ -27,18 +27,16 @@ jobs: needs: deploy-runner runs-on: [self-hosted, cml-gpu] container: - image: docker://mmcky/quantecon-lecture-python:py39-anaconda-2022-10-jb-0.15.1 + image: docker://mmcky/quantecon-lecture-python:cuda-12.1.0-anaconda-2023-03-py310 options: --gpus all steps: - uses: actions/checkout@v3 with: ref: ${{ github.event.pull_request.head.sha }} # Install Hardware Dependant Libraries - - name: Install Jax and Upgrade CUDA + - name: Check nvidia drivers shell: bash -l {0} run: | - pip install --upgrade "jax[cuda]==0.4.2" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html - pip install --upgrade "numpyro[cuda]" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html nvidia-smi - name: Build HTML shell: bash -l {0} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fc123407..6bfaed7d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,18 +24,16 @@ jobs: needs: deploy-runner runs-on: [self-hosted, cml-gpu] container: - image: docker://mmcky/quantecon-lecture-python:py39-anaconda-2022-10-jb-0.15.1 + image: docker://mmcky/quantecon-lecture-python:cuda-12.1.0-anaconda-2023-03-py310 options: --gpus all steps: - uses: actions/checkout@v3 with: ref: ${{ github.event.pull_request.head.sha }} # Install Hardware Dependant Libraries - - name: Install Jax and Upgrade CUDA + - name: Check nvidia drivers shell: bash -l {0} run: | - pip install --upgrade "jax[cuda]==0.4.2" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html - pip install --upgrade "numpyro[cuda]" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html nvidia-smi - name: Display Conda Environment Versions shell: bash -l {0} diff --git a/.github/workflows/execution-linux.yml b/.github/workflows/execution-linux.yml index fe76eaf8..b47224d0 100644 --- a/.github/workflows/execution-linux.yml +++ b/.github/workflows/execution-linux.yml @@ -11,7 +11,7 @@ jobs: fail-fast: false matrix: os: ["ubuntu-latest"] - python-version: ["3.9"] + python-version: ["3.10"] steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/execution-osx.yml b/.github/workflows/execution-osx.yml index 0a5e90de..0b24c800 100644 --- a/.github/workflows/execution-osx.yml +++ b/.github/workflows/execution-osx.yml @@ -11,7 +11,7 @@ jobs: fail-fast: false matrix: os: ["macos-latest"] - python-version: ["3.9"] + python-version: ["3.10"] steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/execution-win.yml b/.github/workflows/execution-win.yml index 1e333d34..8b1091b4 100644 --- a/.github/workflows/execution-win.yml +++ b/.github/workflows/execution-win.yml @@ -11,7 +11,7 @@ jobs: fail-fast: false matrix: os: ["windows-latest"] - python-version: ["3.9"] + python-version: ["3.10"] steps: - name: Checkout uses: actions/checkout@v2 diff --git a/.github/workflows/linkcheck.yml b/.github/workflows/linkcheck.yml index d0247cfa..969801e1 100644 --- a/.github/workflows/linkcheck.yml +++ b/.github/workflows/linkcheck.yml @@ -23,7 +23,7 @@ jobs: auto-update-conda: true auto-activate-base: true miniconda-version: 'latest' - python-version: 3.9 + python-version: 3.10 environment-file: environment.yml activate-environment: quantecon - name: Download "build" folder (cache) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index bb4d797c..e1cf23b6 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -28,17 +28,15 @@ jobs: needs: deploy-runner runs-on: [self-hosted, cml-gpu] container: - image: docker://mmcky/quantecon-lecture-python:py39-anaconda-2022-10-jb-0.15.1 + image: docker://mmcky/quantecon-lecture-python:cuda-12.1.0-anaconda-2023-03-py310 options: --gpus all steps: - name: Checkout uses: actions/checkout@v3 # Install Hardware Dependant Libraries - - name: Install Jax and Upgrade CUDA + - name: Check nvidia drivers shell: bash -l {0} run: | - pip install --upgrade "jax[cuda]==0.4.2" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html - pip install --upgrade "numpyro[cuda]" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html nvidia-smi - name: Display Conda Environment Versions shell: bash -l {0} diff --git a/environment.yml b/environment.yml index 43c262d8..7424c22b 100644 --- a/environment.yml +++ b/environment.yml @@ -2,8 +2,8 @@ name: quantecon channels: - default dependencies: - - python=3.9 - - anaconda=2022.10 + - python=3.10 + - anaconda=2023.03 - pip - pip: - jupyter-book==0.15.1 From ae5f1630bd3bd2b692bf170ee406d30801dab519 Mon Sep 17 00:00:00 2001 From: mmcky Date: Tue, 4 Apr 2023 10:16:45 +1000 Subject: [PATCH 2/3] TST: remove cache for full build --- .github/workflows/ci.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6bfaed7d..e17df5dc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,13 +41,13 @@ jobs: - name: Display Pip Versions shell: bash -l {0} run: pip list - - name: Download "build" folder (cache) - uses: dawidd6/action-download-artifact@v2 - with: - workflow: cache.yml - branch: main - name: build-cache - path: _build + # - name: Download "build" folder (cache) + # uses: dawidd6/action-download-artifact@v2 + # with: + # workflow: cache.yml + # branch: main + # name: build-cache + # path: _build # Build Assets (Download Notebooks and PDF via LaTeX) - name: Build Download Notebooks (sphinx-tojupyter) shell: bash -l {0} From 3d5161e7761d1f631c662b937e3490b3c1f6321e Mon Sep 17 00:00:00 2001 From: mmcky Date: Tue, 4 Apr 2023 10:30:23 +1000 Subject: [PATCH 3/3] sytax fix for linkchecker --- .github/workflows/linkcheck.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/linkcheck.yml b/.github/workflows/linkcheck.yml index 969801e1..671c6bfc 100644 --- a/.github/workflows/linkcheck.yml +++ b/.github/workflows/linkcheck.yml @@ -23,7 +23,7 @@ jobs: auto-update-conda: true auto-activate-base: true miniconda-version: 'latest' - python-version: 3.10 + python-version: "3.10" environment-file: environment.yml activate-environment: quantecon - name: Download "build" folder (cache)