Merge pull request #545 from zhc7/patch-1

fix: fix for issue #544
This commit is contained in:
DongYang Li 2024-05-28 20:12:33 +08:00 committed by GitHub
commit a83eea318d
1 changed files with 1 additions and 0 deletions

View File

@ -2010,6 +2010,7 @@ jt.Var.contiguous = contiguous
def cpu(x): return x.clone()
jt.Var.cpu = cpu
def to(x, *args, **kargs):
args += tuple(kargs.values())
if len(args) >= 1:
s = args[0]
if isinstance(s, jt.NanoString) or callable(s):