Browse Source

Update to 2.9.3

Lutz Roeder 7 years ago
parent
commit
82de12b670
3 changed files with 21 additions and 19 deletions
  1. 2 2
      Makefile
  2. 15 15
      package.json
  3. 4 2
      src/view.js

+ 2 - 2
Makefile

@@ -43,8 +43,8 @@ publish_pip:
 	@[ -d node_modules ] || npm install
 	rm -rf ./build/python
 	python ./setup.py build --version bdist_wheel
-	python install --user keyring
-	python install --user twine
+	python -m pip install --user keyring
+	python -m pip install --user twine
 	twine upload build/python/dist/*
 
 publish_github_electron:

+ 15 - 15
package.json

@@ -5,7 +5,7 @@
         "email": "[email protected]",
         "url": "lutzroeder.com"
     },
-    "version": "2.9.2",
+    "version": "2.9.3",
     "description": "Viewer neural network models",
     "license": "MIT",
     "repository": "lutzroeder/netron",
@@ -19,22 +19,22 @@
         "test": "[ -d node_modules ] || npm install && node ./test/test.js"
     },
     "dependencies": {
-        "d3": "^5.9.1",
-        "dagre": "^0.8.4",
-        "electron-updater": "^4.0.6",
-        "flatbuffers": "^1.10.2",
-        "handlebars": "^4.1.0",
-        "long": "^4.0.0",
-        "marked": "^0.6.1",
-        "npm-font-open-sans": "^1.1.0",
-        "pako": "^1.0.10",
+        "d3": "5.9.1",
+        "dagre": "0.8.4",
+        "electron-updater": "4.0.6",
+        "flatbuffers": "1.10.2",
+        "handlebars": "4.1.0",
+        "long": "4.0.0",
+        "marked": "0.6.1",
+        "npm-font-open-sans": "1.1.0",
+        "pako": "1.0.10",
         "protobufjs": "github:lutzroeder/protobuf.js#pbtxt",
-        "universal-analytics": "^0.4.20"
+        "universal-analytics": "0.4.20"
     },
     "devDependencies": {
-        "electron": "^4.0.6",
-        "electron-builder": "^20.38.5",
-        "eslint": "^5.15.0",
-        "xmldom": "^0.1.27"
+        "electron": "4.0.6",
+        "electron-builder": "20.38.5",
+        "eslint": "5.15.0",
+        "xmldom": "0.1.27"
     }
 }

+ 4 - 2
src/view.js

@@ -899,7 +899,8 @@ view.View = class {
             var data = new XMLSerializer().serializeToString(exportElement);
     
             if (extension == 'svg') {
-                this._host.export(file, new Blob([ data ], { type: 'image/svg' }));
+                var blob = new Blob([ data ], { type: 'image/svg' });
+                this._host.export(file, blob);
             }
     
             if (extension == 'png') {
@@ -947,7 +948,8 @@ view.View = class {
                         this._host.save('NumPy Array', 'npy', defaultPath, (file) => {
                             try {
                                 var array = new numpy.Array(tensor.value, tensor.type.dataType, tensor.type.shape.dimensions);
-                                this._host.export(file, new Blob([ array.toBuffer() ], { type: 'application/octet-stream' }));
+                                var blob = new Blob([ array.toBuffer() ], { type: 'application/octet-stream' });
+                                this._host.export(file, blob);
                             }
                             catch (error) {
                                 this.error('Error saving NumPy tensor.', error);