Download src/utils/arithmetic.h from replicate/gemm: direct link, hf CLI and curl.
- Browser
- Download file 295 Bytes
-
https://huggingface.co/replicate/gemm/resolve/main/src/utils/arithmetic.h
- Command line
-
hf download hf://replicate/gemm/src/utils/arithmetic.h
-
curl -L -o arithmetic.h https://huggingface.co/replicate/gemm/resolve/main/src/utils/arithmetic.h
295 Bytes
| template <int x, int y> constexpr __device__ __host__ inline int exact_div() { | |
| static_assert(x % y == 0); | |
| static_assert(x >= y); | |
| return x / y; | |
| } | |
| constexpr __device__ __host__ inline int ceil_div(int x, int y) { return (x + y - 1) / y; } | |