Calling CUDA kernels from Python This is a full example of how to call CUDA kernels from Python with C Extensions. Notes This example is targeting Python 2.x. It is based on Robert's answer on StackOverflow. This example also used another compiler (PGI compiler) to show how to compile with another compiler.