Giter Club home page Giter Club logo

Comments (4)

oysstu avatar oysstu commented on September 23, 2024

I have no idea why the first one fails. I get the following output

Using CPU: Intel(R) Core(TM) i5-4670K CPU @ 3.40GHz
On platform: Intel(R) CPU Runtime for OpenCL(TM) Applications (OpenCL 2.1 LINUX)

/usr/lib/python3.7/site-packages/pyopencl/cffi_cl.py:1517: CompilerWarning: From-source build succeeded, but resulted in non-empty logs:
Build on <pyopencl.Device 'Intel(R) Core(TM) i5-4670K CPU @ 3.40GHz' on 'Intel(R) CPU Runtime for OpenCL(TM) Applications' at 0x5637977efe08> succeeded, but said:

Compilation started
Compilation done
Linking started
Linking done
Device build started
Device build done
Kernel <mutex> was not vectorized
Done.
  warn(text, CompilerWarning)
Sum: [4]

I see you're using the experimental opencl 2.1 drivers, could be something related to that.

from pyopencl-in-action.

 avatar commented on September 23, 2024

I see - I do not want to use experimental. I have available those

<pyopencl.Platform 'Intel(R) OpenCL HD Graphics' at 0x556d29d9a370>
<pyopencl.Platform 'Experimental OpenCL 2.1 CPU Only Platform' at 0x556d299366d0>

but on "ch11.string_search" it fails where HD Graphics is used

(cl) ~/work/p1/pyopencl-in-action$ python -m "ch11.string_search"
Using GPU: Intel(R) Gen9 HD Graphics NEO
On platform: Intel(R) OpenCL HD Graphics (OpenCL 2.1)

Traceback (most recent call last):
  File "/home/ubuntu/anaconda3/envs/cl/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/ubuntu/anaconda3/envs/cl/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/ubuntu/work/p1/pyopencl-in-action/ch11/string_search.py", line 84, in <module>
    with open(TEXT_FILE, 'r') as f:
FileNotFoundError: [Errno 2] No such file or directory: 'kafka.txt'

from pyopencl-in-action.

oysstu avatar oysstu commented on September 23, 2024

That is a separate issue. It tries to open ch11/kafka.txt. I've pushed a new version that handles the path better, try that

from pyopencl-in-action.

 avatar commented on September 23, 2024

after update - it works ch11.string_search

(cl) ~/work/p1/pyopencl-in-action$ python -m "ch11.string_search"
Using GPU: Intel(R) Gen9 HD Graphics NEO
On platform: Intel(R) OpenCL HD Graphics (OpenCL 2.1)

Number of occurrences of 'that': 330
Number of occurrences of 'with': 237
Number of occurrences of 'have': 110
Number of occurrences of 'from': 116

from pyopencl-in-action.

Related Issues (7)

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.