You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

mindspore.nn.MoEConfig.rst 673 B

12345678910
  1. .. py:class:: mindspore.nn.transformer.MoEConfig(expert_num=1, capacity_factor=1.1, aux_loss_factor=0.05, num_experts_chosen=1)
  2. MoE (Mixture of Expert)的配置。
  3. **参数:**
  4. - **expert_num** (int) - 表示使用的专家数量。默认值:1。
  5. - **capacity_factor** (float) - 表示专家处理的容量关系,其值大于等于1.0。默认值:1.1。
  6. - **aux_loss_factor** (float) - 表示负载均衡损失(由路由器产生)的平衡系数。相乘的结果会加到总损失函数中。此系数的值小于1.0。默认值:0.05。
  7. - **num_experts_chosen** (int) - 表示每个标识选择的专家数量。默认值:1。