Skip to content

Commit fc34db6

Browse files
committed
move registration
Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
1 parent 2cf2aa9 commit fc34db6

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

src/llmcompressor/modeling/moe_context.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,13 @@ def moe_calibration_context(
115115
model(**batch)
116116
# Model is now restored (unless permanent)
117117
"""
118+
# trigger registration
119+
from .deepseek_v3 import CalibrationDeepseekV3MoE # noqa: F401
120+
from .llama4 import SequentialLlama4TextMoe # noqa: F401
121+
from .qwen3_moe import CalibrationQwen3MoeSparseMoeBlock # noqa: F401
122+
from .qwen3_vl_moe import CalibrateQwen3VLMoeTextSparseMoeBlock # noqa: F401
123+
# TODO: add granite4, Qwen3Next
124+
118125
replaced = {}
119126

120127
# Step 1: Collect all MoE modules that need replacement

src/llmcompressor/modeling/prepare.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,6 @@
1515
from llmcompressor.modeling.llama4 import replace as replace_llama4
1616
from llmcompressor.modeling.qwen3_vl_moe import replace as replace_Qwen3VLMoE
1717

18-
# trigger registration
19-
from .deepseek_v3 import CalibrationDeepseekV3MoE # noqa: F401
20-
from .llama4 import SequentialLlama4TextMoe # noqa: F401
21-
from .qwen3_moe import CalibrationQwen3MoeSparseMoeBlock # noqa: F401
22-
from .qwen3_vl_moe import CalibrateQwen3VLMoeTextSparseMoeBlock # noqa: F401
23-
24-
# TODO: add granite4, Qwen3Next
25-
2618
__all__ = ["replace_modules_for_calibration"]
2719

2820
# ---------------------- module replacements; permanent -------------------------

tests/llmcompressor/modeling/test_calib_granite4.py

Whitespace-only changes.

0 commit comments

Comments
 (0)