|
| 1 | +- name: "Enable CUDA compilation on Cppyy-Numba generated IR" |
| 2 | + description: | |
| 3 | + Cppyy is an automatic, run-time, Python-C++ bindings generator, for calling |
| 4 | + C++ from Python and Python from C++. Initial support has been added that |
| 5 | + allows Cppyy to hook into the high-performance Python compiler, |
| 6 | + Numba which compiles looped code containing C++ objects/methods/functions |
| 7 | + defined via Cppyy into fast machine code. Since Numba compiles the code in |
| 8 | + loops into machine code it crosses the language barrier just once and avoids |
| 9 | + large slowdowns accumulating from repeated calls between the two languages. |
| 10 | + Numba uses its own lightweight version of the LLVM compiler toolkit (llvmlite) |
| 11 | + that generates an intermediate code representation (LLVM IR) which is also |
| 12 | + supported by the Clang compiler capable of compiling CUDA C++ code. |
| 13 | + |
| 14 | + The project aims to demonstrate Cppyy's capability to provide CUDA paradigms to |
| 15 | + Python users without any compromise in performance. Upon successful completion |
| 16 | + a possible proof-of-concept can be expected in the below code snippet - |
| 17 | + |
| 18 | + ```python |
| 19 | + import cppyy |
| 20 | + import cppyy.numba_ext |
| 21 | + |
| 22 | + cppyy.cppdef(''' |
| 23 | + __global__ void MatrixMul(float* A, float* B, float* out) { |
| 24 | + // kernel logic for matrix multiplication |
| 25 | + } |
| 26 | + ''') |
| 27 | +
|
| 28 | + @numba.njit |
| 29 | + def run_cuda_mul(A, B, out): |
| 30 | + # Allocate memory for input and output arrays on GPU |
| 31 | + # Define grid and block dimensions |
| 32 | + # Launch the kernel |
| 33 | + MatrixMul[griddim, blockdim](d_A, d_B, d_out) |
| 34 | + ``` |
| 35 | + tasks: | |
| 36 | + * Add support for declaration and parsing of Cppyy-defined CUDA code on |
| 37 | + the Numba extension. |
| 38 | + * Design and develop a CUDA compilation and execution mechanism. |
| 39 | + * Prepare proper tests and documentation. |
| 40 | +
|
| 41 | +- name: "Cppyy STL/Eigen - Automatic conversion and plugins for Python based ML-backends" |
| 42 | + description: | |
| 43 | + Cppyy is an automatic, run-time, Python-C++ bindings generator, for calling |
| 44 | + C++ from Python and Python from C++. Cppyy uses pythonized wrappers of useful |
| 45 | + classes from libraries like STL and Eigen that allow the user to utilize them |
| 46 | + on the Python side. Current support follows container types in STL like |
| 47 | + std::vector, std::map, and std::tuple and the Matrix-based classes in |
| 48 | + Eigen/Dense. These cppyy objects can be plugged into idiomatic expressions |
| 49 | + that expect Python builtin-types. This behaviour is achieved by growing |
| 50 | + pythonistic methods like `__len__` while also retaining its C++ methods |
| 51 | + like `size`. |
| 52 | + |
| 53 | + Efficient and automatic conversion between C++ and Python is essential |
| 54 | + towards high-performance cross-language support. This approach eliminates |
| 55 | + overheads arising from iterative initialization such as comma insertion in |
| 56 | + Eigen. This opens up new avenues for the utilization of Cppyy’s bindings in |
| 57 | + tools that perform numerical operations for transformations, or optimization. |
| 58 | + |
| 59 | + The on-demand C++ infrastructure wrapped by idiomatic Python enables new |
| 60 | + techniques in ML tools like JAX/CUTLASS. This project allows the C++ |
| 61 | + infrastructure to be plugged into at service to the users seeking |
| 62 | + high-performance library primitives that are unavailable in Python. |
| 63 | + |
| 64 | + tasks: | |
| 65 | + * Extend STL support for std::vectors of arbitrary dimensions |
| 66 | + * Improve the initialization approach for Eigen classes |
| 67 | + * Develop a streamlined interconversion mechanism between Python |
| 68 | + builtin-types, numpy.ndarray, and STL/Eigen data structures |
| 69 | + * Implement experimental plugins that perform basic computational |
| 70 | + operations in frameworks like JAX |
| 71 | + * Work on integrating these plugins with toolkits like CUTLASS that |
| 72 | + utilise the bindings to provide a Python API |
| 73 | +
|
1 | 74 | - name: "Enable cross-talk between Python and C++ kernels in xeus-clang-REPL by using Cppyy"
|
2 | 75 | description: |
|
3 | 76 | xeus-clang-REPL is a C++ kernel for Jupyter notebooks using clang-REPL as
|
|
0 commit comments