pytorch/extension-cpp
Example C++ and CUDA extensions for PyTorch demonstrating custom op implementation using ATen/LibTorch APIs.

Velocity · 7d
+0.4
★ / day
Trend
→steady
star history
This repository provides two reference implementations of PyTorch custom operations written in C++ and CUDA. The extensions demonstrate both the standard ATen/LibTorch API and the newer Stable ABI approach for writing version-compatible custom ops. Both examples implement a simple mymuladd operation with CPU and CUDA kernels, serving as boilerplate for developers wanting to extend PyTorch’s backend with custom kernels.