added tqdm to save_model

This commit is contained in:
Anastasiia Filippova
2026-05-14 20:00:29 +02:00
parent df1d3f3c9a
commit ecf87bcf21
+2 -1
View File
@@ -23,6 +23,7 @@ from typing import (
import mlx.core as mx
import mlx.nn as nn
from tqdm import tqdm
if os.getenv("MLXLM_USE_MODELSCOPE", "False").lower() == "true":
try:
@@ -747,7 +748,7 @@ def save_model(
weights.clear()
del weights
for i in range(len(shards)):
for i in tqdm(range(len(shards)), desc="Saving shards", unit="shard"):
shard = shards[i]
shards[i] = None
shard_name = shard_file_format.format(i + 1, shards_count)