Hello,
I’m trying to pass a “cuda event” from python to cpp function, but I’m getting an error.
torch version is 1.13.0a0+d0d6b1f.
python code
event = torch.cuda.Event()
my_fn(event)
c++ code
void my_fn(at::cuda::CUDAEvent event){
...
}
err msg.
/opt/conda/lib/python3.8/site-packages/torch/include/pybind11/cast.h:1441:37: error: use of deleted function ‘at::cuda::CUDAEvent::CUDAEvent(const at::cuda::CUDAEvent&)’
Is there any other way to pass “cuda event” from python to cpp?
Thanks in advance!