3 #include <torch/csrc/python_headers.h> 6 #include <torch/csrc/THP_export.h> 14 #define THPGenerator_Check(obj) \ 15 PyObject_IsInstance(obj, THPGeneratorClass) 17 #define THPGenerator_TH_CData(obj) \ 18 (THGenerator*)((THPGenerator*)obj)->cdata->unsafeGetTH() 20 THP_API PyObject * THPGenerator_New();
25 THP_API PyObject * THPGenerator_NewWithGenerator(
at::Generator& cdata);
27 THP_API PyObject *THPGeneratorClass;
30 bool THPGenerator_init(PyObject *module);