triton.language.flip

triton.language.flip(x, dim=None)

沿维度 dim 翻转张量 x

参数:
  • x (Block) – 第一个输入张量

  • dim (int) – 要翻转的维度

此函数也可以作为 tensor 的成员函数调用,例如 x.flip(...) 而不是 flip(x, ...)