]> khamidou — GitHub mirrors - safetensors.git/commit
Torch fixes (#90)
authorNicolas Patry <patry.nicolas@protonmail.com>
Fri, 18 Nov 2022 13:40:12 +0000 (14:40 +0100)
committerGitHub <noreply@github.com>
Fri, 18 Nov 2022 13:40:12 +0000 (14:40 +0100)
commit11c21549cca3ec3f871b44a8804e2f9ce4df2ac6
tree20e576d6f23dbc64faa256d56c2f1a447c396fd5
parentb8561611f61ce5b204ca5f5597f0e4d64f0b896f
Torch fixes (#90)

* Fix `KeyError: torch.float64` when serializing tensors of doubles and `KeyError: BF16` when parsing.

* Fix non-working `_view2torch` because of the forgotten returns.
Added some tests.

* Test in the same style.

* Like previous style.

Co-authored-by: KOLANICH <kolan_n@mail.ru>
bindings/python/py_src/safetensors/torch.py
bindings/python/tests/test_pt.py [deleted file]
bindings/python/tests/test_pt_comparison.py