mask_scatter_add Class — pytorch Architecture
Architecture documentation for the mask_scatter_add class in GridSamplerKernel.cpp from the pytorch codebase.
Entity Profile
Source Code
aten/src/ATen/native/cpu/GridSamplerKernel.cpp lines 443–456
template<typename scalar_t>
inline void
mask_scatter_add(const scalar_t *src, scalar_t* base_addr,
const int_same_size_t<scalar_t> *offsets,
const int_same_size_t<scalar_t> *mask, int64_t len) {
#if !defined(_MSC_VER) && !defined(COMPILING_FOR_MIN_SIZE)
# pragma unroll
#endif
for (const auto i : c10::irange(len)) {
if (mask[i] & 0x01) {
base_addr[offsets[i]] += src[i];
}
}
}
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free