We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 86af61e + fcdee15 commit 9c3a461Copy full SHA for 9c3a461
src/Python/exportsd.py
@@ -37,7 +37,7 @@ def _write_tensor(t, stream):
37
stream.write(leb128.u.encode(len(t.shape)))
38
for s in t.shape:
39
stream.write(leb128.u.encode(s))
40
- stream.write(t.numpy().tobytes())
+ stream.write(t.detach().cpu().numpy().tobytes())
41
42
def write_tensor(t, file_name):
43
f = open(file_name, "wb")
0 commit comments