Should be fixed in eb1182a.
Andreas
Sean Lynch <seanl(a)literati.org> writes:
> There is something very strange going on, because I cannot see any
> difference between how create_from_gl_buffer and create_from_gl_texture are
> declared, and yet:
>
> seanl@michiru ~/project/voxel (git)-[master] % python noisetest.py
>
>
> Traceback (most recent call last):
> File "noisetest.py", line 8, in <module>
> import pyopencl as cl
> File
> "/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/__init__.py",
> line 35, in <module>
> import pyopencl.cffi_cl as _cl
> File
> "/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/cffi_cl.py",
> line 36, in <module>
> from pyopencl._cffi import ffi as _ffi
> ImportError:
> /home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/_
> cffi.cpython-35m-x86_64-linux-gnu.so: undefined symbol:
> create_from_gl_texture
>
> From nm on the module:
>
> 0000000000044f30 T create_from_gl_buffer
> 00000000000453f0 T create_from_gl_renderbuffer
> U create_from_gl_texture
> 0000000000041970 T create_image_2d
> 00000000000423a0 T create_image_3d
>
> There is, however, a mangled version of create_from_gl_texture, and NOT for
> create_from_gl_buffer:
>
> 0000000000044a00 T _Z22create_from_gl_texturePP6clbaseS0_mjij
>
>
>
> On Mon, Mar 28, 2016 at 10:16 AM, Sean Lynch <seanl(a)literati.org> wrote:
>
>> Fantastic. I'll try it out after I put the kids to bed tonight (California
>> time). And I'm happy to contribute tests.
>>
>> On Mon, Mar 28, 2016 at 10:10 AM, Andreas Kloeckner <
>> lists(a)informa.tiker.net> wrote:
>>
>>> Sean Lynch <seanl(a)literati.org> writes:
>>>
>>> > Beignet doesn't support clCreateFromGLBuffer, but it does support
>>> > clCreateFromGLTexture. PyOpenCL supports clCreateFromGLBuffer, but I get
>>> > NotImplementedError for GLTexture. Does anyone know what needs to be
>>> done
>>> > to make GLTexture work?
>>>
>>> I've made a preliminary implementation:
>>>
>>> https://github.com/pyopencl/pyopencl/commit/de58fbc6dac05428883e64e04dbf802…
>>>
>>> Could you please submit some code that can be used to test it? (ideally
>>> as a patch/PR to the test suite)
>>>
>>> Thanks!
>>> Andreas
>>>
>>
>>
Incidentally, I also get that error using "python setup.py test" in the
pyopencl source directory.
On Mon, Mar 28, 2016 at 6:31 PM, Sean Lynch <seanl(a)literati.org> wrote:
> There is something very strange going on, because I cannot see any
> difference between how create_from_gl_buffer and create_from_gl_texture are
> declared, and yet:
>
> seanl@michiru ~/project/voxel (git)-[master] % python noisetest.py
>
>
> Traceback (most recent call last):
> File "noisetest.py", line 8, in <module>
> import pyopencl as cl
> File
> "/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/__init__.py",
> line 35, in <module>
> import pyopencl.cffi_cl as _cl
> File
> "/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/cffi_cl.py",
> line 36, in <module>
> from pyopencl._cffi import ffi as _ffi
> ImportError:
> /home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/_
> cffi.cpython-35m-x86_64-linux-gnu.so: undefined symbol:
> create_from_gl_texture
>
> From nm on the module:
>
> 0000000000044f30 T create_from_gl_buffer
> 00000000000453f0 T create_from_gl_renderbuffer
> U create_from_gl_texture
> 0000000000041970 T create_image_2d
> 00000000000423a0 T create_image_3d
>
> There is, however, a mangled version of create_from_gl_texture, and NOT
> for create_from_gl_buffer:
>
> 0000000000044a00 T _Z22create_from_gl_texturePP6clbaseS0_mjij
>
>
>
> On Mon, Mar 28, 2016 at 10:16 AM, Sean Lynch <seanl(a)literati.org> wrote:
>
>> Fantastic. I'll try it out after I put the kids to bed tonight
>> (California time). And I'm happy to contribute tests.
>>
>> On Mon, Mar 28, 2016 at 10:10 AM, Andreas Kloeckner <
>> lists(a)informa.tiker.net> wrote:
>>
>>> Sean Lynch <seanl(a)literati.org> writes:
>>>
>>> > Beignet doesn't support clCreateFromGLBuffer, but it does support
>>> > clCreateFromGLTexture. PyOpenCL supports clCreateFromGLBuffer, but I
>>> get
>>> > NotImplementedError for GLTexture. Does anyone know what needs to be
>>> done
>>> > to make GLTexture work?
>>>
>>> I've made a preliminary implementation:
>>>
>>> https://github.com/pyopencl/pyopencl/commit/de58fbc6dac05428883e64e04dbf802…
>>>
>>> Could you please submit some code that can be used to test it? (ideally
>>> as a patch/PR to the test suite)
>>>
>>> Thanks!
>>> Andreas
>>>
>>
>>
>
There is something very strange going on, because I cannot see any
difference between how create_from_gl_buffer and create_from_gl_texture are
declared, and yet:
seanl@michiru ~/project/voxel (git)-[master] % python noisetest.py
Traceback (most recent call last):
File "noisetest.py", line 8, in <module>
import pyopencl as cl
File
"/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/__init__.py",
line 35, in <module>
import pyopencl.cffi_cl as _cl
File
"/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/cffi_cl.py",
line 36, in <module>
from pyopencl._cffi import ffi as _ffi
ImportError:
/home/seanl/project/voxel/pyenv/lib/python3.5/site-packages/pyopencl-2015.2.4-py3.5-linux-x86_64.egg/pyopencl/_
cffi.cpython-35m-x86_64-linux-gnu.so: undefined symbol:
create_from_gl_texture
>From nm on the module:
0000000000044f30 T create_from_gl_buffer
00000000000453f0 T create_from_gl_renderbuffer
U create_from_gl_texture
0000000000041970 T create_image_2d
00000000000423a0 T create_image_3d
There is, however, a mangled version of create_from_gl_texture, and NOT for
create_from_gl_buffer:
0000000000044a00 T _Z22create_from_gl_texturePP6clbaseS0_mjij
On Mon, Mar 28, 2016 at 10:16 AM, Sean Lynch <seanl(a)literati.org> wrote:
> Fantastic. I'll try it out after I put the kids to bed tonight (California
> time). And I'm happy to contribute tests.
>
> On Mon, Mar 28, 2016 at 10:10 AM, Andreas Kloeckner <
> lists(a)informa.tiker.net> wrote:
>
>> Sean Lynch <seanl(a)literati.org> writes:
>>
>> > Beignet doesn't support clCreateFromGLBuffer, but it does support
>> > clCreateFromGLTexture. PyOpenCL supports clCreateFromGLBuffer, but I get
>> > NotImplementedError for GLTexture. Does anyone know what needs to be
>> done
>> > to make GLTexture work?
>>
>> I've made a preliminary implementation:
>>
>> https://github.com/pyopencl/pyopencl/commit/de58fbc6dac05428883e64e04dbf802…
>>
>> Could you please submit some code that can be used to test it? (ideally
>> as a patch/PR to the test suite)
>>
>> Thanks!
>> Andreas
>>
>
>
Sean Lynch <seanl(a)literati.org> writes:
> Beignet doesn't support clCreateFromGLBuffer, but it does support
> clCreateFromGLTexture. PyOpenCL supports clCreateFromGLBuffer, but I get
> NotImplementedError for GLTexture. Does anyone know what needs to be done
> to make GLTexture work?
I've made a preliminary implementation:
https://github.com/pyopencl/pyopencl/commit/de58fbc6dac05428883e64e04dbf802…
Could you please submit some code that can be used to test it? (ideally
as a patch/PR to the test suite)
Thanks!
Andreas
Beignet doesn't support clCreateFromGLBuffer, but it does support
clCreateFromGLTexture. PyOpenCL supports clCreateFromGLBuffer, but I get
NotImplementedError for GLTexture. Does anyone know what needs to be done
to make GLTexture work?
I am very new to OpenCl, I am actually investigating if this is what I need. So if I ask something obvious please just point me where the information can be found. I installed pyopencl after some troubles. My OS is 10.10 (Yosemite) but I have XCode 7, which has the 10.11 SDK. So the install script did not find the SDK for the OS and crashed. The solution was easy, just to make a link to the 10.11 SDK with the right name. Then the first thing I did was to run the benchmark script. With the default settings, 256 workers, it failed with
LogicError: clenqueuendrangekernel failed: INVALID_WORK_GROUP_SIZE in the CPU section. If I skipped the CPU it ran just fine on my Radeon GPUs. I changed the number of workers to 128 and it ran just fine on the CPU. When I query the CPU OpenCL properties it says the maximum work group size is 1024, but it fails with 256. Is that normal? If yes why? I tried it on four different Macs, 24 core MacPro, 8 core iMac 5k, and two different 8 core MacBook Pros, with same result.
One more thing. There are couple of problems with some of the examples.
narray fails on the CPU with clbuildprogram failed: BUILD_PROGRAM_FAILURE -
transpose fails on the CPU with clenqueuendrangekernel failed: INVALID_WORK_GROUP_SIZE after benchmarking Silly 7488 5.25572997632 GB/s
gl_interop fails with AttributeError: type object 'context_properties' has no attribute ‘CONTEXT_PROPERTY_USE_CGL_SHAREGROUP_APPLE in tools.py
gl_particle_animation.py fails with AttributeError: type object 'context_properties' has no attribute ‘CONTEXT_PROPERTY_USE_CGL_SHAREGROUP_APPLE’ then many more error messages are coming, and since the particle window cannot be closed I have to kill python.
Did things change between now when the examples were written?
Thanks for any help.
George
Gyorgy Vizkelethy
Sandia National Laboratories
Radiation-Solid Interactions
PO Box 5800, MS 1056
Albuquerque, NM 87185
USA
+1 (505) 284-3120
gvizkel(a)sandia.gov<mailto:gvizkel@sandia.gov>
Hi all,
I imagine that one of the main things that PyOpenCL and PyCUDA get used
for are computations with large arrays. As such, I can imagine that many
of you are sympathetic to the cause of trying to come up with simpler
abstractions that nonetheless yield high-performance code for such
computations.
ARRAY'16 is a workshop that concerns itself with programming language
aspects of computing with arrays, including language design,
compilation, libraries, and performance optimization. More information
on the workshop (including the full call for papers) may be found here:
http://conf.researchr.org/track/pldi-2016/ARRAY-2016
The workshop will be held June 14 in Santa Barbara, and the deadline for
submissions is April 1.
I would be delighted to see some submissions from the PyCUDA/PyOpenCL
crowd! (Disclaimer: I am on the organizing committee.)
Andreas
Hello again,
I have a muddy situation on my Ubuntu 14.04.
I have the AMDAPP sdk installed. I also have various nvidia drivers (352 is
in use) installed and I have cuda installed.
I'm trying to get pyopencl to use the nvidia gpu.
Running example opencl files from inside cuda works--ie, it finds the nvidia
device and can create a context. I can't get pyopencl to find the device.
My siteconf.py has the directories where the cuda includes and libOpenCL.so
reside. I looked at etc/vendors/nvidia.icd and it has libOpenCL.so but there
are at least two places where it could find libOpenCL.so, inside the AMD sdk
and the cuda, and I'm not sure how to tell it to go to the cuda one. Should I
create a symbolic link and point it to the cuda one, and put the name of the
symbolic link in the .icd? I also have a bunch of libOpenCL.so.1, .1.0,
.1.0.0 in various places, so I'd have to give it a unique name. I tried
putting the full path to the right .so but still get PLATFORM_NOT_FOUND_KHR.
Hi,
for a couple of days I am trying to install pyopencl (2014.1) on an Ubuntu machine (3.13.0.77, x86_64) as user (no root privileges).
When running
$ pip install —global-option=build_ext —global-option=„-I/opt/sw/cuda/include -L/opt/sw/cuda/lib64“ pyopencl==2014.1
the compiler throws
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -fwrapv -Wall -O3 -DNDEBUG -fPIC -DBOOST_PYTHON_SOURCE=1 -DPYGPU_PACKAGE=pyopencl -DPYOPENCL_USE_DEVICE_FISSION=1 -DBOOST_THREAD_DONT_USE_CHRONO=1 -DPYGPU_PYOPENCL=1 -DBOOST_MULTI_INDEX_DISABLE_SERIALIZATION=1 -DBOOST_THREAD_BUILD_DLL=1 -Dboost=pyopenclboost -DBOOST_ALL_NO_LIB=1 -Ibpl-subset/bpl_subset -I/opt/sw/cuda/include -L/opt/sw/cuda/lib64 -I/usr/include/python2.7 -c src/wrapper/wrap_cl.cpp -o build/temp.linux-x86_64-2.7/src/wrapper/wrap_cl.o
In file included from src/wrapper/wrap_cl.cpp:1:0:
src/wrapper/wrap_cl.hpp:28:19: fatal error: CL/cl.h: No such file or directory
#include <CL/cl.h>
The Cuda version is
Cuda compilation tools, release 7.0, V7.0.27
When compiling the package via setuptools it actually succeeds but i am unable to import pyopencl and instead getting the error:
>>>> import pyopencl
pyopencl/__init__.py:34: UserWarning: It looks like you are importing PyOpenCL from its source directory. This likely won't work.
warn("It looks like you are importing PyOpenCL from "
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "pyopencl/__init__.py", line 28, in <module>
import pyopencl._cl as _cl
ImportError: No module named _cl
My siteconf.py looked like
BOOST_INC_DIR = []
BOOST_LIB_DIR = []
BOOST_COMPILER = 'gcc43'
BOOST_PYTHON_LIBNAME = ['boost_python-py27']
USE_SHIPPED_BOOST = True
CL_TRACE = False
CL_ENABLE_GL = False
CL_ENABLE_DEVICE_FISSION = False
CL_INC_DIR = ['/opt/sw/cuda/include']
CL_LIB_DIR = ['/opt/sw/cuda/lib64']
CL_LIBNAME = ['OpenCL']
CXXFLAGS = []
LDFLAGS = []
What can I do? Any ideas what I can try?
Best Regards Jesse