Commit 6625cd3
authored
[Transform] Fix accelerate import to keep it as optional dependency (#480)
Import has_offloaded_params from compressed_tensors.utils.offload instead of
accelerate.utils directly. This ensures accelerate remains optional and the
package can be imported without it installed.
The utils.offload module already has proper fallback handling with
@check_accelerate decorator that returns False when accelerate is not available.
Fixes ModuleNotFoundError when importing compressed_tensors without accelerate.1 parent 07f3b78 commit 6625cd3
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | 18 | | |
20 | 19 | | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
0 commit comments