Download core/math.hpp from RedHatAI/quantization: direct link, hf CLI and curl.
- Browser
- Download file 183 Bytes
-
https://huggingface.co/RedHatAI/quantization/resolve/613a8740fe235de0cdda3afb8bcaf28f13dd90bb/core/math.hpp
- Command line
-
hf download hf://RedHatAI/quantization@613a8740fe235de0cdda3afb8bcaf28f13dd90bb/core/math.hpp
-
curl -L -o math.hpp https://huggingface.co/RedHatAI/quantization/resolve/613a8740fe235de0cdda3afb8bcaf28f13dd90bb/core/math.hpp
183 Bytes
| inline uint32_t next_pow_2(uint32_t const num) { | |
| if (num <= 1) return num; | |
| return 1 << (CHAR_BIT * sizeof(num) - __builtin_clz(num - 1)); | |
| } |