Skip to content

Commit

Permalink
[Bugfix] handle hf_config with architectures == None (#3982)
Browse files Browse the repository at this point in the history
Signed-off-by: Travis Johnson <[email protected]>
Co-authored-by: Simon Mo <[email protected]>
  • Loading branch information
tjohnson31415 and simon-mo authored Apr 10, 2024
1 parent 92cd2e2 commit 934d366
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion vllm/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,9 @@ def _verify_load_format(self) -> None:

# TODO: Remove this check once HF updates the pt weights of Mixtral.
architectures = getattr(self.hf_config, "architectures", [])
if "MixtralForCausalLM" in architectures and load_format == "pt":
# architectures can be None instead of []
if architectures and "MixtralForCausalLM" in architectures \
and load_format == "pt":
raise ValueError(
"Currently, the 'pt' format is not supported for Mixtral. "
"Please use the 'safetensors' format instead. ")
Expand Down

0 comments on commit 934d366

Please sign in to comment.