You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I recently tried to use gpyfft on following setup:
CPU - ARMv7, 32bits
Debian: Linux tinkerboard 4.4.103+ #1 SMP Fri Jun 22 16:14:49 CST 2018 armv7l GNU/Linux
Python 3.5.3
Cython 0.29.15
Pyopencl 2019.1.2
I installed libclfft and build gpyfft in following way:
python3 setup.py build
python3 setup.py install
After that I tried to run simple_example.py from examples directory and I received: Traceback (most recent call last):
File "simple_example.py", line 13, in
transform = FFT(context, queue, data_gpu, axes = (2, 1))
File "/usr/local/lib/python3.5/dist-packages/gpyfft-0.7.3-py3.5-linux-armv7l.egg/gpyfft/fft.py", line 93, in init
plan = GFFT.create_plan(context, t_shape)
File "gpyfft/gpyfftlib.pyx", line 142, in gpyfft.gpyfftlib.GpyFFT.create_plan
File "gpyfft/gpyfftlib.pyx", line 219, in gpyfft.gpyfftlib.Plan.init
OverflowError: can't convert negative value to size_t
Can you, please, help me to fix this problem ?
Thanks
The text was updated successfully, but these errors were encountered:
Thanks for the report, that is a less common platform. I think you discovered a bug. Your fix is ok for your platform, I will try to find some platform independent solution. One possibility might be to use
ctypedef ptrdiff_t voidptr_t
Can you please test this and report back?
For the records: The problem arises when converting e.g. a OpenCL context reference (natively a void*) from pyopencl, where it is exposed as a (signed) Python int (int_ptr attribute), back to a void*. By any reason, a direct cast is not possible/allowed in cython, therefor an intermediate cast to some signed integer type of platform dependent size is needed. size_t is guaranteed to be large enough, but it is an unsigned integer type. ptrdiff_t is devised for signed arithmetic, but I am not sure if it has the right size on all platforms, could be longer. Don't know if that could create any harm.
Hi,
I recently tried to use gpyfft on following setup:
CPU - ARMv7, 32bits
Debian: Linux tinkerboard 4.4.103+ #1 SMP Fri Jun 22 16:14:49 CST 2018 armv7l GNU/Linux
Python 3.5.3
Cython 0.29.15
Pyopencl 2019.1.2
I installed libclfft and build gpyfft in following way:
python3 setup.py build
python3 setup.py install
After that I tried to run simple_example.py from examples directory and I received:
Traceback (most recent call last):
File "simple_example.py", line 13, in
transform = FFT(context, queue, data_gpu, axes = (2, 1))
File "/usr/local/lib/python3.5/dist-packages/gpyfft-0.7.3-py3.5-linux-armv7l.egg/gpyfft/fft.py", line 93, in init
plan = GFFT.create_plan(context, t_shape)
File "gpyfft/gpyfftlib.pyx", line 142, in gpyfft.gpyfftlib.GpyFFT.create_plan
File "gpyfft/gpyfftlib.pyx", line 219, in gpyfft.gpyfftlib.Plan.init
OverflowError: can't convert negative value to size_t
Can you, please, help me to fix this problem ?
Thanks
The text was updated successfully, but these errors were encountered: