From 597751506eab4673bdfad401d37f586216cec1f5 Mon Sep 17 00:00:00 2001 From: krzywon Date: Thu, 30 May 2024 16:37:04 -0400 Subject: [PATCH 01/11] testing pinned pyopencl --- .github/workflows/test.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ff0441e5..95abd497 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,7 +9,7 @@ jobs: strategy: matrix: os: [macos-latest, ubuntu-latest, windows-latest] - python-version: ["3.7", "3.8", "3.9", "3.10"] + python-version: ["3.10", "3.11"] steps: - uses: actions/checkout@v3 @@ -35,7 +35,7 @@ jobs: - name: setup pyopencl on Linux + macOS if: ${{ matrix.os != 'windows-latest' }} run: | - python -m pip install pyopencl + python -m pip install pyopencl==2024.1 - name: setup pyopencl on Windows if: ${{ matrix.os == 'windows-latest' }} @@ -43,7 +43,7 @@ jobs: python -m pip install pytools mako cffi choco install opencl-intel-cpu-runtime - python -m pip install --only-binary=pyopencl --find-links http://www.silx.org/pub/wheelhouse/ --trusted-host www.silx.org pyopencl + python -m pip install --only-binary=pyopencl --find-links http://www.silx.org/pub/wheelhouse/ --trusted-host www.silx.org pyopencl==2024.1 - name: Test with pytest env: From 61c74b311f329fe39f7e7f6191d273121364584a Mon Sep 17 00:00:00 2001 From: krzywon Date: Thu, 30 May 2024 16:42:53 -0400 Subject: [PATCH 02/11] Only test windows --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 95abd497..febe6826 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -8,7 +8,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [macos-latest, ubuntu-latest, windows-latest] + os: [windows-latest] # macos-latest, ubuntu-latest, python-version: ["3.10", "3.11"] steps: From 925dc6bb60ea0eb53785c8a1f888dcc42ec9507b Mon Sep 17 00:00:00 2001 From: krzywon Date: Mon, 3 Jun 2024 14:31:56 -0400 Subject: [PATCH 03/11] Try earlier version of pyopencl for Ubuntu --- .github/workflows/test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index febe6826..d6139c3e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -8,7 +8,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [windows-latest] # macos-latest, ubuntu-latest, + os: [macos-latest, ubuntu-latest, windows-latest] python-version: ["3.10", "3.11"] steps: @@ -35,7 +35,7 @@ jobs: - name: setup pyopencl on Linux + macOS if: ${{ matrix.os != 'windows-latest' }} run: | - python -m pip install pyopencl==2024.1 + python -m pip install pyopencl==2023.1.4 - name: setup pyopencl on Windows if: ${{ matrix.os == 'windows-latest' }} From b733aa64833b4fadab6013d74dad351cebc6c320 Mon Sep 17 00:00:00 2001 From: krzywon Date: Mon, 3 Jun 2024 14:36:39 -0400 Subject: [PATCH 04/11] Install AMD processor utilities for Ubuntu --- .github/workflows/test.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d6139c3e..acc48870 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,8 +22,11 @@ jobs: - name: setup apt dependencies for Linux if: ${{ matrix.os == 'ubuntu-latest' }} run: | - sudo apt-get update - sudo apt-get install opencl-headers ocl-icd-opencl-dev libpocl2 + wget https://repo.radeon.com/amdgpu-install/6.1.1/ubuntu/jammy/amdgpu-install_6.1.60101-1_all.deb + sudo apt install ./amdgpu-install_6.1.60101-1_all.deb + sudo apt update + sudo apt install amdgpu-dkms + sudo apt install rocm - name: Install Python dependencies run: | @@ -35,7 +38,7 @@ jobs: - name: setup pyopencl on Linux + macOS if: ${{ matrix.os != 'windows-latest' }} run: | - python -m pip install pyopencl==2023.1.4 + python -m pip install pyopencl - name: setup pyopencl on Windows if: ${{ matrix.os == 'windows-latest' }} From 1c157586ce15dc3f362d560ad5bc991ce19094a4 Mon Sep 17 00:00:00 2001 From: krzywon Date: Mon, 3 Jun 2024 15:04:39 -0400 Subject: [PATCH 05/11] Attempt to fix no space left error --- .github/workflows/test.yml | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index acc48870..fb5ea621 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,13 +12,21 @@ jobs: python-version: ["3.10", "3.11"] steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} + - name: Free Disk Space (Ubuntu) + if: ${{ matrix.os == 'ubuntu-latest' }} + uses: jlumbroso/free-disk-space@main + with: + # this might remove tools that are actually needed, + # when set to "true" but frees about 6 GB + tool-cache: true + - name: setup apt dependencies for Linux if: ${{ matrix.os == 'ubuntu-latest' }} run: | From 9c8b5a3753593ad4d4f885d3dfb0f1c143c9eea3 Mon Sep 17 00:00:00 2001 From: krzywon Date: Mon, 3 Jun 2024 17:19:38 -0400 Subject: [PATCH 06/11] Testing --- .github/workflows/test.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fb5ea621..8e6de278 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -54,7 +54,7 @@ jobs: python -m pip install pytools mako cffi choco install opencl-intel-cpu-runtime - python -m pip install --only-binary=pyopencl --find-links http://www.silx.org/pub/wheelhouse/ --trusted-host www.silx.org pyopencl==2024.1 + python -m pip install --only-binary=pyopencl --find-links http://www.silx.org/pub/wheelhouse/ --trusted-host www.silx.org pyopencl - name: Test with pytest env: @@ -69,6 +69,8 @@ jobs: - name: check that the docs build (linux only) if: ${{ matrix.os == 'ubuntu-latest' }} run: | + sudo apt install make + sudo apt install echo make -j 4 -C doc SPHINXOPTS="-W --keep-going -n" html - name: Publish samodels docs From 0bb4181f243c26cd78db9638e55834906516bedd Mon Sep 17 00:00:00 2001 From: krzywon Date: Mon, 3 Jun 2024 17:41:08 -0400 Subject: [PATCH 07/11] Testing part 2 --- .github/workflows/test.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8e6de278..f9df1954 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -69,9 +69,7 @@ jobs: - name: check that the docs build (linux only) if: ${{ matrix.os == 'ubuntu-latest' }} run: | - sudo apt install make - sudo apt install echo - make -j 4 -C doc SPHINXOPTS="-W --keep-going -n" html + -make -j 4 -C doc SPHINXOPTS="-W --keep-going -n" html - name: Publish samodels docs if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'}} From f2e3c7e8e312ca14fa4f36cb3dfb658d21e534aa Mon Sep 17 00:00:00 2001 From: krzywon Date: Tue, 4 Jun 2024 10:46:39 -0400 Subject: [PATCH 08/11] Be less aggressive with disk space free-up --- .github/workflows/test.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f9df1954..9b5a3c40 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,10 +22,6 @@ jobs: - name: Free Disk Space (Ubuntu) if: ${{ matrix.os == 'ubuntu-latest' }} uses: jlumbroso/free-disk-space@main - with: - # this might remove tools that are actually needed, - # when set to "true" but frees about 6 GB - tool-cache: true - name: setup apt dependencies for Linux if: ${{ matrix.os == 'ubuntu-latest' }} @@ -69,7 +65,7 @@ jobs: - name: check that the docs build (linux only) if: ${{ matrix.os == 'ubuntu-latest' }} run: | - -make -j 4 -C doc SPHINXOPTS="-W --keep-going -n" html + make -j 4 -C doc SPHINXOPTS="-W --keep-going -n" html - name: Publish samodels docs if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'}} From aa2f6a2630b170ae205c973f2b176e26b5310c64 Mon Sep 17 00:00:00 2001 From: krzywon Date: Tue, 4 Jun 2024 11:07:34 -0400 Subject: [PATCH 09/11] Be less aggressive with disk space free-up part 2 --- .github/workflows/test.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9b5a3c40..ee92a1bc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,6 +22,9 @@ jobs: - name: Free Disk Space (Ubuntu) if: ${{ matrix.os == 'ubuntu-latest' }} uses: jlumbroso/free-disk-space@main + with: + haskell: false + large-packages: false - name: setup apt dependencies for Linux if: ${{ matrix.os == 'ubuntu-latest' }} From c8eb84e5e1df18400cf49d7e361615d58d3615e2 Mon Sep 17 00:00:00 2001 From: krzywon Date: Tue, 4 Jun 2024 12:06:59 -0400 Subject: [PATCH 10/11] Ignore sphinx warnings from types.ModuleType --- doc/conf.py | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/conf.py b/doc/conf.py index f699179b..6173c657 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -40,6 +40,7 @@ ('py:class', 'pyopencl._cl.Device'), ('py:class', 'pyopencl._cl.Kernel'), ('py:class', 'QWebView'), + ('py:class', 'types.ModuleType'), ('py:class', 'unittest.suite.TestSuite'), ('py:class', 'wx.Frame'), # autodoc and namedtuple is completely broken From 1374625be2e5414e525f2a977d3b4f67767cc65e Mon Sep 17 00:00:00 2001 From: krzywon Date: Tue, 4 Jun 2024 13:13:25 -0400 Subject: [PATCH 11/11] Remove 2nd nitpick_ignore from conf.py and ensure original has all modules from both lists --- doc/conf.py | 36 ++---------------------------------- 1 file changed, 2 insertions(+), 34 deletions(-) diff --git a/doc/conf.py b/doc/conf.py index 6173c657..9a041857 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -27,6 +27,7 @@ nitpick_ignore = [ ('py:class', 'argparse.Namespace'), + ('py:class', 'bumps.parameter.Parameter'), ('py:class', 'collections.OrderedDict'), ('py:class', 'cuda.Context'), ('py:class', 'cuda.Function'), @@ -56,6 +57,7 @@ ('py:class', 'module'), ('py:class', 'SesansData'), ('py:class', 'SourceModule'), + ('py:class', 'TestCondition'), # KernelModel and Calculator breaking on git actions tests, even though # KernelModel is already listed. astropy example sometimes includes full # path to complaining symbol. Let's see if that helps here: @@ -142,40 +144,6 @@ # A list of ignored prefixes for module index sorting. #modindex_common_prefix = [] -nitpick_ignore = [ - ('py:class', 'argparse.Namespace'), - ('py:class', 'bumps.parameter.Parameter'), - ('py:class', 'collections.OrderedDict'), - ('py:class', 'cuda.Context'), - ('py:class', 'cuda.Function'), - ('py:class', 'np.dtype'), - ('py:class', 'numpy.dtype'), - ('py:class', 'np.ndarray'), - ('py:class', 'numpy.ndarray'), - ('py:class', 'pyopencl.Program'), - ('py:class', 'pyopencl._cl.Context'), - ('py:class', 'pyopencl._cl.CommandQueue'), - ('py:class', 'pyopencl._cl.Device'), - ('py:class', 'pyopencl._cl.Kernel'), - ('py:class', 'QWebView'), - ('py:class', 'unittest.suite.TestSuite'), - ('py:class', 'wx.Frame'), - # autodoc and namedtuple is completely broken - ('py:class', 'integer -- return number of occurrences of value'), - ('py:class', 'integer -- return first index of value.'), - # autodoc doesn't handle these type definitions - ('py:class', 'Data'), - ('py:class', 'Data1D'), - ('py:class', 'Data2D'), - ('py:class', 'Kernel'), - ('py:class', 'ModelInfo'), - ('py:class', 'module'), - ('py:class', 'SesansData'), - ('py:class', 'SourceModule'), - ('py:class', 'TestCondition'), -] - - # -- Options for HTML output ---------------------------------------------------