Hi,
In the official C++/CUDA extension tutorial (GitHub - pytorch/extension-cpp: C++ extensions in PyTorch),  setup.py only installs the c++ part of the extension into python’s site-packages directory, leaving the lltm.py wrapper file in local directory.
For usage, we will have to refer to this lltm.py file locally (e.g. import cuda.lltm as LLTM, where cuda is the local folder name), which is not ideal for package distribution.
Is there a way to include lltm.py into the extension installation as well?
The setup.py for cuda version looks like this:
from setuptools import setup
from torch.utils.cpp_extension import BuildExtension, CUDAExtension

setup(
    name='lltm_cuda',
    ext_modules=[
        CUDAExtension('lltm_cuda', [
            'lltm_cuda.cpp',
            'lltm_cuda_kernel.cu',
        ]),
    ],
    cmdclass={
        'build_ext': BuildExtension
    })

Thanks!