From 9a9b0fa408dc7cd0a2b72350071e2190bb1e6d72 Mon Sep 17 00:00:00 2001 From: wejoncy <247153481@qq.com> Date: Fri, 22 Nov 2024 02:53:15 +0000 Subject: [PATCH] resolve 3060 --- src/accelerate/hooks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/accelerate/hooks.py b/src/accelerate/hooks.py index 14d57e33661..2da8796b164 100644 --- a/src/accelerate/hooks.py +++ b/src/accelerate/hooks.py @@ -436,7 +436,8 @@ def attach_execution_device_hook( return for child in module.children(): - attach_execution_device_hook(child, execution_device, skip_keys=skip_keys, tied_params_map=tied_params_map) + attach_execution_device_hook(child, execution_device, skip_keys=skip_keys, + preload_module_classes=preload_module_classes, tied_params_map=tied_params_map) def attach_align_device_hook(