More useful error message for unsupported batching (#687)

This commit is contained in:
Awni Hannun
2025-12-17 12:30:53 -08:00
committed by GitHub
parent a227a9e9f3
commit cc3264c22e
+1 -1
View File
@@ -874,7 +874,7 @@ def _make_cache(model, left_padding):
"""
def to_batch_cache(c):
if isinstance(c, KVCache):
if type(c) is KVCache:
return BatchKVCache(left_padding)
elif isinstance(c, ArraysCache):
c.left_padding = mx.array(left_padding)