MathBitFallThroughLists.h 4.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. #pragma once
  2. namespace at {
  3. // views and their in-place version ops
  4. #define TORCH_VIEW_FNS(m) \
  5. m.impl("as_strided_", torch::CppFunction::makeFallthrough()); \
  6. m.impl("detach", torch::CppFunction::makeFallthrough()); \
  7. m.impl("detach_", torch::CppFunction::makeFallthrough()); \
  8. m.impl("diagonal", torch::CppFunction::makeFallthrough()); \
  9. m.impl("expand", torch::CppFunction::makeFallthrough()); \
  10. m.impl("expand_as", torch::CppFunction::makeFallthrough()); \
  11. m.impl("movedim.int", torch::CppFunction::makeFallthrough()); \
  12. m.impl("movedim.intlist", torch::CppFunction::makeFallthrough()); \
  13. m.impl("narrow", torch::CppFunction::makeFallthrough()); \
  14. m.impl("permute", torch::CppFunction::makeFallthrough()); \
  15. m.impl("select.Dimname", torch::CppFunction::makeFallthrough()); \
  16. m.impl("select.int", torch::CppFunction::makeFallthrough()); \
  17. m.impl("squeeze", torch::CppFunction::makeFallthrough()); \
  18. m.impl("squeeze_", torch::CppFunction::makeFallthrough()); \
  19. m.impl("transpose.int", torch::CppFunction::makeFallthrough()); \
  20. m.impl("transpose.Dimname", torch::CppFunction::makeFallthrough()); \
  21. m.impl("transpose_", torch::CppFunction::makeFallthrough()); \
  22. m.impl("t", torch::CppFunction::makeFallthrough()); \
  23. m.impl("t_", torch::CppFunction::makeFallthrough()); \
  24. m.impl("real", torch::CppFunction::makeFallthrough()); \
  25. m.impl("imag", torch::CppFunction::makeFallthrough()); \
  26. m.impl("view_as_real", torch::CppFunction::makeFallthrough()); \
  27. m.impl("unflatten.int", torch::CppFunction::makeFallthrough()); \
  28. m.impl("unflatten.Dimname", torch::CppFunction::makeFallthrough()); \
  29. m.impl("unfold", torch::CppFunction::makeFallthrough()); \
  30. m.impl("unsqueeze", torch::CppFunction::makeFallthrough()); \
  31. m.impl("unsqueeze_", torch::CppFunction::makeFallthrough()); \
  32. m.impl("view_as", torch::CppFunction::makeFallthrough()); \
  33. m.impl("unbind.int", torch::CppFunction::makeFallthrough()); \
  34. m.impl("unbind.Dimname", torch::CppFunction::makeFallthrough()); \
  35. m.impl("split.Tensor", torch::CppFunction::makeFallthrough()); \
  36. m.impl("split_with_sizes", torch::CppFunction::makeFallthrough()); \
  37. m.impl("swapaxes", torch::CppFunction::makeFallthrough()); \
  38. m.impl("swapdims", torch::CppFunction::makeFallthrough()); \
  39. m.impl("chunk", torch::CppFunction::makeFallthrough()); \
  40. m.impl("reshape", torch::CppFunction::makeFallthrough()); \
  41. m.impl("alias", torch::CppFunction::makeFallthrough()); \
  42. m.impl("hsplit.int", torch::CppFunction::makeFallthrough()); \
  43. m.impl("hsplit.array", torch::CppFunction::makeFallthrough()); \
  44. m.impl("dsplit.int", torch::CppFunction::makeFallthrough()); \
  45. m.impl("dsplit.array", torch::CppFunction::makeFallthrough()); \
  46. m.impl("vsplit.int", torch::CppFunction::makeFallthrough()); \
  47. m.impl("vsplit.array", torch::CppFunction::makeFallthrough()); \
  48. m.impl("conj", torch::CppFunction::makeFallthrough()); \
  49. m.impl("_conj", torch::CppFunction::makeFallthrough()); \
  50. m.impl("_unsafe_view", torch::CppFunction::makeFallthrough()); \
  51. m.impl("resize_", torch::CppFunction::makeFallthrough());
  52. #define TENSOR_UTILITIES_AND_CONSTRUCTORS(m) \
  53. m.impl("empty_like", torch::CppFunction::makeFallthrough()); \
  54. m.impl("empty.memory_format", torch::CppFunction::makeFallthrough()); \
  55. m.impl("empty.out", torch::CppFunction::makeFallthrough()); \
  56. m.impl("empty_strided", torch::CppFunction::makeFallthrough()); \
  57. m.impl("full_like", torch::CppFunction::makeFallthrough()); \
  58. m.impl("stride.int", torch::CppFunction::makeFallthrough()); \
  59. m.impl("stride.Dimname", torch::CppFunction::makeFallthrough()); \
  60. m.impl("size.int", torch::CppFunction::makeFallthrough()); \
  61. m.impl("size.Dimname", torch::CppFunction::makeFallthrough()); \
  62. m.impl("is_complex", torch::CppFunction::makeFallthrough()); \
  63. m.impl("is_floating_point", torch::CppFunction::makeFallthrough()); \
  64. m.impl("requires_grad_", torch::CppFunction::makeFallthrough());
  65. }
  66. #define TORCH_VIEW_FNS_NATIVE_FN_REGISTRATION(m) \
  67. m.impl("as_strided", torch::CppFunction::makeFallthrough()); \
  68. m.impl("view", torch::CppFunction::makeFallthrough());