[MoE Refactor] FusedMoE/MoERunner inversion refactor (#41184)
Signed-off-by: Bill Nell <bnell@redhat.com>
This commit is contained in:
@@ -39,7 +39,7 @@ def length_from_prompt_token_ids_or_embeds(
|
||||
def is_moe_layer(module: torch.nn.Module) -> bool:
|
||||
# TODO(bnell): Should use isinstance but can't due to circular dependencies.
|
||||
def _check_bases(cls):
|
||||
if cls.__name__ == "FusedMoE":
|
||||
if cls.__name__ == "MoERunnerInterface":
|
||||
return True
|
||||
|
||||
for b in cls.__bases__:
|
||||
|
||||
@@ -487,3 +487,8 @@ def has_fbgemm_gpu() -> bool:
|
||||
def has_cutedsl() -> bool:
|
||||
"""Whether the optional `cutelass` package is available."""
|
||||
return _has_module("cutlass")
|
||||
|
||||
|
||||
def has_humming() -> bool:
|
||||
"""Whether the optional `humming` package is available."""
|
||||
return _has_module("humming")
|
||||
|
||||
Reference in New Issue
Block a user