Skip to content

Commit

Permalink
fix lazy load
Browse files Browse the repository at this point in the history
  • Loading branch information
awni committed Jan 14, 2025
1 parent 1344236 commit 539b870
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions llms/mlx_lm/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ def load(
"""
model_path = get_model_path(path_or_hf_repo)

model, config = load_model(model_path, sequential_load, lazy)
model, config = load_model(model_path, lazy=lazy, sequential_load=sequential_load)
if adapter_path is not None:
model = load_adapters(model, adapter_path)
model.eval()
Expand All @@ -759,7 +759,7 @@ def load(
def fetch_from_hub(
model_path: Path, lazy: bool = False
) -> Tuple[nn.Module, dict, PreTrainedTokenizer]:
model, config = load_model(model_path, lazy)
model, config = load_model(model_path, lazy=lazy, sequential_load=sequential_load)
tokenizer = load_tokenizer(
model_path, eos_token_ids=config.get("eos_token_id", None)
)
Expand Down

0 comments on commit 539b870

Please sign in to comment.