diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d8d8710..340b04c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -45,8 +45,8 @@ jobs: python-version: ['3.10', '3.11', '3.12'] include: - os: ubuntu-latest - python-version: 3.9 - DEPENDENCIES: matplotlib==3.3 numba==0.55.1 ray[default]==2.9 + python-version: 3.10 + DEPENDENCIES: matplotlib==3.8 numba==0.56.4 pyopencl==2023.1.2 LABEL: -oldest steps: - uses: actions/checkout@v6 diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 27ed305..f178f62 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -6,6 +6,20 @@ All notable changes to PyEBSDIndex will be documented in this file. The format i on `Keep a Changelog `_. +0.3.9.2 (2026-03-06) +================== + Added +----- + +Changed +------- +- Python 3.10 is new minimum required python version. + +Fixed +----- +- Fixed PSO optimization for numpy 2.4 error. + + 0.3.9 (2026-01-26) ================== diff --git a/pyebsdindex/__init__.py b/pyebsdindex/__init__.py index 52a7f0f..d709aa8 100644 --- a/pyebsdindex/__init__.py +++ b/pyebsdindex/__init__.py @@ -7,7 +7,7 @@ ] __description__ = "Python based tool for Radon based EBSD indexing" __name__ = "pyebsdindex" -__version__ = "0.3.9.1" +__version__ = "0.3.9.2" # Try to import only once - also will perform check that at least one GPU is found. diff --git a/pyebsdindex/pcopt.py b/pyebsdindex/pcopt.py index c8bb2a8..4400e91 100644 --- a/pyebsdindex/pcopt.py +++ b/pyebsdindex/pcopt.py @@ -93,8 +93,7 @@ def _optfunction(PC_i, indexer=None, banddat=None): #average_fit /= npoints result[q] = average_fit - #print(timer()-tic) - return result + return result.squeeze() def optimize(pats, indexer, PC0=None, batch=False): @@ -480,7 +479,7 @@ def updateswarmbest(self, fun2opt, pool, **kwargs): #tic = timer() for part_i in range(self.n_particles): - temp = self.pos[part_i, :] + temp = self.pos[part_i, :].squeeze() val[part_i] = fun2opt(temp, **kwargs) #print(timer()-tic) diff --git a/setup.py b/setup.py index 3a551e0..ab6b9cc 100644 --- a/setup.py +++ b/setup.py @@ -29,7 +29,7 @@ "pyopencl", ], "parallel": [ - "ray[default] >= 2.9", + "ray[default] < 2.53", # "pydantic < 2", ] } @@ -57,7 +57,6 @@ long_description_content_type="text/markdown", classifiers=[ "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12",