Ver Fonte

Workaround pytorch/pytorch#31877

Lutz Roeder há 6 anos atrás
pai
commit
b01165d321
2 ficheiros alterados com 4 adições e 4 exclusões
  1. 1 1
      src/pytorch.js
  2. 3 3
      test/models.json

+ 1 - 1
src/pytorch.js

@@ -2697,7 +2697,7 @@ pytorch.Container.Zip = class {
                 // kProducedFileFormatVersion in ./third_party/src/pytorch/caffe2/serialize/inline_container.h
                 const versionEntry = this._entry('version');
                 const versionNumber = versionEntry ? this._utf8Decoder.decode(versionEntry.data).split('\n').shift() : '';
-                const versionTable = { '1': 'v1.3', '2': 'v1.4', '3': 'v1.5' };
+                const versionTable = { '1': 'v1.3', '2': 'v1.4', '3': 'v1.6' };
                 const version = versionTable[versionNumber];
                 if (!version) {
                     this._exceptionCallback(new pytorch.Error("Unsupported PyTorch ZIP version '" + versionNumber + "'."));

+ 3 - 3
test/models.json

@@ -3894,21 +3894,21 @@
     "type":   "pytorch",
     "target": "alexnet.zip.pth",
     "script": "./tools/pytorch sync install zoo",
-    "format": "PyTorch v1.4",
+    "format": "PyTorch v1.6",
     "link":   "https://pytorch.org/docs/stable/torchvision/models.html"
   },
   {
     "type":   "pytorch",
     "target": "alexnet.pt",
     "script": "./tools/pytorch sync install zoo",
-    "format": "TorchScript v1.4",
+    "format": "TorchScript v1.6",
     "link":   "https://pytorch.org/docs/stable/torchvision/models.html"
   },
   {
     "type":   "pytorch",
     "target": "alexnet_traced.pt",
     "script": "./tools/pytorch sync install zoo",
-    "format": "TorchScript v1.4",
+    "format": "TorchScript v1.6",
     "link":   "https://pytorch.org/docs/stable/torchvision/models.html"
   },
   {