Giter Site home page Giter Site logo

Cannot run same script twice. about pyopencl HOT 7 CLOSED

inducer avatar inducer commented on May 18, 2024
Cannot run same script twice.

from pyopencl.

Comments (7)

yuyichao avatar yuyichao commented on May 18, 2024

Can you try a lower version of beignet? e.g. 0.9

from pyopencl.

decabyte avatar decabyte commented on May 18, 2024

Yes, my fault. I didn't installed the right beignet version, with 0.8.1 no problems with the examples. First time without a warming Nvidia under PyOpenCL. :)

It is worth noticing that the version shipped with Ubuntu 14.04 is very old, 0.3.1-1.

Any recommendation for using the right version on different machines? Better to compile beignet from source checking out a specific version everytime or relying on other packages? Maybe the Debian / Ubuntu+1 ones?

$ python benchmark.py 
Execution time of test without OpenCL:  0.0580661296844 s
===============================================================
Platform name: Experiment Intel Gen OCL Driver
Platform profile: FULL_PROFILE
Platform vendor: Intel
Platform version: OpenCL 1.1 beignet 0.8.0
---------------------------------------------------------------
Device name: Intel(R) HD Graphics IvyBridge M GT2
Device type: GPU
Device memory:  128 MB
Device max clock speed: 1000 MHz
Device compute units: 128
Device max work group size: 1024
Device max work item sizes: [512, 512, 512]
Data points: 8388608
Workers: 256
Preferred work group size multiple: 16
Execution time of test: 0.191544 s
Results OK

from pyopencl.

yuyichao avatar yuyichao commented on May 18, 2024

My local beignet version is 3 commit ahead of 0.9.1 and it runs without problems. If you found a commit that breaks pyopencl I think you should report to beignet with the bad commit you are on.

from pyopencl.

yuyichao avatar yuyichao commented on May 18, 2024

Also, I'm supprised that beignet <= 0.9.1 works at all from a binary package since it is only recently that beignet can work on a different architecture it is compiled on. (i.e. if you want to run it on IveBridge CPU, beignet had to be compiled on that CPU as well).
I would recommand using the latest git master or at least >= 0.9.2 since it is the first release which use llvm bytecode at compile time.

from pyopencl.

decabyte avatar decabyte commented on May 18, 2024

Thanks @yuyichao I'll compile the latest git master asap. Given the OS release I'll try the LLVM/clang 3.4 stack as it is shipped by default on 14.04.

What about the git mesa local repo? It is a required dependency for using pyopencl and beignet successfully?

from pyopencl.

yuyichao avatar yuyichao commented on May 18, 2024

There's a recent thread on a compiling problem on the beignet list and the reply seems to indicate that 10.1 should be fine. I'm not sure what's the officially supported versions but at least git master is not necessary. I have just compiled the latest beignet master with mesa 10.2.5 and it looks OK. I guess you should just test it with whatever mesa version you have and report to beignet list if it fails to figure out whether it is possible to support the version you have (I guess any recent versions should be fine).

from pyopencl.

decabyte avatar decabyte commented on May 18, 2024

Yes, the 0.9.2+ seems to works much better. I've compiled with the latest Intel Graphics stack for Ubuntu 14.04 which brings Mesa 10.2.2. Compilation is fine and the only missing part is the cl_khr_gl_sharing cause I didn't rebuild Mesa.

$ python benchmark.py 
Execution time of test without OpenCL:  0.0574040412903 s
===============================================================
Platform name: Intel Gen OCL Driver
Platform profile: FULL_PROFILE
Platform vendor: Intel
Platform version: OpenCL 1.2 beignet 0.9
---------------------------------------------------------------
Device name: Intel(R) HD Graphics IvyBridge M GT2
Device type: GPU
Device memory:  1024 MB
Device max clock speed: 1000 MHz
Device compute units: 16
Device max work group size: 1024
Device max work item sizes: [1024, 1024, 1024]
Data points: 8388608
Workers: 256
Preferred work group size multiple: 16
Execution time of test: 0.0121039 s
Results OK

from pyopencl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.