mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-09-11 12:24:53 +00:00
Support CPU again.
This commit is contained in:
parent
c56df3b167
commit
361263afbf
@ -39,3 +39,12 @@ elif is_xpu_available():
|
||||
empty_cache = torch.xpu.empty_cache
|
||||
synchronize = torch.xpu.synchronize
|
||||
get_free_memory = get_xpu_free_memory
|
||||
else:
|
||||
SYSTEM = "cpu"
|
||||
|
||||
def noop(*args, **kwargs):
|
||||
pass
|
||||
|
||||
empty_cache = noop
|
||||
synchronize = noop
|
||||
get_free_memory = noop
|
||||
|
Loading…
Reference in New Issue
Block a user