galumph issueshttps://git.embl.de/grp-svergun/galumph/-/issues2018-03-10T12:51:11Zhttps://git.embl.de/grp-svergun/galumph/-/issues/4Tests fail for scipy >= 1.02018-03-10T12:51:11ZChris KerrTests fail for scipy >= 1.0The `scipy.special.sph_jn` function was removed in scipy 1.0The `scipy.special.sph_jn` function was removed in scipy 1.0Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/5CI build fails2018-03-04T21:09:19ZChris KerrCI build failsThe build fails at `apt-get update`The build fails at `apt-get update`Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/6ALM rotation function2018-03-14T23:24:18ZChris KerrALM rotation functionChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/7ALM shift-Z function2018-03-18T23:50:39ZChris KerrALM shift-Z functionChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/8Improve tests2018-03-14T18:01:31ZChris KerrImprove tests* [x] Use pytest fixtures for setup (e.g. get an OpenCL context)
* [x] Use hypothesis to get more variety of test cases* [x] Use pytest fixtures for setup (e.g. get an OpenCL context)
* [x] Use hypothesis to get more variety of test caseshttps://git.embl.de/grp-svergun/galumph/-/issues/9Change the AtomAlm class to use an OpenCL context passed as an argument2018-03-10T16:11:41ZChris KerrChange the AtomAlm class to use an OpenCL context passed as an argumentHopefully this should also fix the crash on the CI server during the atomalm tests.Hopefully this should also fix the crash on the CI server during the atomalm tests.https://git.embl.de/grp-svergun/galumph/-/issues/10Cross scattering between two Alm objects2018-03-16T17:34:05ZChris KerrCross scattering between two Alm objectsAlso separate the self-scattering intensity function from the atomic scattering kernel.Also separate the self-scattering intensity function from the atomic scattering kernel.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/11Atomalm test segfaults on server2018-03-10T12:51:11ZChris KerrAtomalm test segfaults on serverCurrently the test is skipped with `@pytest.mark.skipif('CI_JOB_ID' in os.environ)`Currently the test is skipped with `@pytest.mark.skipif('CI_JOB_ID' in os.environ)`https://git.embl.de/grp-svergun/galumph/-/issues/15Change Ylm representation to store magnitude and exp(i*phi) separately2020-05-23T08:09:58ZChris KerrChange Ylm representation to store magnitude and exp(i*phi) separatelyTwo advantages:
* Uses less memory (and less memory bandwidth)
* Avoids the problem that some OpenCL implementations are unable to do `async_work_group_copy` on `cfloat_t` arrays (and the compiler warnings that result from the workaround...Two advantages:
* Uses less memory (and less memory bandwidth)
* Avoids the problem that some OpenCL implementations are unable to do `async_work_group_copy` on `cfloat_t` arrays (and the compiler warnings that result from the workaround of casting the array pointer to `float*`)Add to ATSASChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/16Make SphericalHarmonic and SphericalBessel allocate a new array for each call2018-03-13T07:14:45ZChris KerrMake SphericalHarmonic and SphericalBessel allocate a new array for each call...rather than having an internal array and returning a reference to that.
Then it is possible to start calculating the `jl` and `ylm` arrays for a new batch of atoms while `alm_add_atoms` is still using the previous arrays.
Similar to ......rather than having an internal array and returning a reference to that.
Then it is possible to start calculating the `jl` and `ylm` arrays for a new batch of atoms while `alm_add_atoms` is still using the previous arrays.
Similar to numpy functions, it should also be possible to pass an 'out' array.https://git.embl.de/grp-svergun/galumph/-/issues/18Separate Alm class from the atomic scattering kernel2018-03-14T17:59:25ZChris KerrSeparate Alm class from the atomic scattering kernelCurrently, when creating an Alm array, it also (re)compiles the CL kernel to add scattering from atoms with a given x,y,z and form factor, and initializes the array with zeros. The Alm class should be separate from this operation, to all...Currently, when creating an Alm array, it also (re)compiles the CL kernel to add scattering from atoms with a given x,y,z and form factor, and initializes the array with zeros. The Alm class should be separate from this operation, to allow e.g. returning an Alm from the ROTALM function (#6) or loading an Alm from a file (#1).Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/19Convenience interface to kernel functions2018-03-15T22:49:17ZChris KerrConvenience interface to kernel functionsAllow passing queue and/or out array, allocate a queue or array if none are passed.
This will probably require a utils module with some decorator functions.Allow passing queue and/or out array, allocate a queue or array if none are passed.
This will probably require a utils module with some decorator functions.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/22Load the CL source in the kernel class constructor2018-03-15T22:49:17ZChris KerrLoad the CL source in the kernel class constructor...not when loading the module....not when loading the module.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/24Bug in the spherical harmonic kernel2018-03-14T00:19:51ZChris KerrBug in the spherical harmonic kernelFound here: https://git.embl.de/grp-svergun/galumph/-/jobs/8781Found here: https://git.embl.de/grp-svergun/galumph/-/jobs/8781Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/25docker base image with dependencies installed for CI tests2019-02-17T20:12:21ZChris Kerrdocker base image with dependencies installed for CI testsThis should help to get the CI tests to run faster, because there is no need to wait for packages to install.This should help to get the CI tests to run faster, because there is no need to wait for packages to install.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/26Add a style checker e.g. flake82020-05-22T03:49:47ZChris KerrAdd a style checker e.g. flake8Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/31Many hypothesis deadline warnings in the CI tests2019-02-17T21:20:29ZChris KerrMany hypothesis deadline warnings in the CI testsRunning the CL code in pocl on Docker isn't very fast.
Add `@settings(deadline=...)` decorators to the testsRunning the CL code in pocl on Docker isn't very fast.
Add `@settings(deadline=...)` decorators to the testshttps://git.embl.de/grp-svergun/galumph/-/issues/35crash with pocl on CI server - DominatorTree is not up to date2020-05-21T05:21:58ZChris Kerrcrash with pocl on CI server - DominatorTree is not up to dateNot sure what is causing this, for the moment I have just disabled the tests that crash.Not sure what is causing this, for the moment I have just disabled the tests that crash.https://git.embl.de/grp-svergun/galumph/-/issues/37Remove Python 2 support2020-05-23T06:53:32ZChris KerrRemove Python 2 supportPython 2 will reach end-of-life at the end of 2019.
We should remove Python 2 from the list of environments to test.Python 2 will reach end-of-life at the end of 2019.
We should remove Python 2 from the list of environments to test.Release PyPI packageChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/38Do not require Fortran compiler / f2py for Wigner 3j symbols2020-05-27T03:48:46ZChris KerrDo not require Fortran compiler / f2py for Wigner 3j symbolsEither:
* Add a pure Python implementation
* Use an external libraryEither:
* Add a pure Python implementation
* Use an external libraryRelease PyPI packageChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/40Compatibility with new hypothesis version2019-02-17T21:20:29ZChris KerrCompatibility with new hypothesis versionSee failed test here: https://git.embl.de/grp-svergun/galumph/-/jobs/22075
* Remove `max_iterations` setting
* Specify extended deadline for any tests taking longer than 200 msSee failed test here: https://git.embl.de/grp-svergun/galumph/-/jobs/22075
* Remove `max_iterations` setting
* Specify extended deadline for any tests taking longer than 200 msChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/48Change the Ylm and Jl kernels back to being single-atom only2019-05-12T12:14:42ZChris KerrChange the Ylm and Jl kernels back to being single-atom onlyThis will reduce the amount of faff required for endianness compatibility as well as making the functions simpler.
To feed data to alm_add_many_atoms, invoke the Ylm and Jl kernels several times on separate sub-buffers of the same region.This will reduce the amount of faff required for endianness compatibility as well as making the functions simpler.
To feed data to alm_add_many_atoms, invoke the Ylm and Jl kernels several times on separate sub-buffers of the same region.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/49Use 'faulthandler' to give better information when tests segfault2020-05-22T03:53:44ZChris KerrUse 'faulthandler' to give better information when tests segfaulte.g. using the 'pytest-faulthandler' package
See also this blog post: https://pythonspeed.com/articles/python-c-extension-crashes/e.g. using the 'pytest-faulthandler' package
See also this blog post: https://pythonspeed.com/articles/python-c-extension-crashes/Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/51Add SPDX / fsfe-reuse metadata2020-05-23T08:03:53ZChris KerrAdd SPDX / fsfe-reuse metadataAdd machine-parsable metadata for copyright and licensing.
https://reuse.software/
https://github.com/fsfe/reuse-docs/Add machine-parsable metadata for copyright and licensing.
https://reuse.software/
https://github.com/fsfe/reuse-docs/Release PyPI packageChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/52Update base image to Debian 102020-05-20T17:54:16ZChris KerrUpdate base image to Debian 10Update the base image to Debian 10 to get more recent versions of dependencies.Update the base image to Debian 10 to get more recent versions of dependencies.Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/53Tests fail with latest Hypothesis 5.152020-05-20T05:10:19ZChris KerrTests fail with latest Hypothesis 5.15Job [#37759](https://git.embl.de/grp-svergun/galumph/-/jobs/37759) failed for 8122627a5f202db6b9f30c901f7a6e4da6cb6b85:
```
=========================== short test summary info ============================
FAILED test/test_atomic_scatter...Job [#37759](https://git.embl.de/grp-svergun/galumph/-/jobs/37759) failed for 8122627a5f202db6b9f30c901f7a6e4da6cb6b85:
```
=========================== short test summary info ============================
FAILED test/test_atomic_scattering.py::test_single_multiple - hypothesis.erro...
FAILED test/test_atomic_scattering.py::test_reorder_atoms - hypothesis.errors...
FAILED test/test_bessel.py::test_multiple - hypothesis.errors.InvalidArgument...
FAILED test/test_intensity.py::test_cross_intensity - hypothesis.errors.Inval...
FAILED test/test_intensity.py::test_Guinier - hypothesis.errors.InvalidArgume...
FAILED test/test_sphharm.py::test_multiple - hypothesis.errors.InvalidArgumen...
FAILED test/test_zshift.py::test_zshift - hypothesis.errors.InvalidArgument: ...
============= 7 failed, 7 passed, 3 skipped, 8 warnings in 29.51s ==============
```Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/54pocl: Could not find a dominating alternative variable2020-05-21T05:22:39ZChris Kerrpocl: Could not find a dominating alternative variableJob [#37915](https://git.embl.de/grp-svergun/galumph/-/jobs/37915) failed for ddf35fa2f5c7d77ee902ade8bd5b6e8882679a83:Job [#37915](https://git.embl.de/grp-svergun/galumph/-/jobs/37915) failed for ddf35fa2f5c7d77ee902ade8bd5b6e8882679a83:Chris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/55Update package metadata for PyPI2020-05-26T19:31:48ZChris KerrUpdate package metadata for PyPIRelease PyPI packageChris KerrChris Kerrhttps://git.embl.de/grp-svergun/galumph/-/issues/59Tests fail with TypeError on recent Python / Numpy2022-09-14T17:23:36ZChris KerrTests fail with TypeError on recent Python / Numpy```
______________________________________________________________________ test_zshift_0 _______________________________________________________________________
cl_context = <pyopencl.Context at 0x12bca05f0 on <pyopencl.Device 'pthread-...```
______________________________________________________________________ test_zshift_0 _______________________________________________________________________
cl_context = <pyopencl.Context at 0x12bca05f0 on <pyopencl.Device 'pthread-POWER9, altivec supported' on 'Portable Computing Language' at 0x12bc229f0>>
cl_shzmat = cl.Array([ 1.0000000e+00, 1.7320508e+00, 1.0000000e+00, ...,
3.9918969e-08, -2.0758608e-09, 5.2570500e-11], dtype=float32)
@settings(max_examples=10)
> @given(
almparams=alm_parameters(
# Need a reasonable LMAX to get accurate results
LMAX=st.integers(min_value=10, max_value=LMAX_TEST),
worksize=st.integers(min_value=1, max_value=16),
),
xyz_ff=atom_xyzf(),
)
test/test_zshift.py:83:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
test/test_zshift.py:108: in test_zshift_0
np_alm_orig = alm_orig.get(unpack=True)
.venv/lib/python3.10/site-packages/galumph/almarray.py:42: in get
ary[L, 0:L+1, :] = self[packed_range, :].get(queue=queue, **kwargs)
/usr/lib/python3.10/site-packages/pyopencl/array.py:2081: in __getitem__
return self._new_with_changes(
/usr/lib/python3.10/site-packages/pyopencl/array.py:642: in _new_with_changes
return self.__class__(None, shape, dtype, allocator=allocator,
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <[AttributeError("'AlmArray' object has no attribute 'queue'") raised in repr()] AlmArray object at 0x3fff0e644460>, cq = None, LMAX = (1, 4)
NS = dtype('complex64'), dtype = 'c8'
kwargs = {'_context': <pyopencl.Context at 0x12bca05f0 on <pyopencl.Device 'pthread-POWER9, altivec supported' on 'Portable Com...' at 0x12bc229f0>>, '_fast': False, '_queue': <pyopencl._cl.CommandQueue object at 0x3fff0e6b01d0>, '_size': None, ...}
def __init__(self, cq, LMAX, NS, dtype='c8', **kwargs):
"""Work out the shape from LMAX and call the superclass constructor."""
> assert LMAX >= 0
E TypeError: '>=' not supported between instances of 'tuple' and 'int'
E Falsifying example: test_zshift_0(
E almparams={'LMAX': 10,
E 's': array([0. , 0.33333333, 0.66666667, 1. ]),
E 'worksize': 1,
E 'natwork': 4},
E xyz_ff=(array([[0., 0., 0.]], dtype=float32), array([1.], dtype=float32)),
E cl_context=<pyopencl.Context at 0x12bca05f0 on <pyopencl.Device 'pthread-POWER9, altivec supported' on 'Portable Computing Language' at 0x12bc229f0>>,
E cl_shzmat=cl.Array([ 1.0000000e+00, 1.7320508e+00, 1.0000000e+00, ...,
E 3.9918969e-08, -2.0758608e-09, 5.2570500e-11], dtype=float32),
E )
.venv/lib/python3.10/site-packages/galumph/almarray.py:20: TypeError
```Chris KerrChris Kerr