zzd1992:

I am not familiar with PackedTensorAccessors and I can’t find related topics on the Internet. Can you provide an example of how to use it or some related materials?


I should SEO optimize my blog more (it’s the second item on DuckDuckGo, but not on the first page at Google)  . My blog post on a Sinkhorn kernel uses and comments on them 2 with a full code example.
I also used them for PyTorch’s own batch norm implementation. That and the C++ extension tutoral have the latest refactoring with packed_accessor32 (32 bit indexing is much faster on CUDA than 64 bit).
Best regards
Thomas