check_sm_version Class — pytorch Architecture
Architecture documentation for the check_sm_version class in sdp_utils.cpp from the pytorch codebase.
Entity Profile
Source Code
aten/src/ATen/native/transformers/cuda/sdp_utils.cpp lines 287–296
template <typename lower_bound, typename upper_bound>
bool check_sm_version(cudaDeviceProp * dprops) {
bool is_gte_lower_bound = dprops->major > lower_bound::major ||
(dprops->major == lower_bound::major &&
dprops->minor >= lower_bound::minor);
bool is_lte_upper_bound = dprops->major < upper_bound::major ||
(dprops->major == upper_bound::major &&
dprops->minor <= upper_bound::minor);
return is_gte_lower_bound && is_lte_upper_bound;
}
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free