Skip to content

Commit

Permalink
Safely access "num_moe_experts"
Browse files Browse the repository at this point in the history
Signed-off-by: Piotr Kamiński <67481570+Laplasjan107@users.noreply.github.com>
  • Loading branch information
Laplasjan107 authored Dec 12, 2024
1 parent f44fd24 commit fe5dac5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nemo/export/tensorrt_llm.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def export(
)

# TODO: Temporary fix
if model_configs["num_moe_experts"] in {None, 0}:
if model_configs.get("num_moe_experts", None) in {None, 0}:
model_configs["num_moe_experts"] = 1

# We build the transformer config using the nemo model config.
Expand Down

0 comments on commit fe5dac5

Please sign in to comment.