Home / Class/ fmod Class — pytorch Architecture

fmod Class — pytorch Architecture

Architecture documentation for the fmod class in vec_base.h from the pytorch codebase.

Entity Profile

Source Code

aten/src/ATen/cpu/vec/vec_base.h lines 553–564

  template <
      typename U = T,
      typename std::enable_if_t<is_floating_point_v<U>, int> = 0>
  Vectorized<T> fmod(const Vectorized<T>& q) const {
    // U is for SFINAE purposes only. Make sure it is not changed.
    static_assert(std::is_same_v<U, T>, "U must be T");
    Vectorized<T> ret;
    for (const auto i : c10::irange(size())) {
      ret[i] = std::fmod(values[i], q[i]);
    }
    return ret;
  }

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free