class_docstr: Base mixing for MoE modules. The interface represented by this module is:
  
  expert_assignments = gate(hidden_states)
  intermediate = ragged_linear(hidden_states, expert_assignments)
  output = ragged_linear(intermediate, expert_assignments)
class_docstr_tok: ["Base","mixing","for","MoE","modules",".","The","interface","represented","by","this","module","is",":","expert_assignments","=","gate","(","hidden_states",")","intermediate","=","ragged_linear","(","hidden_states",",","expert_assignments",")","output","=","ragged_linear","(","intermediate",",","expert_assignments",")"]
code: def __init__(
      self, config: DSMoEConfig, implementation_config: Dict[str, Any]
  ) -> None:
      super().__init__(config, implementation_config)
  
file_path: deepspeed/deepspeed/inference/v2/modules/interfaces/moe_base.py
imports: from abc import abstractmethod
  from typing import Any, Dict, Optional, Type
  import torch
  from deepspeed.runtime.config_utils import DeepSpeedConfigModel
  from ..ds_module import DSModuleBase
  from ..module_registry import DSModuleRegistryBase
  from ..configs import DSMoEConfig
  from ...inference_parameter import InferenceParameter
label_desc: Use image node_id 2 to create a new DSMoEBase object from inherited base classes: DSModuleBase with example: obj = DSMoEBase(config, implementation_config)