mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-05-20 17:22:09 +00:00
Adjust the round_up_seq
logic in Gaudi backend (#3224)
Signed-off-by: Liu, Kaixuan <kaixuan.liu@intel.com>
This commit is contained in:
parent
c94f415af4
commit
535ce23827
@ -73,7 +73,7 @@ def torch_compile_for_eager(func):
|
||||
|
||||
|
||||
def round_up_seq(number, k, base):
|
||||
exponent = math.ceil(math.log(number / k, base))
|
||||
exponent = max(0, math.ceil(math.log(number / k, base)))
|
||||
return int(k * (base**exponent))
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user