mirror of
https://github.com/ml-explore/mlx-examples.git
synced 2025-06-26 18:51:18 +08:00
[MLX LM] Fix f-string formatting in memory warning message (#1105)
* Fix missing f-prefix for string interpolation in model size warning * Ensures proper display of memory values in MB for model and max size
This commit is contained in:
parent
1e07660184
commit
bd6d910ca3
@ -61,8 +61,8 @@ def wired_limit(model: nn.Module, streams: Optional[List[mx.Stream]] = None):
|
|||||||
model_mb = model_bytes // 2**20
|
model_mb = model_bytes // 2**20
|
||||||
max_rec_mb = max_rec_size // 2**20
|
max_rec_mb = max_rec_size // 2**20
|
||||||
print(
|
print(
|
||||||
"[WARNING] Generating with a model that requires {model_mb} MB "
|
f"[WARNING] Generating with a model that requires {model_mb} MB "
|
||||||
"which is close to the maximum recommended size of {max_rec_mb} "
|
f"which is close to the maximum recommended size of {max_rec_mb} "
|
||||||
"MB. This can be slow. See the documentation for possible work-arounds: "
|
"MB. This can be slow. See the documentation for possible work-arounds: "
|
||||||
"https://github.com/ml-explore/mlx-examples/tree/main/llms#large-models"
|
"https://github.com/ml-explore/mlx-examples/tree/main/llms#large-models"
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user