I can use the various TH/THC routines with a C-api by passing a void pointer,
e.g.
THFloatTensor *t=THFloatTensor_new();
THFloatTensor_resizeNd(t, dim, sizes);
void *v=t;
but I can’t figure out how to pass a pointer back and forth with the higher-level ATen Tensor,
e.g.
Tensor t=CPU(kFloat).ones({3, 4});
void *p=&t;
either this is incorrect, or my tensor is out of scope so that i can no longer reference it on the other side of the C-api, or I need to increment it’s reference or…?
Thanks