There’s a new C++ extension interface, coming in Pytorch 0.4 (and currently on master). Here are the docs for it 58. You can’t write CUDA extensions yet, but C++ extensions with our ATen backend work.