10403

OpenCL programming using Python syntax

Massimo Di Pierro
School of Computing, DePaul University, Chicago IL 60604, USA
Third International Conference on Computer Science, Engineering & Applications (ICCSEA), 2013

@article{di2013opencl,

   title={OpenCL programming using Python syntax},

   author={Di Pierro, Massimo},

   year={2013}

}

Download Download (PDF)   View View   Source Source   Source codes Source codes

Package:

2606

views

We describe ocl, a Python library built on top of pyOpenCL and numpy. It allows programming GPU devices using Python. Python functions which are marked up using the provided decorator, are converted into C99/OpenCL and compiled using the JIT at runtime. This approach lowers the barrier to entry to programming GPU devices since it requires only Python syntax and no external compilation or linking steps. The resulting Python program runs even if a GPU is not available. As an example of application, we solve the problem of computing the covariance matrix for historical stock prices and determining the optimal portfolio according to Modern Portfolio Theory.
No votes yet.
Please wait...

* * *

* * *

HGPU group © 2010-2024 hgpu.org

All rights belong to the respective authors

Contact us: