[XPU][NPU][ROCM] enable cpu_offloading flag for non_cuda (#1488)
Signed-off-by: gcanlin <canlinguosdu@gmail.com> Signed-off-by: Chendi Xue <chendi.xue@intel.com> Co-authored-by: gcanlin <canlinguosdu@gmail.com>
This commit is contained in:
1 parent
ba9594724e
commit
482f9b89a1
6 files changed
+16
-11
No files matched your search
@@ -76,9 +76,11 @@ class SequentialOffloadHook(ModelHook):
|
||||
current_omni_platform.synchronize()
|
||||
|
||||
logger.debug(
|
||||
"Swapped: %s -> CPU, %s -> GPU",
|
||||
"Swapped: %s -> CPU, %s -> %s, free memory: %.4f GB",
|
||||
[t.__class__.__name__ for t in self.offload_targets],
|
||||
module.__class__.__name__,
|
||||
f"{self.device.type}:{self.device.index}",
|
||||
current_omni_platform.get_free_memory() / 1024 / 1024 / 1024,
|
||||
)
|
||||
|
||||
return args, kwargs
|
||||
|
||||
Reference in new issue
Block a user