Skip to content

Commit c026704

Browse files
authored
import ModelCompressor for type checking (#220)
Signed-off-by: Kyle Sayers <[email protected]>
1 parent fc711ca commit c026704

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/compressed_tensors/utils/helpers.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,17 @@
1414

1515
import warnings
1616
from functools import wraps
17-
from typing import Any, Callable, Dict, List, Optional
17+
from typing import TYPE_CHECKING, Any, Callable, Dict, List, Optional
1818

1919
import numpy
2020
import torch
2121
from transformers import AutoConfig
2222

2323

24+
if TYPE_CHECKING:
25+
from compressed_tensors.compressors import ModelCompressor
26+
27+
2428
__all__ = [
2529
"infer_compressor_from_model_config",
2630
"fix_fsdp_module_name",

0 commit comments

Comments
 (0)