diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index ad0971a..9a56174 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -10,15 +10,14 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - python-version: ['3.7', '3.8', '3.9'] os: [macos-latest, ubuntu-latest, windows-latest] steps: - - uses: actions/checkout@v2 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v2 + - uses: actions/checkout@v4 + - name: Set up Python 3.x + uses: actions/setup-python@v4 with: - python-version: ${{ matrix.python-version }} + python-version: '3.x' - name: Install fftw3 libs (Linux) if: runner.os == 'Linux' run: | diff --git a/.github/workflows/deploy_pypi.yml b/.github/workflows/deploy_pypi.yml index 9087624..79edef3 100644 --- a/.github/workflows/deploy_pypi.yml +++ b/.github/workflows/deploy_pypi.yml @@ -10,11 +10,11 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: - python-version: 3.8 + python-version: '3.x' - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/CHANGELOG b/CHANGELOG index 5a89189..ee5e58e 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +0.9.2 + - ci: python build version changed to latest minor version + - ref: update unwrap arg name from seed to rng 0.9.1 - setup: bump qpretrieve from 0.2.6 to 0.2.8 0.9.0 diff --git a/qpimage/core.py b/qpimage/core.py index 5902e8d..b56c310 100644 --- a/qpimage/core.py +++ b/qpimage/core.py @@ -362,10 +362,10 @@ def _get_amp_pha(self, data, which_data, bg_data=None, proc_phase=True): pham = pha.copy() pham[nanmask] = 0 pham = np.ma.masked_array(pham, mask=nanmask) - pha = unwrap_phase(pham, seed=47) + pha = unwrap_phase(pham, rng=47) pha[nanmask] = np.nan else: - pha = unwrap_phase(pha, seed=47) + pha = unwrap_phase(pha, rng=47) # remove 2PI offsets that might be present in the border phase border = np.concatenate((pha[0, :], pha[-1, :], diff --git a/setup.py b/setup.py index 3691061..ba5ee37 100644 --- a/setup.py +++ b/setup.py @@ -29,10 +29,10 @@ "nrefocus[FFTW]>=0.4.3", # Refocus class "numpy>=1.9.0", "qpretrieve[FFTW]>=0.2.8", - "scikit-image>=0.11.0", + "scikit-image>=0.21.0", "scipy>=0.18.0", ], - python_requires='>=3.6, <4', + python_requires='>=3.8, <4', keywords=["digital holographic microscopy", "optics", "quantitative phase imaging", diff --git a/tests/test_series.py b/tests/test_series.py index 5d5ef69..d49b266 100644 --- a/tests/test_series.py +++ b/tests/test_series.py @@ -168,7 +168,9 @@ def test_series_hdf5_hardlink_bg(): def test_series_meta(): h5file = pathlib.Path(__file__).parent / "data" / "bg_tilt.h5" - with pytest.raises((OSError, RuntimeError)): + # We have no write intent on the file, so we cannot modify + # the metadata. + with pytest.raises((OSError, RuntimeError, KeyError)): qpimage.QPImage(h5file=h5file, meta_data={"wavelength": 333e-9}, h5mode="r")