mirror of
https://github.com/ml-explore/mlx.git
synced 2025-06-24 09:21:16 +08:00
Fix obsured warning (#1944)
This commit is contained in:
parent
d699cc1330
commit
5db90ce822
@ -598,9 +598,7 @@ class Module(dict):
|
|||||||
parameters to the new dtype.
|
parameters to the new dtype.
|
||||||
"""
|
"""
|
||||||
if predicate is None:
|
if predicate is None:
|
||||||
|
predicate = lambda _: True
|
||||||
def predicate(_):
|
|
||||||
return True
|
|
||||||
|
|
||||||
self.apply(lambda x: x.astype(dtype) if predicate(x.dtype) else x)
|
self.apply(lambda x: x.astype(dtype) if predicate(x.dtype) else x)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user